Cosmicperl,
two points:

1. Apache features
Basic and/or digest authentication - afaik, there is no way how to change browser behavior when auth credentials requested by Apache. Additionally, there is no way how to command browser to forgot used credentials (log out).

2. Proprietary features
it is possible and relatively easy to do, but it depends on your application framework (I mean modperl || php || cgi || ...). I can imagine mod_perl PerlHandler, which is the first in the handler chain, and which checks some cookie containing session ID.
If unsatisfied, prints the html login page and AVOIDS next handler in the chain to process.
If unsatisfied but login and password sent, checks it against rdbms or file, creates unique session id and sets related cookie.
If satisfied, does nothing special, just leaves processing to the next handler of the chain.
Update: I have such handler somewhere, so, let me know if you (or somebody else) are interested in...


In reply to Re: Perl and htaccess by pajout
in thread Perl and htaccess by cosmicperl

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.