mirror of
https://github.com/gorhill/uBlock.git
synced 2024-11-10 01:02:08 +01:00
restrict read/write of cached auth secrets to user
This commit is contained in:
parent
d6c1ab868c
commit
5c82bf6eba
2 changed files with 6 additions and 0 deletions
3
dist/chromium/publish-beta.py
vendored
3
dist/chromium/publish-beta.py
vendored
|
@ -64,8 +64,11 @@ def input_secret(prompt, token):
|
|||
value = ubo_secrets[token]
|
||||
elif token not in ubo_secrets or value != ubo_secrets[token]:
|
||||
ubo_secrets[token] = value
|
||||
exists = os.path.isfile(ubo_secrets_filename)
|
||||
with open(ubo_secrets_filename, 'w') as f:
|
||||
json.dump(ubo_secrets, f, indent=2)
|
||||
if not exists:
|
||||
os.chmod(ubo_secrets_filename, 0o600)
|
||||
return value
|
||||
|
||||
|
||||
|
|
3
dist/firefox/publish-signed-beta.py
vendored
3
dist/firefox/publish-signed-beta.py
vendored
|
@ -82,8 +82,11 @@ def input_secret(prompt, token):
|
|||
value = ubo_secrets[token]
|
||||
elif token not in ubo_secrets or value != ubo_secrets[token]:
|
||||
ubo_secrets[token] = value
|
||||
exists = os.path.isfile(ubo_secrets_filename)
|
||||
with open(ubo_secrets_filename, 'w') as f:
|
||||
json.dump(ubo_secrets, f, indent=2)
|
||||
if not exists:
|
||||
os.chmod(ubo_secrets_filename, 0o600)
|
||||
return value
|
||||
|
||||
# GitHub API token
|
||||
|
|
Loading…
Reference in a new issue