I’m working with J2EE application and my web application has to recognize the user without authenticate using the windows logon user info.
When I create a web applciation with VB.NET I used something like that:
Session(“Login”) =
Mid(Request.ServerVariables(“LOGON_USER”),
Request.ServerVariables(“LOGON_USER”).IndexOf(“\”)
+ 2)
Do you know if it’s possible to do the same on Java / Spring / Tomcat webapplication?
tnx,
Andrea
You can use
HttpServletRequest.getRemoteUser().Note that you will need to add some sort of authentication to Tomcat. For example, if you are trying to do NTLM authentication, you can use Waffle.