Jeff,
I'm not sure what the equivalent is in JSP, but ASP (gasp!) has a Request
object, which contains a collection called ServerVariables. When wanting to
determine the NT account of the user accessing a web site, you can use
Request.ServerVariables("LOGON_USER") which will return the mapped username.
Request.ServerVariables("REMOTE_USER") returns the unmapped, fully qualified
username (e.g. MYDOMAIN\username). These are environment variables created
by IIS on NT for each request made to the server, so you may be able to use
the same names under JSP, if it has an equivalent method of retreiving
server environment variables.
I realise this doesn't answer your question, but hopefully it will help you
in finding an equivalent in JSP.
P.S. Note that if you are allowing anonymous access to your app, the
variables I mentioned will in most cases only return "IUSR_<machinename>",
which is the default anonymous account created by IIS. If you want to
ensure that your users are authenticated properly, use the
Challenge/Response authentication method and restrict access to your web app
folder (e.g. D:\inetpub\wwwroot\mywebapp) and its contents with standard NT
ACLs.
-----Original Message-----
From: Bailey, Jeff A [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 25, 1999 5:26 AM
To: [EMAIL PROTECTED]
Subject: Access to system properties (specifically user) from JSP
Quick question
Has anyone implemented a method to access the username of the person logged
into an NT system through a JSP in any way? Specifically the username of
the person accessing the jsp through a browser.
Sort of like using System.getProperty("user") from a JSP (sorta)
I remember reading about some attempts to do this but dont remember the
details and it is something that would greatly aid some tasks I am working
on. Any third party utilities? etc?
Any ideas are greatly appreciated.
Thanks,
J
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
FAQs on JSP can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
FAQs on JSP can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html