;;JPMC site definition from the configurator ftplogon "JPMCManagedSite" ;; Encrypt and upload files ftpcd "incoming" workingdir "c:\JPMC\uploads" :upload_loop getnextfile "*" /oldest IFERROR GOTO download_files set encrypted_file = %nextfile + ".pgp" PGPENCRYPT %nextfile encrypted_file /encryptfor="JPMC" /compat sendfile encrypted_file /delete delete %nextfile goto upload_loop :download_files ;; Download and decrypt files ftpcd "../outgoing" workingdir "c:\JPMC\downloads" :download_loop getsitefile "*.pgp" /oldest IFERROR RETURN $ERROR_SUCCESS rcvfile %sitefile /delete SETREPLACE decrypted_file = %sitefile ".pgp" "" pgpdecrypt %sitefile decrypted_file delete %sitefile GOTO download_loop