;; ;; Logon to FTP site ;; FTPLOGON "IP Address" /user=username /pw=password IFERROR= $ERROR_SUCCESS GOTO Operation1 GOTO Disconnect ;; ;; Receive encrypted file from FTP site ;; :Operation1 RCVFILE "encryptedfile.gpg" IFERROR= $ERROR_SUCCESS GOTO Operation2 GOTO Disconnect ;; ;; Decrypt received file ;; :Operation2 PGPDECRYPT "encryptedfile.gpg" "decryptedfile.txt" /pw=keypassphrase IFERROR= $ERROR_SUCCESS GOTO Disconnect ;; ;; Logoff to FTP Site ;; :Disconnect FTPLOGOFF