Skip to content

Commit 2ed5f56

Browse files
committed
Remove support for legacy dependencies
1 parent ebcbed4 commit 2ed5f56

File tree

10 files changed

+3
-732
lines changed

10 files changed

+3
-732
lines changed

.travis.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ matrix:
44
- python: 3.8
55
env: TOXENV=lint,typing
66
- python: 3.5
7-
env: TOXENV=py35-crypto,py35-nocrypto,py35-contrib_crypto
7+
env: TOXENV=py35-crypto,py35-nocrypto
88
- python: 3.6
9-
env: TOXENV=py36-crypto,py36-nocrypto,py36-contrib_crypto
9+
env: TOXENV=py36-crypto,py36-nocrypto
1010
- python: 3.7
11-
env: TOXENV=py37-crypto,py37-nocrypto,py37-contrib_crypto
11+
env: TOXENV=py37-crypto,py37-nocrypto
1212
- python: 3.8
1313
env: TOXENV=py38-crypto,py38-nocrypto
1414
install:

docs/installation.rst

Lines changed: 0 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -23,39 +23,4 @@ The ``pyjwt[crypto]`` format is recommended in requirements files in
2323
projects using ``PyJWT``, as a separate ``cryptography`` requirement line
2424
may later be mistaken for an unused requirement and removed.
2525

26-
.. _legacy-deps:
27-
28-
Legacy Dependencies
29-
-------------------
30-
31-
Some environments, most notably Google App Engine, do not allow the installation
32-
of Python packages that require compilation of C extensions and therefore
33-
cannot install ``cryptography``. If you can install ``cryptography``, you
34-
should disregard this section.
35-
36-
If you are deploying an application to one of these environments, you may
37-
need to use the legacy implementations of the digital signature algorithms:
38-
39-
.. code-block:: console
40-
41-
$ pip install pycrypto ecdsa
42-
43-
Once you have installed ``pycrypto`` and ``ecdcsa``, you can tell PyJWT to use
44-
the legacy implementations with ``jwt.register_algorithm()``. The following
45-
example code shows how to configure PyJWT to use the legacy implementations
46-
for RSA with SHA256 and EC with SHA256 signatures.
47-
48-
.. code-block:: python
49-
50-
import jwt
51-
from jwt.contrib.algorithms.pycrypto import RSAAlgorithm
52-
from jwt.contrib.algorithms.py_ecdsa import ECAlgorithm
53-
54-
jwt.unregister_algorithm('RS256')
55-
jwt.unregister_algorithm('ES256')
56-
57-
jwt.register_algorithm('RS256', RSAAlgorithm(RSAAlgorithm.SHA256))
58-
jwt.register_algorithm('ES256', ECAlgorithm(ECAlgorithm.SHA256))
59-
60-
6126
.. _`cryptography`: https://cryptography.io

jwt/contrib/__init__.py

Whitespace-only changes.

jwt/contrib/algorithms/__init__.py

Whitespace-only changes.

jwt/contrib/algorithms/py_ecdsa.py

Lines changed: 0 additions & 69 deletions
This file was deleted.

jwt/contrib/algorithms/pycrypto.py

Lines changed: 0 additions & 47 deletions
This file was deleted.

jwt/contrib/algorithms/pycryptodome.py

Lines changed: 0 additions & 125 deletions
This file was deleted.

tests/contrib/__init__.py

Whitespace-only changes.

0 commit comments

Comments
 (0)