I am sure that would have worked, but Booth's solution was much simpler.


-----Original Message-----
From: MIDRANGE-L <midrange-l-bounces@xxxxxxxxxxxxxxxxxx> On Behalf Of Jerry Draper
Sent: Tuesday, November 26, 2019 4:12 PM
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxxxxxxxx>
Subject: [EXT] Re: sftp from IBMi to remote server

External Email: This is an EXTERNAL email do not click links or open attachments unless you know the content is safe. Please use caution with Urgent Requests.

I know that the private key needs to be secured but with an ssh key exchange connection the partner needs your public key in their authorized_keys file and the partner's RSA fingerprint needs to be in your known_hosts file.

Given that probably any system is breakable the ssh key exchange offers a pretty good solution.


On 11/26/2019 12:44 PM, Patrik Schindler wrote:
Hello Jerry,

Am 26.11.2019 um 21:14 schrieb Jerry Draper <midrangel@xxxxxxxxxxxxx>:

However, the userid/pw is stored in plain text in the FTP script.
True? It is on our system.

Yes, mostly true. See comment from John.

Let's put it this way: If anybody copies the ssh private key, he can also utilize that one for abuse. Ssh-Keys for automation are most often not protected by passwords, so automation doesn't need passwords to be supplied. Thus, the key is unencrypted and ready for use.

In general, it's possible to use ssh-agent. This is a background task to which you can add encrypted (password protected) keys and these will be stored in memory in unencrypted form. (I'm doing that manually after reboots.) Through environment variables, ssh clients (sftp, scp, ssh) and ssh-add (for adding keys) find a local socket for communicating with the ssh-agent. Honestly, I don't know how much of this Linux/Unix specific stuff also applies to PASE, though.

:wq! PoC

PGP-Key: DDD3 4ABF 6413 38DE -;

Jerry Draper, Trilobyte Software Systems, since 1976 IBMi, Network, and Connectivity Specialists, LAN/WAN/VPN Representing WinTronix, Synapse, HiT, and others .....
(415) 457-3431 opt-1 .;;sdata=ER45ejfPMlK6Iw6spm%2FxBZaHEeWE9idOZYte95Cr%2BL4%3D&amp;reserved=0

This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at;;sdata=ORdG%2BGC3NO0qUm2HYokLpzU55ZNNMCDBvTbuI7DRGSo%3D&amp;reserved=0.

Please contact support@xxxxxxxxxxxx for any subscription related questions.

Help support by shopping at with our affiliate link:;;sdata=iZzV8FzXmFI5b0uJCNyC8j0JIP5niLnc6%2BFH7Gl4Ua4%3D&amp;reserved=0
"This email and any attachments, contain Genuine Parts Company confidential information that is proprietary, privileged, and protected by applicable laws. If you have received this message in error and are not the intended recipient, you should not retain, distribute, disclose or use any of this information and you should destroy this email, any attachments or copies therein forthwith. Please notify the sender immediately by email if you have received this email in error."

As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2022 by and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.