Hi all,

As we all know, silly things happen that sometimes require a proof of concept. This one happens to have a core need for writing a mysql "proxy" server, if you will. The functionality consists of one type of query. If a client service sends a specific query, where it's looking up a username/pass combo, then the script needs to ignore the password stored in mysql but then reference a RADIUS server for that information. The application's result is based on the success/failure of the RADIUS query whereby the rows returned would be 1/0 (if 1, it contains the pass that was used). All other queries go right to the mysql server for this application.

So, the question to all is.... does anyone know of a way of making a "mysql server" in perl (ie the existence of a perl module). I've searched cpan/google. I'm sure I'm not asking the right question as all the results that come back discuss on how to make your perl script talk to a mysql server. http://search.cpan.org/~timb/DBI-1.53/lib/DBI/ProxyServer.pm is the closet thing I came across, but I'm not sure it's the right thing.

Yes, I know there are TONS better ways of attacking this... but as I said before there are silly things that happened which lead up to this. In essence, if this proof of concept doesnt work then no harm/foul because the system as a whole can go back into it's previous state. If this does work, then it will justify that the whole system will be rebuilt from scratch to accommodate this new password system.


In reply to DBI/MySQL Proxy by satanklawz

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.