aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Kehrer <paul.l.kehrer@gmail.com>2014-04-24 20:06:57 -0500
committerPaul Kehrer <paul.l.kehrer@gmail.com>2014-04-24 20:11:45 -0500
commit31d449e31db013500f57b4e2389c2489a39d2b6e (patch)
tree67e7f7d8463cec7a0924b9db36d69616b7b7f7af
parentdcf63ab6bcee9d5a4ae837186db8f0804ddca62c (diff)
downloadcryptography-31d449e31db013500f57b4e2389c2489a39d2b6e.tar.gz
cryptography-31d449e31db013500f57b4e2389c2489a39d2b6e.tar.bz2
cryptography-31d449e31db013500f57b4e2389c2489a39d2b6e.zip
add more d2i/i2d bindings because sometimes you just don't want bios
-rw-r--r--cryptography/hazmat/bindings/openssl/x509.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/cryptography/hazmat/bindings/openssl/x509.py b/cryptography/hazmat/bindings/openssl/x509.py
index 92870369..68658ebf 100644
--- a/cryptography/hazmat/bindings/openssl/x509.py
+++ b/cryptography/hazmat/bindings/openssl/x509.py
@@ -183,8 +183,13 @@ const char *X509_get_default_private_dir(void);
int i2d_RSA_PUBKEY(RSA *, unsigned char **);
RSA *d2i_RSA_PUBKEY(RSA **, const unsigned char **, long);
+RSA * d2i_RSAPublicKey(RSA **, const unsigned char **, long);
+RSA *d2i_RSAPrivateKey(RSA **, const unsigned char **, long);
int i2d_DSA_PUBKEY(DSA *, unsigned char **);
DSA *d2i_DSA_PUBKEY(DSA **, const unsigned char **, long);
+DSA * d2i_DSAPublicKey(DSA **, const unsigned char **, long);
+DSA *d2i_DSAPrivateKey(DSA **, const unsigned char **, long);
+
RSA *d2i_RSAPrivateKey_bio(BIO *, RSA **);
int i2d_RSAPrivateKey_bio(BIO *, RSA *);
@@ -223,6 +228,11 @@ void sk_X509_EXTENSION_free(X509_EXTENSIONS *);
int sk_X509_REVOKED_num(Cryptography_STACK_OF_X509_REVOKED *);
X509_REVOKED *sk_X509_REVOKED_value(Cryptography_STACK_OF_X509_REVOKED *, int);
+int i2d_RSAPublicKey(RSA *, unsigned char **);
+int i2d_RSAPrivateKey(RSA *, unsigned char **);
+int i2d_DSAPublicKey(DSA *, unsigned char **);
+int i2d_DSAPrivateKey(DSA *, unsigned char **);
+
/* These aren't macros these arguments are all const X on openssl > 1.0.x */
int X509_CRL_set_lastUpdate(X509_CRL *, ASN1_TIME *);
int X509_CRL_set_nextUpdate(X509_CRL *, ASN1_TIME *);