PASSWD_DSN='//DD:PASSWD'

Discussion of Co:Z sftp, a port of OpenSSH sftp for z/OS
Post Reply
cschneid
Posts: 4
Joined: Fri Apr 13, 2012 1:24 pm

PASSWD_DSN='//DD:PASSWD'

Post by cschneid »

z/OS 1.12
cozbatch version 1.2.5 2009-04-20
Co:Z sftp version: 1.2.5 (5.0p1) 2009-04-20

Is it possible to point the PASSWD_DSN environment variable at a DD statement instead of hardcoding the dataset name? We have tried this, and the result is...

Code: Select all

fromdsn(DD:PASSWD)[E]: DatasetHandler: Error in fopen(//DD:PASSWD, rb,type=record,noseek,recfm=*) - EDC5037I The specified ddname was not found. (errno2=0xC00B05B1)
A search of this board uncovered the requirement for _BPX_SHAREAS to be set to "YES" for GET and PUT to reference DD statements, our value for _BPX_SHAREAS is "MUST" which appears to be effectively the same as "YES" with the caveat that the child process will never be created in a separate address space.

Simply executing the read_passwd_dsn.sh script with PASSWD_DSN pointing to '/DD:PASSWD' is successful; unfortunately, trying to use this same PASSWD_DSN reference in executing cozsftp doesn't seem to work for us. Is there a solution or workaround?
dovetail
Site Admin
Posts: 2025
Joined: Thu Jul 29, 2004 12:12 pm

Re: PASSWD_DSN='//DD:PASSWD'

Post by dovetail »

Unfortunately, IBM Ported Tools ssh (used by Co:Z for the ssh connection) does a "fork" of the SSH_ASKPASS program, so it runs in a separate address space. This means that it is not possible to reference a DD back in the original job step.
cschneid
Posts: 4
Joined: Fri Apr 13, 2012 1:24 pm

Re: PASSWD_DSN='//DD:PASSWD'

Post by cschneid »

Thank you for the reply. At least now we know.
Post Reply