Skip to content

Instantly share code, notes, and snippets.

@dmlloyd
Created December 10, 2014 16:36
Show Gist options
  • Save dmlloyd/7500201c011b63e66ad9 to your computer and use it in GitHub Desktop.
Save dmlloyd/7500201c011b63e66ad9 to your computer and use it in GitHub Desktop.
Proposed credential verification API
public interface RealmIdentity {
// [...]
/**
* Verify the given credential. The result is one of the following:
* <ul>
* <li>{@link VerificationResult#DENIED} - the credential is not valid</li>
* <li>{@link VerificationResult#UNVERIFIED} - the credential is not supported or could not be verified; retry with another credential type</li>
* <li>{@link VerificationResult#VERIFIED} - the credential is valid and verified</li>
* </ul>
*
* @param credential the credential to verify
* @return the non-{@code null} verification result
*/
VerificationResult verifyCredential(Object credential);
// [...]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment