Cody Pendant has asked for the wisdom of the Perl Monks concerning the following question:
I was just noticing how the Movable Type people do it (see point 8, "Set your SQL database password").
Most of their information goes in a ".cfg" config file. But the username and password go in a separate file, which has the CGI extension, only without a shebang line. So even though everyone knows where it is, you can't execute it or view it, so you can steal the details.
Is this normal? What are they protecting against by going to all that trouble as opposed to just putting it in the script? Or in the config file? After all, as long as the config doesn't have a "Content-type: whatever\n\n" somewhere, I can't see that either.
Nobody says perl looks like line-noise any more
kids today don't know what line-noise IS ...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: hiding username/password in database scripts
by kyle (Abbot) on Jan 13, 2008 at 03:26 UTC | |
|
Re: hiding username/password in database scripts
by graff (Chancellor) on Jan 13, 2008 at 07:41 UTC | |
|
Re: hiding username/password in database scripts
by gam3 (Curate) on Jan 13, 2008 at 15:10 UTC | |
|
Re: hiding username/password in database scripts
by hpavc (Acolyte) on Jan 13, 2008 at 16:55 UTC | |
|
Re: hiding username/password in database scripts
by Cody Pendant (Prior) on Jan 13, 2008 at 22:31 UTC | |
by WoodyWeaver (Monk) on Jan 14, 2008 at 00:03 UTC |