Often you want to connect to a site to get data that
requires a name and password, but you want a simple
interface. For instance one that will work with
LWP::Simple. The following form of a URL is documented
but apparently not as widely known as it deserves to be.
It should work for all protocols.
EDIT
A piece of trivia. Hotmail has an interesting use for
this. Their name/password form is submitted by https to
a script that does nothing but redirect to a URL with the
name and password inserted as above, that will require
Digest authentication. The browser without prompting then
uses the name and password (as originally typed in their
form) and from then on has http authentication loaded.
Turning form entries into http authentication securely without encrypting your whole site is something that a lot of people think is impossible. Well it is not, and that is how you do it! :-)
http://name:password@www.somedomain.com/whatever/page.html
|
---|
Replies are listed 'Best First'. | |
---|---|
RE: Put name and password in URLs
by tenatious (Beadle) on Aug 26, 2000 at 22:10 UTC | |
Re: Put name and password in URLs - except for IE :-(
by tilly (Archbishop) on Feb 01, 2004 at 21:07 UTC | |
Re (tilly) 1: Put name and password in URLs
by tilly (Archbishop) on Aug 22, 2001 at 19:39 UTC | |
by vacant (Pilgrim) on Nov 10, 2003 at 05:15 UTC | |
by tilly (Archbishop) on Nov 10, 2003 at 15:32 UTC | |
RE: Put name and password in URLs
by Anonymous Monk on Nov 04, 2000 at 00:24 UTC |
Back to
Cool Uses for Perl