mirror of
https://github.com/josegonzalez/python-github-backup.git
synced 2025-12-06 00:28:01 +01:00
Encode special characters in password
This commit is contained in:
@@ -243,7 +243,11 @@ def get_auth(args, encode=True):
|
|||||||
elif args.username:
|
elif args.username:
|
||||||
if not args.password:
|
if not args.password:
|
||||||
args.password = getpass.getpass()
|
args.password = getpass.getpass()
|
||||||
auth = args.username + ':' + args.password
|
if encode:
|
||||||
|
password = args.password
|
||||||
|
else:
|
||||||
|
password = urllib.quote(args.password)
|
||||||
|
auth = args.username + ':' + password
|
||||||
elif args.password:
|
elif args.password:
|
||||||
log_error('You must specify a username for basic auth')
|
log_error('You must specify a username for basic auth')
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user