crypto/ecp_nistz256.c: harmonize error codes.
[oweals/openssl.git] / crypto / ec / eck_prn.c
index 06de8f3959d57d2bdebe85ea7ab2d5b3c3a414fe..45e0109bb6902e7d75912408e76c99e9e12d47af 100644 (file)
@@ -177,6 +177,7 @@ int ECPKParameters_print(BIO *bp, const EC_GROUP *x, int off)
                {
                /* the curve parameter are given by an asn1 OID */
                int nid;
+               const char *nname;
 
                if (!BIO_indent(bp, off, 128))
                        goto err;
@@ -189,6 +190,14 @@ int ECPKParameters_print(BIO *bp, const EC_GROUP *x, int off)
                        goto err;
                if (BIO_printf(bp, "\n") <= 0)
                        goto err;
+               nname = EC_curve_nid2nist(nid);
+               if (nname)
+                       {
+                       if (!BIO_indent(bp, off, 128))
+                               goto err;
+                       if (BIO_printf(bp, "NIST CURVE: %s\n", nname) <= 0)
+                               goto err;
+                       }
                }
        else
                {