Fix for a bug in PKCS#7 code and non-detached data.
[openssl.git] / apps / apps.c
index 3a27f2c6f140b4ae7131e315ebe8c03d7796a410..4e3f32d07a0608ffb93f11652ada2d3538195579 100644 (file)
@@ -325,7 +325,7 @@ int app_init(long mesgwin)
        }
 #endif
 
-int MS_CALLBACK key_callback(char *buf, int len, int verify, void *key)
+int MS_CALLBACK key_cb(char *buf, int len, int verify, void *key)
        {
        int i;
 
@@ -335,3 +335,17 @@ int MS_CALLBACK key_callback(char *buf, int len, int verify, void *key)
        memcpy(buf,key,i);
        return(i);
        }
+
+int dump_cert_text (BIO *out, X509 *x)
+{
+       char buf[256];
+       X509_NAME_oneline(X509_get_subject_name(x),buf,256);
+       BIO_puts(out,"subject=");
+       BIO_puts(out,buf);
+
+       X509_NAME_oneline(X509_get_issuer_name(x),buf,256);
+       BIO_puts(out,"\nissuer= ");
+       BIO_puts(out,buf);
+       BIO_puts(out,"\n");
+        return 0;
+}