I've searched the Database at the monastery on basic authentication and can't seem to find the answer. Hopefully this request isn't completely an insult to the monks.

What I want to do is have the users run a perl cgi script that accepts a userid and password in an html form (not true basic authentication, just a form) and then write these values to the browser cache but for a different realm, not the realm of the original page. That way the proper realm and authentication values are in the client cache when the user is redirected to the new realm.

Under the current system we use basic authentication and that works fine for those links on the menu that require it, but for the other links that want the userid/password in the URL the users have to log in a second time.

By capturing the userid and login and preloading the browser cache I would be able to make a menu that has some links that use basic authentication (would see the preloaded values) and other links that require userid/password to be passed on the url (captured in the original html form).


In reply to Possible to programatically set basic auth realm,userid/password in browser client cache by q_the_eskimo

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.