Linux server.edchosting.com 4.18.0-553.79.1.lve.el7h.x86_64 #1 SMP Wed Oct 15 16:34:46 UTC 2025 x86_64
LiteSpeed
Server IP : 75.98.162.185 & Your IP : 216.73.216.163
Domains :
Cant Read [ /etc/named.conf ]
User : goons4good
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
lib /
python2.7 /
site-packages /
jwcrypto /
Delete
Unzip
Name
Size
Permission
Date
Action
__init__.py
0
B
-rw-r--r--
2015-07-10 12:38
__init__.pyc
140
B
-rw-r--r--
2018-04-10 20:03
__init__.pyo
140
B
-rw-r--r--
2018-04-10 20:03
common.py
2.82
KB
-rw-r--r--
2017-08-01 04:46
common.pyc
4.64
KB
-rw-r--r--
2018-04-10 20:03
common.pyo
4.64
KB
-rw-r--r--
2018-04-10 20:03
jwa.py
31.26
KB
-rw-r--r--
2017-08-01 04:46
jwa.pyc
41.92
KB
-rw-r--r--
2018-04-10 20:03
jwa.pyo
41.92
KB
-rw-r--r--
2018-04-10 20:03
jwe.py
18.17
KB
-rw-r--r--
2017-08-01 09:22
jwe.pyc
14.71
KB
-rw-r--r--
2018-04-10 20:03
jwe.pyo
14.71
KB
-rw-r--r--
2018-04-10 20:03
jwk.py
28.85
KB
-rw-r--r--
2017-08-01 04:46
jwk.pyc
29.68
KB
-rw-r--r--
2018-04-10 20:03
jwk.pyo
29.68
KB
-rw-r--r--
2018-04-10 20:03
jws.py
18.66
KB
-rw-r--r--
2017-08-01 04:46
jws.pyc
15.82
KB
-rw-r--r--
2018-04-10 20:03
jws.pyo
15.82
KB
-rw-r--r--
2018-04-10 20:03
jwt.py
15.81
KB
-rw-r--r--
2017-08-01 04:46
jwt.pyc
17.21
KB
-rw-r--r--
2018-04-10 20:03
jwt.pyo
17.21
KB
-rw-r--r--
2018-04-10 20:03
Save
Rename
# Copyright (C) 2015 JWCrypto Project Contributors - see LICENSE file import json from base64 import urlsafe_b64decode, urlsafe_b64encode # Padding stripping versions as described in # RFC 7515 Appendix C def base64url_encode(payload): if not isinstance(payload, bytes): payload = payload.encode('utf-8') encode = urlsafe_b64encode(payload) return encode.decode('utf-8').rstrip('=') def base64url_decode(payload): l = len(payload) % 4 if l == 2: payload += '==' elif l == 3: payload += '=' elif l != 0: raise ValueError('Invalid base64 string') return urlsafe_b64decode(payload.encode('utf-8')) # JSON encoding/decoding helpers with good defaults def json_encode(string): if isinstance(string, bytes): string = string.decode('utf-8') return json.dumps(string, separators=(',', ':'), sort_keys=True) def json_decode(string): if isinstance(string, bytes): string = string.decode('utf-8') return json.loads(string) class JWException(Exception): pass class InvalidJWAAlgorithm(JWException): def __init__(self, message=None): msg = 'Invalid JWA Algorithm name' if message: msg += ' (%s)' % message super(InvalidJWAAlgorithm, self).__init__(msg) class InvalidCEKeyLength(JWException): """Invalid CEK Key Length. This exception is raised when a Content Encryption Key does not match the required lenght. """ def __init__(self, expected, obtained): msg = 'Expected key of length %d bits, got %d' % (expected, obtained) super(InvalidCEKeyLength, self).__init__(msg) class InvalidJWEOperation(JWException): """Invalid JWS Object. This exception is raised when a requested operation cannot be execute due to unsatisfied conditions. """ def __init__(self, message=None, exception=None): msg = None if message: msg = message else: msg = 'Unknown Operation Failure' if exception: msg += ' {%s}' % repr(exception) super(InvalidJWEOperation, self).__init__(msg) class InvalidJWEKeyType(JWException): """Invalid JWE Key Type. This exception is raised when the provided JWK Key does not match the type required by the sepcified algorithm. """ def __init__(self, expected, obtained): msg = 'Expected key type %s, got %s' % (expected, obtained) super(InvalidJWEKeyType, self).__init__(msg) class InvalidJWEKeyLength(JWException): """Invalid JWE Key Length. This exception is raised when the provided JWK Key does not match the lenght required by the sepcified algorithm. """ def __init__(self, expected, obtained): msg = 'Expected key of lenght %d, got %d' % (expected, obtained) super(InvalidJWEKeyLength, self).__init__(msg)