httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michele Waldman" <>
Subject RE: Making mod_auth_digest mysql
Date Fri, 06 Feb 2009 17:10:19 GMT
The isn't one.  I'm talking about writing it.

-----Original Message-----
From: Eric Covener [] 
Sent: Friday, February 06, 2009 9:24 AM
Subject: Re: Making mod_auth_digest mysql

On Fri, Feb 6, 2009 at 8:49 AM, Michele Waldman <>
> I mean to check server environment variables which is what REMOTE_USER is.

This might be better off on

> I just want to know if the variable is defined on the server then I could
> this:
> RewriteEngine On
> RewriteCond %{REMOTE_USER} -e

I couldn't find any reference to "-e", to check if it's empty you can
do !="" or !^$

> RewriteRule ^(.*)$ - [S=1]
> RewriteRule ^.*$ http://domain/login.html [R]
> Right now when REMOTE_USER is not defined this line gets executed:
> RewriteRule ^(.*)$ - [S=1]
> I want that line to be skipped if REMOTE_USER has not been defined as a
> server environment variable.

In per-vhost context, that will never be set unless you use the
lookahead feature.

> You can see the values in phpinfo();  It is only defined if the user is
> logged in.

That processing is later, so REMOTE_USER may be set by then.

> Why would a nonexistent variable evaluate to true?

Unless i'm confused re: "-e", It  seems like your "-e" would be
interpreted as a regex, but that shouldn't match an empty string

Eric Covener

View raw message