×
The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.
Audit logging with QSHELL/STRQSH CMD('/QOpenSys/bin/sftp -v -b YourSFTPscriptFile.txt -o IdentityFile=~/.ssh/id_rsa AllowedUser@xxxxxxxxxx > /IFSFolder/YourLogFile.log 2>&1 ')
subcommand LS -lt may have a parameter allowing you to direct the LS output to some IFS location.
https://www.ibm.com/docs/en/search/SSH?scope=ssw_ibm_i_75
-----Original Message-----
From: MIDRANGE-L <midrange-l-bounces@xxxxxxxxxxxxxxxxxx> On Behalf Of DEnglander--- via MIDRANGE-L
Sent: Tuesday, November 29, 2022 1:17 PM
To: midrange-l@xxxxxxxxxxxxxxxxxx
Cc: DEnglander@xxxxxxxxxxxxxxx
Subject: [External] SFTP examples
[WARNING]: External Email
Does anyone have an example (or know of a URL where I can find an example) of using SFTP?
I need to have SFTP executed in a CL [or RPG] program that is submitted to Batch. That program will need to sign on to the remote SFTP server, execute the LS command on a specific folder, and then place the contents of the LS command into a file on the IFS.
My credentials are correct because I have another SFTP process that sends our IFS files to the same remote server, and it works fine [it does not create any logging/listing file but I would like it to]. I would like to capture the whole back and forth session between the two systems, and most importantly, the contents of the folder.
Any ideas?
Thank you,
Doug
As an Amazon Associate we earn from qualifying purchases.