File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSP and the fly likes Can I get a userid from Windows Authenication from a JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Can I get a userid from Windows Authenication from a JSP" Watch "Can I get a userid from Windows Authenication from a JSP" New topic
Author

Can I get a userid from Windows Authenication from a JSP

Rich Barry
Greenhorn

Joined: Jan 28, 2002
Posts: 19
Hi,
I was wondering if there was a way for a JSP page to get the userid from a users windows login???
Is this possible??
Thx,
Rich
David O'Meara
Rancher

Joined: Mar 06, 2001
Posts: 13459

Complicated. The answer is 'no', except when the answer is 'yes'...
If a user is logged on to their person computer and visits the JSP, you cannot get the name that they logged in as.
However, you can (in some servers like WebSphere) get the JSP to authenticate against the windows login - but all this functionality is driven from the server side. If the JSP is secured, (BASIC or FORM based authentication), the first time they ask for the page they will be challenged for a username and password. These details can be validated against the server. After that the userid is available via request.getRemoteUser()
Dave
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Can I get a userid from Windows Authenication from a JSP
 
Similar Threads
Action Class
Basic Windows Authentication in Weblogic
Windows Authentication
Problems with getRemoteUser()
html:hidden