diff options
author | 2018-05-18 17:46:17 +0000 | |
---|---|---|
committer | 2018-05-18 17:46:17 +0000 | |
commit | 4de46f6f06e17f6171174f6da38e67f5e72b9e68 (patch) | |
tree | f1925296ea7ef45ba6fbf6802755f56821c5f272 | |
parent | negative assertions only work well on constant-width regexp, do things (diff) | |
download | wireguard-openbsd-4de46f6f06e17f6171174f6da38e67f5e72b9e68.tar.xz wireguard-openbsd-4de46f6f06e17f6171174f6da38e67f5e72b9e68.zip |
X509_LOOKUP_by_alias() now takes a 'const char str *' and
X509_LOOKUP_by_fingerprint() 'const unsigned char *bytes'.
tested in a bulk build by sthen
ok jsing
-rw-r--r-- | lib/libcrypto/x509/x509_lu.c | 8 | ||||
-rw-r--r-- | lib/libcrypto/x509/x509_vfy.h | 10 |
2 files changed, 9 insertions, 9 deletions
diff --git a/lib/libcrypto/x509/x509_lu.c b/lib/libcrypto/x509/x509_lu.c index 742eb4d2bf6..5121ae31ec1 100644 --- a/lib/libcrypto/x509/x509_lu.c +++ b/lib/libcrypto/x509/x509_lu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_lu.c,v 1.28 2018/03/17 15:43:32 tb Exp $ */ +/* $OpenBSD: x509_lu.c,v 1.29 2018/05/18 17:46:17 tb Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -154,8 +154,8 @@ X509_LOOKUP_by_issuer_serial(X509_LOOKUP *ctx, int type, X509_NAME *name, } int -X509_LOOKUP_by_fingerprint(X509_LOOKUP *ctx, int type, unsigned char *bytes, - int len, X509_OBJECT *ret) +X509_LOOKUP_by_fingerprint(X509_LOOKUP *ctx, int type, + const unsigned char *bytes, int len, X509_OBJECT *ret) { if ((ctx->method == NULL) || (ctx->method->get_by_fingerprint == NULL)) return X509_LU_FAIL; @@ -163,7 +163,7 @@ X509_LOOKUP_by_fingerprint(X509_LOOKUP *ctx, int type, unsigned char *bytes, } int -X509_LOOKUP_by_alias(X509_LOOKUP *ctx, int type, char *str, int len, +X509_LOOKUP_by_alias(X509_LOOKUP *ctx, int type, const char *str, int len, X509_OBJECT *ret) { if ((ctx->method == NULL) || (ctx->method->get_by_alias == NULL)) diff --git a/lib/libcrypto/x509/x509_vfy.h b/lib/libcrypto/x509/x509_vfy.h index 9e0730b0147..ee9290347b2 100644 --- a/lib/libcrypto/x509/x509_vfy.h +++ b/lib/libcrypto/x509/x509_vfy.h @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_vfy.h,v 1.27 2018/03/20 15:26:22 jsing Exp $ */ +/* $OpenBSD: x509_vfy.h,v 1.28 2018/05/18 17:46:17 tb Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -141,9 +141,9 @@ typedef struct x509_lookup_method_st int (*get_by_issuer_serial)(X509_LOOKUP *ctx,int type,X509_NAME *name, ASN1_INTEGER *serial,X509_OBJECT *ret); int (*get_by_fingerprint)(X509_LOOKUP *ctx,int type, - unsigned char *bytes,int len, + const unsigned char *bytes,int len, X509_OBJECT *ret); - int (*get_by_alias)(X509_LOOKUP *ctx,int type,char *str,int len, + int (*get_by_alias)(X509_LOOKUP *ctx,int type, const char *str,int len, X509_OBJECT *ret); } X509_LOOKUP_METHOD; @@ -496,8 +496,8 @@ int X509_LOOKUP_by_subject(X509_LOOKUP *ctx, int type, X509_NAME *name, int X509_LOOKUP_by_issuer_serial(X509_LOOKUP *ctx, int type, X509_NAME *name, ASN1_INTEGER *serial, X509_OBJECT *ret); int X509_LOOKUP_by_fingerprint(X509_LOOKUP *ctx, int type, - unsigned char *bytes, int len, X509_OBJECT *ret); -int X509_LOOKUP_by_alias(X509_LOOKUP *ctx, int type, char *str, + const unsigned char *bytes, int len, X509_OBJECT *ret); +int X509_LOOKUP_by_alias(X509_LOOKUP *ctx, int type, const char *str, int len, X509_OBJECT *ret); int X509_LOOKUP_shutdown(X509_LOOKUP *ctx); |