Win a copy of Head First Agile this week in the Agile forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Login + password  RSS feed

 
Roel De Nijs
Sheriff
Posts: 11338
177
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Need to get user's login and password from windows authentication in some way.

Found that jcifs could be doing this, but tried for some hours but not getting any result concerning the password: it's always null.

This is the code i use (in jsp-file)
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You will never get the password from NTLM authentication unless you are using plain text passwords (which will never be the case if you are using NTLM HTTP). You can't even do that through Windows. Its always treated as a hashed value.
 
Roel De Nijs
Sheriff
Posts: 11338
177
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And there is no way to unhash this password?
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No. Hashing is one way, its not the same as encryption. When you hash a value you can only compare the hashed value with other hashed values. Its part of the NTLM security model (as it is with others which use hashing) that you can only reset/change a lost password, not recover it.

If your passwords are sent plain text, then you will be able to get the value. But of course this open the application out to other security issues.
 
Roel De Nijs
Sheriff
Posts: 11338
177
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i was already afraid it couldn't be done.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!