The PWENCODE SAS procedure enables you to encode passwords that can be used in place of plain-text passwords in SAS programs that access relational database management systems (RDBMSs), SAS/SHARE servers, and SAS Integrated Object Model (IOM) servers (such as the SAS Metadata Server).
PROC PWENCODE IN=’password’ ;
IN=’password’
specifies the password to encode. password can have no more than 512 characters. password can contain letters, numerals, spaces, and special characters
OUT=fileref
specifies a fileref to which the output string is to be written. If the OUT= option is not specified, then the output string is written to the SAS log.
METHOD=encoding-method
specifies the encoding method to use. Currently, sas001 is the only supported encoding method and is the default if the METHOD= option is omitted.
When a password is encoded with PROC PWENCODE, the output string includes a tag that identifies the string as having been encoded. An example of a tag is {sas001}. The tag indicates the encoding method. SAS servers and SAS/ACCESS engines recognize the tag and decode the string before using it. Encoding a password enables you to write SAS programs without having to specify a password in plain text.
/* ENCODE the password and Write it to the Log*/ |
/* ENCODE the password and Save it to the ClipBoard*/ |
/* ENCODE the password and Save it to the Text file C:\pass.txt */ |
/*Use the New password to connect to RDBMS, FTP or anywhere in SAS*/ |
This example creates a file called test.dat in the \remote directory of the unix ftp server for the user ftpuser on the host unixserver: |
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.