Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Get Remote Username

by vsailas (Beadle)
on Dec 12, 2007 at 04:59 UTC ( #656549=perlquestion: print w/replies, xml ) Need Help??
vsailas has asked for the wisdom of the Perl Monks concerning the following question:

Hi, I have this problem, I want to create login access and use Mysql to store them.
I want to save the remote "username" as an when a new account is created or an account is updated.
I suppose that to use ENV{REMOTE_USER}, I need to authenticate using .htaccess,
but as I said I have an database based authentication.

Please help me!
Thank you.

Replies are listed 'Best First'.
Re: Get Remote Username
by moritz (Cardinal) on Dec 12, 2007 at 06:36 UTC
    There are several approaches.

    One is to dump the database contents regularly into a .htusers files and let Apache do all the dirty work.

    Another possibility is to send the 401 Autentication Required HTTP header yourself, and deal with the response by yourself.

    Or you can set up your own authentication handler.

Re: Get Remote Username
by Thilosophy (Curate) on Dec 12, 2007 at 06:29 UTC

    Using .htaccess does not necessarily mean a password file. Check out mod_authmysql for making Apache get the passwords from MySQL.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://656549]
Approved by lidden
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (8)
As of 2016-10-28 18:54 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (386 votes). Check out past polls.