aboutsummaryrefslogtreecommitdiff
path: root/share/rpcauth/rpcauth.py
diff options
context:
space:
mode:
Diffstat (limited to 'share/rpcauth/rpcauth.py')
-rwxr-xr-xshare/rpcauth/rpcauth.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/share/rpcauth/rpcauth.py b/share/rpcauth/rpcauth.py
index b14c80171e..c6d9b652b8 100755
--- a/share/rpcauth/rpcauth.py
+++ b/share/rpcauth/rpcauth.py
@@ -5,7 +5,6 @@
from argparse import ArgumentParser
from base64 import urlsafe_b64encode
-from binascii import hexlify
from getpass import getpass
from os import urandom
@@ -13,7 +12,7 @@ import hmac
def generate_salt(size):
"""Create size byte hex salt"""
- return hexlify(urandom(size)).decode()
+ return urandom(size).hex()
def generate_password():
"""Create 32 byte b64 password"""