diff options
author | Bodo Möller <bodo@openssl.org> | 1999-05-14 11:52:49 +0000 |
---|---|---|
committer | Bodo Möller <bodo@openssl.org> | 1999-05-14 11:52:49 +0000 |
commit | 3ae76679c7aeebd455173bb65b720b97c3261a79 (patch) | |
tree | d70e32471e9e5b4de8439eaf50484caaba4c04bb /ssl | |
parent | e6d0b6eca3d630d2ee306a61782fdfebce146478 (diff) | |
download | openssl-new-3ae76679c7aeebd455173bb65b720b97c3261a79.tar.gz |
Introduce and use function typedef pem_password_cb so that we don't call
those functions without having a parameter list declaration.
(There are various similar cases left ...)
Diffstat (limited to 'ssl')
-rw-r--r-- | ssl/ssl.h | 5 | ||||
-rw-r--r-- | ssl/ssl_lib.c | 2 |
2 files changed, 4 insertions, 3 deletions
@@ -148,6 +148,7 @@ extern "C" { #include <openssl/lhash.h> #include <openssl/buffer.h> #include <openssl/bio.h> +#include <openssl/pem.h> #include <openssl/x509.h> #define SSL_FILETYPE_ASN1 X509_FILETYPE_ASN1 @@ -402,7 +403,7 @@ struct ssl_ctx_st /**/ int (*default_verify_callback)(int ok,X509_STORE_CTX *ctx); /* Default password callback. */ -/**/ int (*default_passwd_callback)(); +/**/ pem_password_cb *default_passwd_callback; /* get client cert callback */ /**/ int (*client_cert_cb)(/* SSL *ssl, X509 **x509, EVP_PKEY **pkey */); @@ -954,7 +955,7 @@ int SSL_CTX_use_PrivateKey_ASN1(int pk,SSL_CTX *ctx, int SSL_CTX_use_certificate(SSL_CTX *ctx, X509 *x); int SSL_CTX_use_certificate_ASN1(SSL_CTX *ctx, int len, unsigned char *d); -void SSL_CTX_set_default_passwd_cb(SSL_CTX *ctx,int (*cb)()); +void SSL_CTX_set_default_passwd_cb(SSL_CTX *ctx, pem_password_cb *); int SSL_CTX_check_private_key(SSL_CTX *ctx); int SSL_check_private_key(SSL *ctx); diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 666dba54cf..09c837cc97 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -1115,7 +1115,7 @@ void SSL_CTX_free(SSL_CTX *a) Free((char *)a); } -void SSL_CTX_set_default_passwd_cb(SSL_CTX *ctx,int (*cb)()) +void SSL_CTX_set_default_passwd_cb(SSL_CTX *ctx, pem_password_cb *cb) { ctx->default_passwd_callback=cb; } |