Using LDAP authenication through a java application based on already LDAP authenticated Windows Session?

So a user logs into a Windows Server 2008 SP2 (64 bit) through a domain using LDAP authentication.

I then have a Java application that launches. The application has several buttons to launch various other applications, which all use the same LDAP authentication (username/password) as used when the user came into the machine.

The problem (or more annoyance) is the user has to enter there username/password again when launching these apps (even though they already authenticated to windows). I'm wondering if there is a way in the JAVA code to use the current windows authentication to pass the users LDAP username and password into the API call that launches these apps? These apps all have an API I call that I pass in the username and password to authenticate, just currently I'm not passing anything in and letting the user enter it. It would be real nice if I could somehow pass in the LDAP details w/ out having to ask the user for them since they are already in windows.

NOTE: The user authenicated in windows will always be the same user launching to app.

Hopefully, what I'm asking makes sense. I'm not an expereienced windows admin or developer, if anything isn't clear or seems incorrect, just ask for clarification.
LVL 5
KGNicklAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

colr__Commented:
Take a look at Spring security - single sign on with LDAP. What you are looking for was formerly called Acegi security (when I used it a couple fo years ago), which would allow you to log in to your app using your windows credentials via LDAP. I dont think it will be possible for you to actually obtain the credentials yourself though as this would be a security problem - no app should ever be given your windows credentials, however you could be smart about it and if the user logs in the first time and succeeds, store the credntials and associated them with the windows user. So the enxt time that user logs on to the machine, you can detect which user is logged in to windows, and extract your stored cache of credentials to use. You'd need to be SUPER careful with this though, you dont want to leak your windows user credentials!
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Development

From novice to tech pro — start learning today.