Browse Source

更新

tags/v2.4.1
xiaoying 1 year ago
parent
commit
ea8425b8d3
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      tuoheng_oidc_admin/src/test/java/com/tuoheng/passwordTest.java

+ 2
- 2
tuoheng_oidc_admin/src/test/java/com/tuoheng/passwordTest.java View File

@@ -23,7 +23,7 @@ public class passwordTest {
@Test
public void test1() {
String password = "123";
String encode = "{bcrypt}" + passwordEncoder.encode(password);
String encode = passwordEncoder.encode(password);
System.out.println(encode);
//$2a$10$K.gyCkGOvQAbBQg.HAai1O5cvE./sVWLCfiLURhCVjhHVt1SSOAi6
}
@@ -32,7 +32,7 @@ public class passwordTest {
@Test
public void test2() {
String password = "123";
String encode = "{bcrypt}$2a$10$apjRNzmuDrDx2DiGAaVaZeM/HzyxMU3bOEWpZwYsbp5nc9jv1A7FK";
String encode = "$2a$10$apjRNzmuDrDx2DiGAaVaZeM/HzyxMU3bOEWpZwYsbp5nc9jv1A7FK";
boolean matches = passwordEncoder.matches(password, encode);
System.out.println(matches);
}

Loading…
Cancel
Save