Tectia

Password in File or Dataset

Password authentication requires normally user interaction. For situations where user interaction is not possible, for example when running Tectia client programs from JCL, you can set up the password in file or dataset.

With sshg3, scpg3, and sftpg3, use the --password=file://FILE option to provide the password. With ssh-keydist-g3, use the --password-file FILE option to provide the password.

[Note]Note

When storing a password in a file or dataset, make sure that the access permissions are correct.

For non-interactive batch jobs, we recommend that you use public-key authentication without a passphrase, or host-based authentication. These methods provide more security than a password stored in a file.

Password in File

To set up password-in-file authentication:

  1. Create a file, for example /home/userid/passwd_file.

  2. Make sure the file is readable only by the user that created it:

    $ chmod 600 /home/userid/passwd_file
    
  3. Edit the file with your favorite text editor to contain one line with your password on the remote system, for example:

    MyPasS
    

To use the password in file, for example with sftpg3, run the following:

$ sftpg3 --password=file:///home/userid/passwd_file

Password in Dataset

To set up password-in-dataset authentication:

  1. Allocate a dataset or a dataset member, for example:

    //'USERID.PASSWD'
    
  2. Make sure that the dataset is accessible only by the correct UserID.

  3. Edit the password dataset to contain your password on the remote system. The format of the password dataset is one line containing only the password. For example:

    MyPasS
    

To use the password in dataset, for example with sftpg3, run the following:

$ sftpg3 --password=file:////'USERID.PASSWD'