Do you have the ability to set the password yourself for the SQL Server login? If so, consider the following:
- Come up with a string that is derivable from some concatenation of perl's predefined variables (e.g. $<.$0.$^O or some such) -- use anything you can that "localizes" the string but keeps it invariable when the script is run as intended by the authorized user(s).
- Get the MD5 signature of that string (formatted as base64), randomly select some subset of characters from the signature and put them together in some way to make the password.
Now all you have to do is write the script to derive the password in the necessary fashion, and bingo -- your password is generated at runtime.
I suppose that could be construed as skirting the official policy, but you can point out truthfully that the stated policy conditions are met: the password is not stored as clear text in source code, config file or registry. (It's built on the fly via variables that are likely to have unsuitable values if the script is usurped.)
If you are not able to change the password, play with a few different ways of deriving a string, until you find one such that a base64 MD5 sig contains the characters that make up the password, and build some suitably obfuscated way of pulling those characters in the needed order out of the sig.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.