Hiding Passwords in ddlgen

When you issue the ddlgen utility in a UNIX command-line environment, other users on that UNIX machine can see your ddlgen command—including its password—if they issue the ps process management command, which shows the status of processes that are running on that machine.

The ddlgen -P password parameter option lets you to invoke ddlgen from a script so that the password is hidden from other users.

To achieve this, set the $PSWD environment variable to point to your SAP ASE login password, and include the string “ext” in the -P parameter. ext acts as a pseudo password, allowing you to supply the actual password in the next line. Set $PSWD at the command line or a Bourne shell script, but not from the C-shell.

  1. Set the $PSWD environment variable:
    setenv PSWD pass_word
  2. Run ddlgen:
    ddlgen -Ulogin -Pext -Sserver:port -Ttype -Nname << END
    $PSWD 
    END 
If you prefer to keep your password in a file, replace $PSWD with `cat filename`, where filename is the location of your password file. For example:
ddlgen -Ulogin -Pext -Sserver:port -Ttype -Nname << END
`cat filename`
END
Note: Enclose cat filename with a grave accent (`); ddlgen returns an error if you use an apostrophe.