Re: Modifying value or format of HTTPServletRequest.getRemoteUser()

2010-01-20 Thread Pid

On 20/01/2010 01:33, Christopher Nebergall wrote:

I have a Jaas plugin where I'm using basic auth.   It authenticates the user
successfully, and in the jaas plugin I make it so
request.getUserPrincipal().getName() it returns the format of the username I
want shown to the app.  But HttpServletRequest.getRemoteUser always returns
the value of the username in the HTTP AUTHORIZATION header.  How do I modify
what getRemoteUser returns to always match the
request.getUserPrincipal().getName()?

Thanks,
Christopher



Use a servlet Filter and wrap the request in an 
HttpServletRequestWrapper.  Override the appropriate method.



p


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Modifying value or format of HTTPServletRequest.getRemoteUser()

2010-01-19 Thread Christopher Nebergall
I have a Jaas plugin where I'm using basic auth.   It authenticates the user
successfully, and in the jaas plugin I make it so
request.getUserPrincipal().getName() it returns the format of the username I
want shown to the app.  But HttpServletRequest.getRemoteUser always returns
the value of the username in the HTTP AUTHORIZATION header.  How do I modify
what getRemoteUser returns to always match the
request.getUserPrincipal().getName()?

Thanks,
Christopher