I haven't read anywhere that Shiro attempts to tackle this problem but it
seems a great place to ask the question to get advice and on the surface
seems like it might be very helpful functionality that could be built into
Shiro.

So the question is: Can you use Shiro (or do you have guidance to some other
text or Java code) that can retrieve the currently logged on user credential
for someone that has logged into a Windows network via Active Directory? I
haven't been able to find good documentation on how to do this anywhere,
though maybe my Google skills are just lacking. A typical example would be
that a user at his company logs on to their Windows XP or 7 machine and
enters their user name and password for a particular domain. That domain is
usually controlled by an Active Directory - I know Shiro handles Active
Directory authentication if you pass in a user name and password. From what
I've found so far it seems like prior to Java 6 you would need to
communicate with a DLL via JNI or JNA to find such info out. Then with Java
6 the GSS API is supposed to help handle this type of situation but I
haven't found out how to use it yet. The System.getProperty("user.name") is
a poor way to do it since anyone can change the environment variable.

Hope that makes sense and any advise or thoughts are greatly appreciated!

Scott
-- 
View this message in context: 
http://shiro-user.582556.n2.nabble.com/Gathering-Windows-logon-credentials-tp5272872p5272872.html
Sent from the Shiro User mailing list archive at Nabble.com.

Reply via email to