Fixed failing test due to change in hashing algorithm

This commit is contained in:
Josh Stark 2019-03-28 17:49:20 +00:00
parent b7aa227d09
commit 87a6c29083

View File

@ -25,7 +25,7 @@ import static org.hamcrest.MatcherAssert.assertThat;
public class PKCS5S2PasswordEncoderTest {
private static final String HASH_FOR_PASSWORD = "8SLrEokFZQQrRk1MeDrpgINOHNXKXPMs2r56DMWBCjLXs9oTHsLzEmnwb68oQAc9+1YdKPTdWahAjjqtvO9M8FtQxCC+8yd71+J1VoWizow=";
private static final String HASH_FOR_PASSWORD = "CYvjZH/RPa+6Y4JVQiKjOTEIrdntD+6DJDmolYpO0gta8gjI5yRiN/dRoHr0PhpJB0EoTmqR4gJakqk6HElT2yRaLp6WPG4U0GZIYjQSUo8=";
private PKCS5S2PasswordEncoder encoder = new PKCS5S2PasswordEncoder("superSecret");
@ -33,9 +33,4 @@ public class PKCS5S2PasswordEncoderTest {
public void shouldGenerateHash() {
assertThat(encoder.matches("password", HASH_FOR_PASSWORD), is(equalTo(true)));
}
@Test
public void test() {
System.out.println(encoder.encode("password").length());
}
}