Python cryptography.x509.CertificateRevocationList() Examples
The following are 14
code examples of cryptography.x509.CertificateRevocationList().
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example.
You may also want to check out all available functions/classes of the module
cryptography.x509
, or try the search function
.
Example #1
Source File: crypto.py From learn_python3_spider with MIT License | 6 votes |
def from_cryptography(cls, crypto_crl): """ Construct based on a ``cryptography`` *crypto_crl*. :param crypto_crl: A ``cryptography`` certificate revocation list :type crypto_crl: ``cryptography.x509.CertificateRevocationList`` :rtype: CRL .. versionadded:: 17.1.0 """ if not isinstance(crypto_crl, x509.CertificateRevocationList): raise TypeError("Must be a certificate revocation list") crl = cls() crl._crl = crypto_crl._x509_crl return crl
Example #2
Source File: crypto.py From pyopenssl with Apache License 2.0 | 6 votes |
def from_cryptography(cls, crypto_crl): """ Construct based on a ``cryptography`` *crypto_crl*. :param crypto_crl: A ``cryptography`` certificate revocation list :type crypto_crl: ``cryptography.x509.CertificateRevocationList`` :rtype: CRL .. versionadded:: 17.1.0 """ if not isinstance(crypto_crl, x509.CertificateRevocationList): raise TypeError("Must be a certificate revocation list") crl = cls() crl._crl = crypto_crl._x509_crl return crl
Example #3
Source File: x509.py From oss-ftp with MIT License | 5 votes |
def __eq__(self, other): if not isinstance(other, x509.CertificateRevocationList): return NotImplemented res = self._backend._lib.X509_CRL_cmp(self._x509_crl, other._x509_crl) return res == 0
Example #4
Source File: x509.py From Safejumper-for-Desktop with GNU General Public License v2.0 | 5 votes |
def __eq__(self, other): if not isinstance(other, x509.CertificateRevocationList): return NotImplemented res = self._backend._lib.X509_CRL_cmp(self._x509_crl, other._x509_crl) return res == 0
Example #5
Source File: x509.py From teleport with Apache License 2.0 | 5 votes |
def __eq__(self, other): if not isinstance(other, x509.CertificateRevocationList): return NotImplemented res = self._backend._lib.X509_CRL_cmp(self._x509_crl, other._x509_crl) return res == 0
Example #6
Source File: x509.py From teleport with Apache License 2.0 | 5 votes |
def __eq__(self, other): if not isinstance(other, x509.CertificateRevocationList): return NotImplemented res = self._backend._lib.X509_CRL_cmp(self._x509_crl, other._x509_crl) return res == 0
Example #7
Source File: x509.py From teleport with Apache License 2.0 | 5 votes |
def __eq__(self, other): if not isinstance(other, x509.CertificateRevocationList): return NotImplemented res = self._backend._lib.X509_CRL_cmp(self._x509_crl, other._x509_crl) return res == 0
Example #8
Source File: crypto.py From learn_python3_spider with MIT License | 5 votes |
def to_cryptography(self): """ Export as a ``cryptography`` CRL. :rtype: ``cryptography.x509.CertificateRevocationList`` .. versionadded:: 17.1.0 """ from cryptography.hazmat.backends.openssl.x509 import ( _CertificateRevocationList ) backend = _get_backend() return _CertificateRevocationList(backend, self._crl)
Example #9
Source File: x509.py From learn_python3_spider with MIT License | 5 votes |
def __eq__(self, other): if not isinstance(other, x509.CertificateRevocationList): return NotImplemented res = self._backend._lib.X509_CRL_cmp(self._x509_crl, other._x509_crl) return res == 0
Example #10
Source File: x509.py From quickstart-git2s3 with Apache License 2.0 | 5 votes |
def __eq__(self, other): if not isinstance(other, x509.CertificateRevocationList): return NotImplemented res = self._backend._lib.X509_CRL_cmp(self._x509_crl, other._x509_crl) return res == 0
Example #11
Source File: crypto.py From pyopenssl with Apache License 2.0 | 5 votes |
def to_cryptography(self): """ Export as a ``cryptography`` CRL. :rtype: ``cryptography.x509.CertificateRevocationList`` .. versionadded:: 17.1.0 """ from cryptography.hazmat.backends.openssl.x509 import ( _CertificateRevocationList ) backend = _get_backend() return _CertificateRevocationList(backend, self._crl)
Example #12
Source File: test_crypto.py From pyopenssl with Apache License 2.0 | 5 votes |
def test_convert_to_cryptography_key(self): crl = load_crl(FILETYPE_PEM, crlData) crypto_crl = crl.to_cryptography() assert isinstance(crypto_crl, x509.CertificateRevocationList)
Example #13
Source File: x509.py From quickstart-redhat-openshift with Apache License 2.0 | 5 votes |
def __eq__(self, other): if not isinstance(other, x509.CertificateRevocationList): return NotImplemented res = self._backend._lib.X509_CRL_cmp(self._x509_crl, other._x509_crl) return res == 0
Example #14
Source File: x509.py From Carnets with BSD 3-Clause "New" or "Revised" License | 5 votes |
def __eq__(self, other): if not isinstance(other, x509.CertificateRevocationList): return NotImplemented res = self._backend._lib.X509_CRL_cmp(self._x509_crl, other._x509_crl) return res == 0