Protecting a SQLPLUS account password in a script
I have a SQL SQLPLUS script that needs to run on a Windows 2008R2 server.
I have coded the script commands in script.sql
I call script.sql using sqlplus /nolog @c:\scripts\script.sql
How do I protect the password for the account so that the password is not in clear txt in the script.
I don't want to have in the script
How are other people out there protecting the password so it can't be seen clear txt in the script?
Not that much different than on UNIX, where an env file is sourced - the password is clear text within that file, but the rub is: who can read it? Same thing applies in Windows - use NTFS permissions to allow reading of the file only by whomever. A "dot" env file in UNIX is owned by oracle, so the perms may be rw-------. In Windows, block access to the file via NTFS.
Or...you also can use an "externally identified" account.
"The person who says it cannot be done should not interrupt the person doing it." --Chinese Proverb
Click Here to Expand Forum to Full Width