Hi,
can you check with a simple server side include shtml file that the
remote user is properly set:
<html>
<head></head>
<body>
<p>Hi, I'm protected by CAS.</p>
<p>REMOTE_USER =
<!--#echo var="REMOTE_USER"-->
</p>
</body>
</html>
I'm not very familiar with the rewrite stuff but you regex seems wrong.
The condition should be .+ or maybe even ^.+$ . Your regexp will match
an empty remote user. Your groupings are unecessary since you dont use them.
RewriteEngine on
RewriteCond %{REMOTE_USER} ^.+$
rewriteRule ^index.php.*
/research/conduct/signedin.php\?user\=%{REMOTE_USER}
Since you are trying to get the remote user to an php application i
would suggest you give phpCAS https://wiki.jasig.org/display/CASC/phpCAS
a try.
Cheers,
Joachim
Am 08.07.2010 18:14, schrieb David Wolowicz:
Hi Phil,
Your message was lost in my CAS inbox there for a bit.
The REMOTE_USER is being populated for PHP, and the user is being correctly
authenticated. I just can't seem to access the remote_user from the .htaccess
file. I don't currently have a log file for this.
Thanks
Dave Wolowicz
Manager of Web Services
University of Victoria Systems
[email protected] | (250) 721-6117
Call me toll-free over the internet: UVic-6117
-----Original Message-----
From: Phil Ames [mailto:[email protected]]
Sent: July-01-10 8:06 PM
To: [email protected]
Subject: Re: [cas-user] mod_auth_cas, REMOTE_USER, and mod_rewrite
Hi David,
Have you made any progress in solving this issue?
If you put something simple like a phpinfo() type script in the
resulting directory (or anything that prints out the environment) is
REMOTE_USER properly populated?
Does mod_auth_cas redirect the user and not populate this field after
the ticket is validated?
Can you share the logs from LogLevel debug for that VirtualHost with
CASDebug On?
Thanks,
-Phil
On Sat, Jun 26, 2010 at 12:00 PM, David Wolowicz<[email protected]> wrote:
Hi all,
I'm having some issues with mod_auth_cas, and passing the REMOTE_USER
variable to mod_rewrite. I'm not sure if it's a apache module loading or run
time thing, or just something that is not working.
Here is my test .htaccess:
###################################
AuthType CAS
AuthName "CAS"
require valid-user
<Files index.php>
Satisfy Any
</Files>
RewriteEngine on
RewriteCond %{REMOTE_USER} (.*)
rewriteRule ^index.php(.*)
/research/conduct/signedin.php\?user\=%{REMOTE_USER}
###################################
Please note that I'm putting the username into the URL so that I can see if
it's there or not. All I can get from this is:
https://adomain.uvic.ca /research/conduct/signedin.php?user%3d
Any ideas?
I have also attempted this:
###################################
CASAuthNHeader CAS_USER
AuthType CAS
AuthName "CAS"
require valid-user
<Files index.php>
Satisfy Any
</Files>
RewriteEngine on
RewriteCond %{REMOTE_USER} (.*)
rewriteRule ^index.php(.*) /research/conduct/signedin.php\?user\=%{CAS_USER}
####################################
Any help would be greatly appreciated.
Thanks
David Wolowicz
Manager of Web Services
University Systems | University of Victoria
(250) 721-6117 | [email protected]
--
You are currently subscribed to [email protected] as:
[email protected]
To unsubscribe, change settings or access archives, see
http://www.ja-sig.org/wiki/display/JSG/cas-user
--
You are currently subscribed to [email protected] as:
[email protected]
To unsubscribe, change settings or access archives, see
http://www.ja-sig.org/wiki/display/JSG/cas-user