Just wondering, but what keeps the guy who breaks into your system from setting up something that harvests those usernames and passwords from any method of authorization? This is why they introduced digest authorization and are further beefing up security with the Apache 2.1 authorization scheme.

As a side note, do not encrypt the username and password for a DBI connection on the server unless you REALLY REALLY want to. Think about it if you will: the server has to decrypt them somehow. The decryption key will be either stored somewhere on the machine or provided by the user. If someone takes control of the system, they can either find it wherever it is on the hard drive or harvest it the next time someone comes in. Forming the database connection is already expensive and decrypting the username and password will only make this process more expensive.

antirice    
The first rule of Perl club is - use Perl
The
ith rule of Perl club is - follow rule i - 1 for i > 1


In reply to Re: Authenticating to mySQL through DBI on Apache? by antirice
in thread Authenticating to mySQL through DBI on Apache? by Massyn

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • 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:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.