diff options
author | Bodo Möller <bodo@openssl.org> | 1999-08-05 11:50:18 +0000 |
---|---|---|
committer | Bodo Möller <bodo@openssl.org> | 1999-08-05 11:50:18 +0000 |
commit | 48c843c3672c49724b3ccb11204b7ae67b17c9cb (patch) | |
tree | 03ca1f8cbf340b0ca140c09d8dc28526f7b62fd8 /crypto/asn1 | |
parent | 90f14e251e2e9836a33bc7ac752abea48e3439af (diff) |
New function DSA_dup_DH, and fixes for bugs that were found
while implementing and using it.
Diffstat (limited to 'crypto/asn1')
-rw-r--r-- | crypto/asn1/Makefile.ssl | 41 | ||||
-rw-r--r-- | crypto/asn1/i2d_dhp.c | 7 |
2 files changed, 29 insertions, 19 deletions
diff --git a/crypto/asn1/Makefile.ssl b/crypto/asn1/Makefile.ssl index 66c1136f67..541d1dac4a 100644 --- a/crypto/asn1/Makefile.ssl +++ b/crypto/asn1/Makefile.ssl @@ -346,9 +346,10 @@ d2i_dhp.o: ../../include/openssl/stack.h ../cryptlib.h d2i_dsap.o: ../../include/openssl/asn1.h ../../include/openssl/asn1_mac.h d2i_dsap.o: ../../include/openssl/bio.h ../../include/openssl/bn.h d2i_dsap.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h -d2i_dsap.o: ../../include/openssl/dsa.h ../../include/openssl/e_os.h -d2i_dsap.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h -d2i_dsap.o: ../../include/openssl/objects.h ../../include/openssl/opensslconf.h +d2i_dsap.o: ../../include/openssl/dh.h ../../include/openssl/dsa.h +d2i_dsap.o: ../../include/openssl/e_os.h ../../include/openssl/e_os2.h +d2i_dsap.o: ../../include/openssl/err.h ../../include/openssl/objects.h +d2i_dsap.o: ../../include/openssl/opensslconf.h d2i_dsap.o: ../../include/openssl/opensslv.h ../../include/openssl/safestack.h d2i_dsap.o: ../../include/openssl/stack.h ../cryptlib.h d2i_pr.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h @@ -402,17 +403,19 @@ d2i_r_pu.o: ../cryptlib.h d2i_s_pr.o: ../../include/openssl/asn1.h ../../include/openssl/asn1_mac.h d2i_s_pr.o: ../../include/openssl/bio.h ../../include/openssl/bn.h d2i_s_pr.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h -d2i_s_pr.o: ../../include/openssl/dsa.h ../../include/openssl/e_os.h -d2i_s_pr.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h -d2i_s_pr.o: ../../include/openssl/objects.h ../../include/openssl/opensslconf.h +d2i_s_pr.o: ../../include/openssl/dh.h ../../include/openssl/dsa.h +d2i_s_pr.o: ../../include/openssl/e_os.h ../../include/openssl/e_os2.h +d2i_s_pr.o: ../../include/openssl/err.h ../../include/openssl/objects.h +d2i_s_pr.o: ../../include/openssl/opensslconf.h d2i_s_pr.o: ../../include/openssl/opensslv.h ../../include/openssl/safestack.h d2i_s_pr.o: ../../include/openssl/stack.h ../cryptlib.h d2i_s_pu.o: ../../include/openssl/asn1.h ../../include/openssl/asn1_mac.h d2i_s_pu.o: ../../include/openssl/bio.h ../../include/openssl/bn.h d2i_s_pu.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h -d2i_s_pu.o: ../../include/openssl/dsa.h ../../include/openssl/e_os.h -d2i_s_pu.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h -d2i_s_pu.o: ../../include/openssl/objects.h ../../include/openssl/opensslconf.h +d2i_s_pu.o: ../../include/openssl/dh.h ../../include/openssl/dsa.h +d2i_s_pu.o: ../../include/openssl/e_os.h ../../include/openssl/e_os2.h +d2i_s_pu.o: ../../include/openssl/err.h ../../include/openssl/objects.h +d2i_s_pu.o: ../../include/openssl/opensslconf.h d2i_s_pu.o: ../../include/openssl/opensslv.h ../../include/openssl/safestack.h d2i_s_pu.o: ../../include/openssl/stack.h ../cryptlib.h evp_asn1.o: ../../include/openssl/asn1.h ../../include/openssl/asn1_mac.h @@ -454,9 +457,9 @@ i2d_dhp.o: ../cryptlib.h i2d_dsap.o: ../../include/openssl/asn1.h ../../include/openssl/asn1_mac.h i2d_dsap.o: ../../include/openssl/bio.h ../../include/openssl/bn.h i2d_dsap.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h -i2d_dsap.o: ../../include/openssl/dsa.h ../../include/openssl/e_os.h -i2d_dsap.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h -i2d_dsap.o: ../../include/openssl/opensslconf.h +i2d_dsap.o: ../../include/openssl/dh.h ../../include/openssl/dsa.h +i2d_dsap.o: ../../include/openssl/e_os.h ../../include/openssl/e_os2.h +i2d_dsap.o: ../../include/openssl/err.h ../../include/openssl/opensslconf.h i2d_dsap.o: ../../include/openssl/opensslv.h ../../include/openssl/safestack.h i2d_dsap.o: ../../include/openssl/stack.h ../cryptlib.h i2d_pr.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h @@ -510,17 +513,19 @@ i2d_r_pu.o: ../cryptlib.h i2d_s_pr.o: ../../include/openssl/asn1.h ../../include/openssl/asn1_mac.h i2d_s_pr.o: ../../include/openssl/bio.h ../../include/openssl/bn.h i2d_s_pr.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h -i2d_s_pr.o: ../../include/openssl/dsa.h ../../include/openssl/e_os.h -i2d_s_pr.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h -i2d_s_pr.o: ../../include/openssl/objects.h ../../include/openssl/opensslconf.h +i2d_s_pr.o: ../../include/openssl/dh.h ../../include/openssl/dsa.h +i2d_s_pr.o: ../../include/openssl/e_os.h ../../include/openssl/e_os2.h +i2d_s_pr.o: ../../include/openssl/err.h ../../include/openssl/objects.h +i2d_s_pr.o: ../../include/openssl/opensslconf.h i2d_s_pr.o: ../../include/openssl/opensslv.h ../../include/openssl/safestack.h i2d_s_pr.o: ../../include/openssl/stack.h ../cryptlib.h i2d_s_pu.o: ../../include/openssl/asn1.h ../../include/openssl/asn1_mac.h i2d_s_pu.o: ../../include/openssl/bio.h ../../include/openssl/bn.h i2d_s_pu.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h -i2d_s_pu.o: ../../include/openssl/dsa.h ../../include/openssl/e_os.h -i2d_s_pu.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h -i2d_s_pu.o: ../../include/openssl/objects.h ../../include/openssl/opensslconf.h +i2d_s_pu.o: ../../include/openssl/dh.h ../../include/openssl/dsa.h +i2d_s_pu.o: ../../include/openssl/e_os.h ../../include/openssl/e_os2.h +i2d_s_pu.o: ../../include/openssl/err.h ../../include/openssl/objects.h +i2d_s_pu.o: ../../include/openssl/opensslconf.h i2d_s_pu.o: ../../include/openssl/opensslv.h ../../include/openssl/safestack.h i2d_s_pu.o: ../../include/openssl/stack.h ../cryptlib.h n_pkey.o: ../../include/openssl/asn1.h ../../include/openssl/asn1_mac.h diff --git a/crypto/asn1/i2d_dhp.c b/crypto/asn1/i2d_dhp.c index 1b2b4b8ebe..fdda4ec41b 100644 --- a/crypto/asn1/i2d_dhp.c +++ b/crypto/asn1/i2d_dhp.c @@ -94,7 +94,12 @@ int i2d_DHparams(DH *a, unsigned char **pp) } t=ASN1_object_size(1,tot,V_ASN1_SEQUENCE); - if (pp == NULL) return(t); + if (pp == NULL) + { + if (num[2] != NULL) + BN_free(num[2]); + return(t); + } p= *pp; ASN1_put_object(&p,1,tot,V_ASN1_SEQUENCE,V_ASN1_UNIVERSAL); |