public class BCryptPasswordEncoder extends Object
| 构造器和说明 |
|---|
BCryptPasswordEncoder() |
BCryptPasswordEncoder(int strength) |
BCryptPasswordEncoder(int strength,
SecureRandom random) |
public BCryptPasswordEncoder()
public BCryptPasswordEncoder(int strength)
strength - the log rounds to use, between 4 and 31public BCryptPasswordEncoder(int strength,
SecureRandom random)
strength - the log rounds to use, between 4 and 31random - the secure random instance to usepublic String encode(CharSequence rawPassword)
public boolean matches(CharSequence rawPassword, String encodedPassword)
public static void main(String[] args)
Copyright © 2020. All rights reserved.