@SupportsCredentials(value={org.picketlink.idm.credential.DigestCredentials.class,org.picketlink.idm.credential.Digest.class})
public class DigestCredentialHandler<S,V,U>
extends Object
implements org.picketlink.idm.credential.spi.CredentialHandler<org.picketlink.idm.spi.CredentialStore<?>,org.picketlink.idm.credential.DigestCredentials,org.picketlink.idm.credential.Digest>
This particular implementation supports the validation of DigestCredentials.
When using this handler, password are always stored using: H(A1) = MD5 (unq(username) ":" unq(realm) ":" password). During
the validation this handler will use the stored HA1 to compare with the digest provided by the Digest credential.
This is done in two ways, if the credential has the method and uri setted the H(A2) will also be calculated and used to
calcutate the final digest as KD ( H(A1), unq(nonce-value) ":" nc-value ":" unq(cnonce-value) ":" unq(qop-value) ":" H(A2) ).
| Constructor and Description |
|---|
DigestCredentialHandler() |
| Modifier and Type | Method and Description |
|---|---|
void |
setup(org.picketlink.idm.spi.CredentialStore<?> identityStore) |
void |
update(org.picketlink.idm.spi.SecurityContext context,
org.picketlink.idm.model.Agent agent,
org.picketlink.idm.credential.Digest digest,
org.picketlink.idm.spi.CredentialStore<?> store,
Date effectiveDate,
Date expiryDate) |
void |
validate(org.picketlink.idm.spi.SecurityContext context,
org.picketlink.idm.credential.DigestCredentials credentials,
org.picketlink.idm.spi.CredentialStore<?> store) |
public void setup(org.picketlink.idm.spi.CredentialStore<?> identityStore)
setup in interface org.picketlink.idm.credential.spi.CredentialHandler<org.picketlink.idm.spi.CredentialStore<?>,org.picketlink.idm.credential.DigestCredentials,org.picketlink.idm.credential.Digest>public void validate(org.picketlink.idm.spi.SecurityContext context,
org.picketlink.idm.credential.DigestCredentials credentials,
org.picketlink.idm.spi.CredentialStore<?> store)
validate in interface org.picketlink.idm.credential.spi.CredentialHandler<org.picketlink.idm.spi.CredentialStore<?>,org.picketlink.idm.credential.DigestCredentials,org.picketlink.idm.credential.Digest>public void update(org.picketlink.idm.spi.SecurityContext context,
org.picketlink.idm.model.Agent agent,
org.picketlink.idm.credential.Digest digest,
org.picketlink.idm.spi.CredentialStore<?> store,
Date effectiveDate,
Date expiryDate)
update in interface org.picketlink.idm.credential.spi.CredentialHandler<org.picketlink.idm.spi.CredentialStore<?>,org.picketlink.idm.credential.DigestCredentials,org.picketlink.idm.credential.Digest>Copyright © 2013. All Rights Reserved.