Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: sitescripts/oauth2dl/bin/constants.py

Issue 29833582: Issue 4954 - Implement a downloader script supporting OAuth2 authentication/authorization (Closed)
Patch Set: Created July 18, 2018, 1:41 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: sitescripts/oauth2dl/bin/constants.py
diff --git a/sitescripts/oauth2dl/bin/constants.py b/sitescripts/oauth2dl/bin/constants.py
new file mode 100644
index 0000000000000000000000000000000000000000..a0d2f5f92c3305aa761ee8f96b8101ac41544f0e
--- /dev/null
+++ b/sitescripts/oauth2dl/bin/constants.py
@@ -0,0 +1,37 @@
+# This file is part of the Adblock Plus web scripts,
+# Copyright (C) 2006-present eyeo GmbH
+#
+# Adblock Plus is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 3 as
+# published by the Free Software Foundation.
+#
+# Adblock Plus is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>.
+
+KEYFILE_NOT_FOUND_ERROR = 'ERROR: Oauth2 key file not found! Please specify ' \
Vasily Kuznetsov 2018/07/20 21:00:00 PEP8 [1] recommends breaking long lines by implied
Tudor Avram 2018/07/31 09:20:16 Done.
+ 'it as an optional argument using -k or --key or ' \
+ 'add it to the environment variable OAUTH2DL_KEY.'
+
+SCOPE_NOT_FOUND_ERROR = 'ERROR: Oauth2 scope not found! Please specify it ' \
+ 'as an optional argument using -s or --scope or add ' \
+ 'it to the environment variable OAUTH2DL_SCOPE'
+
+INVALID_KEY_FILE = 'ERROR: Invalid key file format! {0} not found in {1}!'
+
+DUMMY_PRIVATE_KEY = '-----BEGIN RSA PRIVATE KEY-----\nMIIBOgIBAAJBAK8Q+ToR4t' \
+ 'WGshaKYRHKJ3ZmMUF6jjwCS/u1A8v1tFbQiVpBlxYB\npaNcT2ENEXB' \
+ 'GdmWqr8VwSl0NBIKyq4p0rhsCAQMCQHS1+3wL7I5ZzA8G62Exb6RE\n' \
+ 'INZRtCgBh/0jV91OeDnfQUc07SE6vs31J8m7qw/rxeB3E9h6oGi9IVR' \
+ 'ebVO+9zsC\nIQDWb//KAzrSOo0P0yktnY57UF9Q3Y26rulWI6LqpsxZ' \
+ 'DwIhAND/cmlg7rUz34Pf\nSmM61lJEmMEjKp8RB/xgghzmCeI1AiEAj' \
+ 'vVVMVd8jCcItTdwyRO0UjWU4JOz0cnw\n5BfB8cSIO18CIQCLVPbw60' \
+ 'nOIpUClNxCJzmMLbsrbMcUtgVS6wFomVvsIwIhAK+A\nYqT6WwsMW2O' \
+ 'n5l9di+RPzhDT1QdGyTI5eFNS+GxY\n-----END RSA PRIVATE KEY' \
+ '-----'
+
+GOOGLE_OAUTH_ERROR = 'ERROR {0} - {1}'

Powered by Google App Engine
This is Rietveld