summaryrefslogtreecommitdiffstats
path: root/crypto/asn1/t_x509.c
diff options
context:
space:
mode:
authorBodo Möller <bodo@openssl.org>2002-02-13 18:21:51 +0000
committerBodo Möller <bodo@openssl.org>2002-02-13 18:21:51 +0000
commit4d94ae00d5614d64d4dd065860c4b00161a81f82 (patch)
treee993aa323ea753b3c0782439eb78f4f8c896a67e /crypto/asn1/t_x509.c
parent60d8bae30d1040a4f955e3247443b2dd4c674cde (diff)
ECDSA support
Submitted by: Nils Larsch <nla@trustcenter.de>
Diffstat (limited to 'crypto/asn1/t_x509.c')
-rw-r--r--crypto/asn1/t_x509.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/crypto/asn1/t_x509.c b/crypto/asn1/t_x509.c
index 5de4833ed0..ae6d5ce041 100644
--- a/crypto/asn1/t_x509.c
+++ b/crypto/asn1/t_x509.c
@@ -66,6 +66,9 @@
#ifndef OPENSSL_NO_DSA
#include <openssl/dsa.h>
#endif
+#ifndef OPENSSL_NO_ECDSA
+#include <openssl/ecdsa.h>
+#endif
#include <openssl/objects.h>
#include <openssl/x509.h>
#include <openssl/x509v3.h>
@@ -229,6 +232,14 @@ int X509_print_ex(BIO *bp, X509 *x, unsigned long nmflags, unsigned long cflag)
}
else
#endif
+#ifndef OPENSSL_NO_ECDSA
+ if (pkey->type == EVP_PKEY_ECDSA)
+ {
+ BIO_printf(bp, "%12sECDSA Public Key:\n","");
+ ECDSA_print(bp, pkey->pkey.ecdsa, 16);
+ }
+ else
+#endif
BIO_printf(bp,"%12sUnknown Public Key:\n","");
EVP_PKEY_free(pkey);