Search in sources :

Example 1 with HashedCredentialsMatcher

use of org.apache.shiro.authc.credential.HashedCredentialsMatcher in project killbill by killbill.

the class KillbillCredentialsMatcher method getCredentialsMatcher.

public static CredentialsMatcher getCredentialsMatcher(final SecurityConfig securityConfig) {
    // This needs to be in sync with DefaultTenantDao
    final HashedCredentialsMatcher credentialsMatcher = new HashedCredentialsMatcher(HASH_ALGORITHM_NAME);
    // base64 encoding, not hex
    credentialsMatcher.setStoredCredentialsHexEncoded(false);
    credentialsMatcher.setHashIterations(securityConfig.getShiroNbHashIterations());
    return credentialsMatcher;
}
Also used : HashedCredentialsMatcher(org.apache.shiro.authc.credential.HashedCredentialsMatcher)

Example 2 with HashedCredentialsMatcher

use of org.apache.shiro.authc.credential.HashedCredentialsMatcher in project neo4j by neo4j.

the class SecureHasher method getHashedCredentialsMatcher.

public HashedCredentialsMatcher getHashedCredentialsMatcher() {
    if (hashedCredentialsMatcher == null) {
        hashedCredentialsMatcher = new HashedCredentialsMatcher(HASH_ALGORITHM);
        hashedCredentialsMatcher.setHashIterations(HASH_ITERATIONS);
    }
    return hashedCredentialsMatcher;
}
Also used : HashedCredentialsMatcher(org.apache.shiro.authc.credential.HashedCredentialsMatcher)

Aggregations

HashedCredentialsMatcher (org.apache.shiro.authc.credential.HashedCredentialsMatcher)2