chore: use Base64 library for generating SS password
This commit is contained in:
1 parent
101e9ebf35
commit
a45e9de472
1 file changed
+1
-1
@@ -139,7 +139,7 @@ class RandomUtil {
|
||||
static randomShadowsocksPassword() {
|
||||
let array = new Uint8Array(32);
|
||||
window.crypto.getRandomValues(array);
|
||||
return btoa(String.fromCharCode.apply(null, array));
|
||||
return Base64.encode(String.fromCharCode.apply(null, array));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user