File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Security and the fly likes Principal and Credential Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Security
Bookmark "Principal and Credential" Watch "Principal and Credential" New topic

Principal and Credential

S. Palanigounder
Ranch Hand

Joined: Apr 03, 2003
Posts: 145
What is Principal? What is Credential?
What is the difference between them?
Maulin Vasavada
Ranch Hand

Joined: Nov 04, 2001
Posts: 1873
according to me,
principal is an object that presents the "identity" (name of the login user for e.g.)
credentials are the "credibility" parameters associated with the principal (password for e.g.)
in LDAP for e.g. we can have a user that can be "identified" by DN="uid=maulin,ou=developers,o=mycompany"
that is a principal for user "maulin" and if my password is "password" then my credentials is "password"
hope this helps.
I agree. Here's the link:
subject: Principal and Credential
It's not a secret anymore!