Class CredentialsFactory
- java.lang.Object
-
- org.eclipse.equinox.security.auth.credentials.CredentialsFactory
-
public final class CredentialsFactory extends java.lang.ObjectThis factory can be used by login modules to create Equinox public and private credentials. It is expected that as a result of successful login credentials are added to theSubject.This class is not intended to be instantiated or extended by clients.
- Restriction:
- This class is not intended to be instantiated by clients.
-
-
Constructor Summary
Constructors Constructor Description CredentialsFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static IPrivateCredentialprivateCredential(javax.crypto.spec.PBEKeySpec privateKey, java.lang.String providerID)Login modules can use this method to create new private credentials.static IPublicCredentialpublicCredential(java.lang.String name, java.security.Principal[] roles, java.lang.String providerID)Login modules can use this method to create new public credentials as a result of the login process.static IPublicCredentialpublicCredential(java.lang.String name, java.security.Principal primaryRole, java.lang.String providerID)Login modules can use this method to create new public credentials as a result of the login process.
-
-
-
Method Detail
-
publicCredential
public static IPublicCredential publicCredential(java.lang.String name, java.security.Principal primaryRole, java.lang.String providerID)
Login modules can use this method to create new public credentials as a result of the login process.- Parameters:
name- user's nameprimaryRole- user's primary role,nullif not availableproviderID- the ID of the creator of this public credential; if provider was described as an extension, use the extension ID- Returns:
- new public credential
- See Also:
Subject.getPublicCredentials()
-
publicCredential
public static IPublicCredential publicCredential(java.lang.String name, java.security.Principal[] roles, java.lang.String providerID)
Login modules can use this method to create new public credentials as a result of the login process.- Parameters:
name- user's nameroles- user's roles,nullif not availableproviderID- the ID of the creator of this public credential; if provider was described as an extension, use the extension ID- Returns:
- new public credential
- See Also:
Subject.getPublicCredentials()
-
privateCredential
public static IPrivateCredential privateCredential(javax.crypto.spec.PBEKeySpec privateKey, java.lang.String providerID)
Login modules can use this method to create new private credentials.- Parameters:
privateKey- the private key to be stored in this credentialproviderID- the ID of the creator of this private credential; if provider was described as an extension, use the extension ID- Returns:
- new private credential
- See Also:
Subject.getPrivateCredentials()
-
-