diff options
author | Fraser Tweedale <frase@frase.id.au> | 2016-11-12 01:28:56 +1000 |
---|---|---|
committer | Paul Kehrer <paul.l.kehrer@gmail.com> | 2016-11-11 07:28:56 -0800 |
commit | 01ee6f5e391eee76e6cd3062de8fc84851bd06e3 (patch) | |
tree | 3309443a73201bcec03c5bb14df019e49eae798c /src/_cffi_src | |
parent | 44eb89e911db7298a29640c9073c9e2ff4d5f806 (diff) | |
download | cryptography-01ee6f5e391eee76e6cd3062de8fc84851bd06e3.tar.gz cryptography-01ee6f5e391eee76e6cd3062de8fc84851bd06e3.tar.bz2 cryptography-01ee6f5e391eee76e6cd3062de8fc84851bd06e3.zip |
Name: add support for multi-value RDNs (#3202)
Update the Name class to accept and internally store a list of
RelativeDistinguishedName objects. Add the 'rdns' attribute to give
access to the RDNs. Update ASN.1 routines to correctly decode and
encode multi-value RDNs.
Fixes: https://github.com/pyca/cryptography/issues/3199
Diffstat (limited to 'src/_cffi_src')
-rw-r--r-- | src/_cffi_src/openssl/x509name.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/_cffi_src/openssl/x509name.py b/src/_cffi_src/openssl/x509name.py index 30acbdbb..0554a024 100644 --- a/src/_cffi_src/openssl/x509name.py +++ b/src/_cffi_src/openssl/x509name.py @@ -35,6 +35,7 @@ void X509_NAME_ENTRY_free(X509_NAME_ENTRY *); int X509_NAME_get_index_by_NID(X509_NAME *, int, int); int X509_NAME_cmp(const X509_NAME *, const X509_NAME *); X509_NAME *X509_NAME_dup(X509_NAME *); +int Cryptography_X509_NAME_ENTRY_set(X509_NAME_ENTRY *); """ MACROS = """ @@ -76,4 +77,13 @@ Cryptography_STACK_OF_X509_NAME_ENTRY *sk_X509_NAME_ENTRY_dup( """ CUSTOMIZATIONS = """ +#if CRYPTOGRAPHY_OPENSSL_110_OR_GREATER && !defined(LIBRESSL_VERSION_NUMBER) +int Cryptography_X509_NAME_ENTRY_set(X509_NAME_ENTRY *ne) { + return X509_NAME_ENTRY_set(ne); +} +#else +int Cryptography_X509_NAME_ENTRY_set(X509_NAME_ENTRY *ne) { + return ne->set; +} +#endif """ |