/** * Create a raw implementation of this password type. No validation of the content is performed, and the password * must be "adopted" in to a {@link PasswordFactory} (via the {@link PasswordFactory#translate(Password)} method) * before it can be validated and used to verify guesses. * * @param algorithm the algorithm name * @param hash the hash * @param salt the salt * @param iterationCount the iteration count * @return the raw password implementation */ static SunUnixMD5CryptPassword createRaw(String algorithm, byte[] salt, byte[] hash, int iterationCount) { Assert.checkNotNullParam("algorithm", algorithm); Assert.checkNotNullParam("salt", salt); Assert.checkNotNullParam("hash", hash); return new RawSunUnixMD5CryptPassword(algorithm, salt, hash, iterationCount); } }
public boolean equals(final Object obj) { if (! (obj instanceof RawSunUnixMD5CryptPassword)) { return false; } RawSunUnixMD5CryptPassword other = (RawSunUnixMD5CryptPassword) obj; return iterationCount == other.iterationCount && getAlgorithm().equals(other.getAlgorithm()) && Arrays.equals(hash, other.hash) && Arrays.equals(salt, other.salt); } }
public int hashCode() { return multiHashOrdered(multiHashOrdered(multiHashOrdered(Arrays.hashCode(hash), Arrays.hashCode(salt)), iterationCount), getAlgorithm().hashCode()); }
/** * Create a raw implementation of this password type. No validation of the content is performed, and the password * must be "adopted" in to a {@link PasswordFactory} (via the {@link PasswordFactory#translate(Password)} method) * before it can be validated and used to verify guesses. * * @param algorithm the algorithm name * @param hash the hash * @param salt the salt * @param iterationCount the iteration count * @return the raw password implementation */ static SunUnixMD5CryptPassword createRaw(String algorithm, byte[] salt, byte[] hash, int iterationCount) { Assert.checkNotNullParam("algorithm", algorithm); Assert.checkNotNullParam("salt", salt); Assert.checkNotNullParam("hash", hash); return new RawSunUnixMD5CryptPassword(algorithm, salt, hash, iterationCount); } }
public boolean equals(final Object obj) { if (! (obj instanceof RawSunUnixMD5CryptPassword)) { return false; } RawSunUnixMD5CryptPassword other = (RawSunUnixMD5CryptPassword) obj; return iterationCount == other.iterationCount && getAlgorithm().equals(other.getAlgorithm()) && Arrays.equals(hash, other.hash) && Arrays.equals(salt, other.salt); } }
/** * Create a raw implementation of this password type. No validation of the content is performed, and the password * must be "adopted" in to a {@link PasswordFactory} (via the {@link PasswordFactory#translate(Password)} method) * before it can be validated and used to verify guesses. * * @param algorithm the algorithm name * @param hash the hash * @param salt the salt * @param iterationCount the iteration count * @return the raw password implementation */ static SunUnixMD5CryptPassword createRaw(String algorithm, byte[] salt, byte[] hash, int iterationCount) { Assert.checkNotNullParam("algorithm", algorithm); Assert.checkNotNullParam("salt", salt); Assert.checkNotNullParam("hash", hash); return new RawSunUnixMD5CryptPassword(algorithm, salt, hash, iterationCount); } }
public boolean equals(final Object obj) { if (! (obj instanceof RawSunUnixMD5CryptPassword)) { return false; } RawSunUnixMD5CryptPassword other = (RawSunUnixMD5CryptPassword) obj; return iterationCount == other.iterationCount && getAlgorithm().equals(other.getAlgorithm()) && Arrays.equals(hash, other.hash) && Arrays.equals(salt, other.salt); } }
/** * Create a raw implementation of this password type. No validation of the content is performed, and the password * must be "adopted" in to a {@link PasswordFactory} (via the {@link PasswordFactory#translate(Password)} method) * before it can be validated and used to verify guesses. * * @param algorithm the algorithm name * @param hash the hash * @param salt the salt * @param iterationCount the iteration count * @return the raw password implementation */ static SunUnixMD5CryptPassword createRaw(String algorithm, byte[] salt, byte[] hash, int iterationCount) { Assert.checkNotNullParam("algorithm", algorithm); Assert.checkNotNullParam("salt", salt); Assert.checkNotNullParam("hash", hash); return new RawSunUnixMD5CryptPassword(algorithm, salt, hash, iterationCount); } }
public boolean equals(final Object obj) { if (! (obj instanceof RawSunUnixMD5CryptPassword)) { return false; } RawSunUnixMD5CryptPassword other = (RawSunUnixMD5CryptPassword) obj; return iterationCount == other.iterationCount && getAlgorithm().equals(other.getAlgorithm()) && Arrays.equals(hash, other.hash) && Arrays.equals(salt, other.salt); } }
public int hashCode() { return multiHashOrdered(multiHashOrdered(multiHashOrdered(Arrays.hashCode(hash), Arrays.hashCode(salt)), iterationCount), getAlgorithm().hashCode()); }
public int hashCode() { return multiHashOrdered(multiHashOrdered(multiHashOrdered(Arrays.hashCode(hash), Arrays.hashCode(salt)), iterationCount), getAlgorithm().hashCode()); }
public int hashCode() { return multiHashOrdered(multiHashOrdered(multiHashOrdered(Arrays.hashCode(hash), Arrays.hashCode(salt)), iterationCount), getAlgorithm().hashCode()); }