mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
fix code
This commit is contained in:
@@ -174,7 +174,7 @@ public class KeyUtil {
|
||||
}
|
||||
|
||||
if (null == password) {
|
||||
password = RandomUtil.randomString(32).toCharArray();
|
||||
password = RandomUtil.randomStringLower(32).toCharArray();
|
||||
}
|
||||
return generateKey(algorithm, SpecUtil.createPBEKeySpec(password));
|
||||
}
|
||||
|
@@ -72,7 +72,7 @@ public class SpecUtil {
|
||||
*/
|
||||
public static PBEKeySpec createPBEKeySpec(char[] password) {
|
||||
if (null == password) {
|
||||
password = RandomUtil.randomString(32).toCharArray();
|
||||
password = RandomUtil.randomStringLower(32).toCharArray();
|
||||
}
|
||||
return new PBEKeySpec(password);
|
||||
}
|
||||
|
Reference in New Issue
Block a user