aboutsummaryrefslogtreecommitdiff
path: root/crypto/asn1
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2014-10-31 00:01:18 +0000
committerMatt Caswell <matt@openssl.org>2014-12-08 21:40:26 +0000
commit76b2a0227433af6c100aadf9a3df78ea4d52803a (patch)
tree1f21a7eeda18c56606e4af84510bb08c3a9a733f /crypto/asn1
parent7a5233118ca655ab69387423e26ffb9de20dbaa5 (diff)
downloadopenssl-76b2a0227433af6c100aadf9a3df78ea4d52803a.zip
openssl-76b2a0227433af6c100aadf9a3df78ea4d52803a.tar.gz
openssl-76b2a0227433af6c100aadf9a3df78ea4d52803a.tar.bz2
Implement internally opaque bn access from asn1
Reviewed-by: Tim Hudson <tjh@openssl.org>
Diffstat (limited to 'crypto/asn1')
-rw-r--r--crypto/asn1/Makefile2
-rw-r--r--crypto/asn1/t_pkey.c6
2 files changed, 4 insertions, 4 deletions
diff --git a/crypto/asn1/Makefile b/crypto/asn1/Makefile
index 4ea6fb8..a7b6c35 100644
--- a/crypto/asn1/Makefile
+++ b/crypto/asn1/Makefile
@@ -612,7 +612,7 @@ t_pkey.o: ../../include/openssl/obj_mac.h ../../include/openssl/objects.h
t_pkey.o: ../../include/openssl/opensslconf.h ../../include/openssl/opensslv.h
t_pkey.o: ../../include/openssl/ossl_typ.h ../../include/openssl/safestack.h
t_pkey.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h
-t_pkey.o: ../cryptlib.h t_pkey.c
+t_pkey.o: ../cryptlib.h ../include/internal/bn_int.h t_pkey.c
t_req.o: ../../e_os.h ../../include/openssl/asn1.h ../../include/openssl/bio.h
t_req.o: ../../include/openssl/bn.h ../../include/openssl/buffer.h
t_req.o: ../../include/openssl/conf.h ../../include/openssl/crypto.h
diff --git a/crypto/asn1/t_pkey.c b/crypto/asn1/t_pkey.c
index 9dd18f6..44f7183 100644
--- a/crypto/asn1/t_pkey.c
+++ b/crypto/asn1/t_pkey.c
@@ -60,7 +60,7 @@
#include "cryptlib.h"
#include <openssl/objects.h>
#include <openssl/buffer.h>
-#include <openssl/bn.h>
+#include "internal/bn_int.h"
int ASN1_bn_print(BIO *bp, const char *number, const BIGNUM *num,
unsigned char *buf, int off)
@@ -82,8 +82,8 @@ int ASN1_bn_print(BIO *bp, const char *number, const BIGNUM *num,
if (BN_num_bytes(num) <= BN_BYTES)
{
if (BIO_printf(bp,"%s %s%lu (%s0x%lx)\n",number,neg,
- (unsigned long)num->d[0],neg,(unsigned long)num->d[0])
- <= 0) return(0);
+ (unsigned long)bn_get_words(num)[0],neg,
+ (unsigned long)bn_get_words(num)[0])<= 0) return(0);
}
else
{