Welcome to WebmasterWorld Guest from 50.17.16.177

Forum Moderators: Ocean10000 & incrediBILL & phranque

Message Too Old, No Replies

Rewrite REMOTE USER

Add more info to Existng remote_user

     
11:44 am on Jun 17, 2013 (gmt 0)

New User

joined:June 17, 2013
posts: 1
votes: 0


I'm very new to this and have been tasked with coming up with a Single Sign on solution to a system that basically can have three usernames for the same user and the only difference is _agt (Agent Login), _sup (supervisor Login) and _adm (Admin Login)

The username is all these is the users default windows username and password.

Using mod rewrite I am able to get the username of the user but how do I append the _agt, _sup or _adm to the username?

My idea is to have three separate locations that resolve to one central location and then do the three different rewrites as listed above.

This is the rewrite code I'm using at the moment inside the location section for agt - at the moment this only gets me the username


RewriteEngine on
RewriteCond %{REMOTE_USER} (.+)
RewriteRule . - [E=RU:%1]
RequestHeader set REMOTE_USER %{RU}e
3:42 am on June 26, 2013 (gmt 0)

Administrator

WebmasterWorld Administrator phranque is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Aug 10, 2004
posts:10542
votes: 8


welcome to WebmasterWorld, jp9757!


does something like this work?
RewriteRule . - [E=RU:%1_agt]