feat: add cryptography as required dependency (#1929)
The `rsa` library has been deprecated and archived. This PR adds
`cryptography` as a the new preferred backend for RSA operations
In the short term, both `rsa` and `cryptography` will be listed as
dependencies. Soon, `rsa` will be removed, but still supported as an
optional dependency. Eventually, it will be completely removed from the
codebase.
As a part of this change, I introduced new RSASigner and RSAVerifier
wrapper classes, that can use either cryptography or rsa
implementations. Previously, the library would only import one or the
other, depending on if cryptography was installed. This simplifies the
import structure, and puts rsa and cryptography on equal footing
Fixes
https://github.com/googleapis/google-auth-library-python/issues/912
Towards
https://github.com/googleapis/google-auth-library-python/issues/1810
Towards
https://github.com/googleapis/google-auth-library-python/issues/941
---------
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
8 files changed