aboutsummaryrefslogtreecommitdiffstats
path: root/src/_cffi_src/openssl/x509.py
diff options
context:
space:
mode:
authorPaul Kehrer <paul.l.kehrer@gmail.com>2016-03-12 20:04:43 -0400
committerPaul Kehrer <paul.l.kehrer@gmail.com>2016-03-12 20:04:43 -0400
commitfb39352087eaed8ba8d3687833a06a4a75944891 (patch)
treee3f6a516440cd81a655725a1778b3d414c5fdab6 /src/_cffi_src/openssl/x509.py
parent5d3965bbfad2364c45e3a5e4cb9cd11b87fd2d83 (diff)
downloadcryptography-fb39352087eaed8ba8d3687833a06a4a75944891.tar.gz
cryptography-fb39352087eaed8ba8d3687833a06a4a75944891.tar.bz2
cryptography-fb39352087eaed8ba8d3687833a06a4a75944891.zip
improve comments
Diffstat (limited to 'src/_cffi_src/openssl/x509.py')
-rw-r--r--src/_cffi_src/openssl/x509.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/_cffi_src/openssl/x509.py b/src/_cffi_src/openssl/x509.py
index d3145f58..4484a8ac 100644
--- a/src/_cffi_src/openssl/x509.py
+++ b/src/_cffi_src/openssl/x509.py
@@ -373,10 +373,11 @@ void X509_get0_signature(ASN1_BIT_STRING **psig, X509_ALGOR **palg,
/* from x509/x_x509.c */
int i2d_re_X509_tbs(X509 *x, unsigned char **pp)
{
- /* In 1.0.1 and below cert_info is a pointer in the struct, so
- we don't want to pass by reference. */
- /* ideally we also call x->cert_info->enc.modified = 1 as 1.0.2+ does, but
- older OpenSSLs don't have the enc ASN1_ENCODING on the struct */
+ /* in 1.0.2+ this function also sets x->cert_info->enc.modified = 1
+ but older OpenSSLs don't have the enc ASN1_ENCODING member in the
+ X509 struct. Setting modified to 1 marks the encoding
+ (x->cert_info->enc.enc) as invalid, but since the entire struct isn't
+ present we don't care. */
return i2d_X509_CINF(x->cert_info, pp);
}
#endif