1
- .\" $OpenBSD: X509_STORE_set_verify_cb_func.3,v 1.9 2020/03/29 17:05:02 schwarze Exp $
2
- .\" OpenSSL 05ea606a May 20 20:52:46 2016 -0400
1
+ .\" $OpenBSD: X509_STORE_set_verify_cb_func.3,v 1.10 2021/07/29 10:13:45 schwarze Exp $
2
+ .\" full merge up to: OpenSSL 05ea606a May 20 20:52:46 2016 -0400
3
+ .\" selective merge up to: OpenSSL 315c47e0 Dec 1 14:22:16 2020 +0100
3
4
.\"
4
5
.\" This file was written by Dr. Stephen Henson <steve@openssl.org>.
5
6
.\" Copyright (c) 2009 The OpenSSL Project. All rights reserved.
48
49
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
49
50
.\" OF THE POSSIBILITY OF SUCH DAMAGE.
50
51
.\"
51
- .Dd $Mdocdate : March 29 2020 $
52
+ .Dd $Mdocdate : July 29 2021 $
52
53
.Dt X509_STORE_SET_VERIFY_CB_FUNC 3
53
54
.Os
54
55
.Sh NAME
55
56
.Nm X509_STORE_set_verify_cb ,
56
- .Nm X509_STORE_set_verify_cb_func
57
+ .Nm X509_STORE_set_verify_cb_func ,
58
+ .Nm X509_STORE_set_verify_func
57
59
.Nd set verification callback
58
60
.Sh SYNOPSIS
59
61
.In openssl/x509_vfy.h
67
69
.Fa " X509_STORE *st"
68
70
.Fa " int (*verify_cb)(int ok, X509_STORE_CTX *ctx)"
69
71
.Fc
72
+ .Ft void
73
+ .Fo X509_STORE_set_verify_func
74
+ .Fa " X509_STORE *st"
75
+ .Fa " int (*verify_func)(X509_STORE_CTX *ctx)"
76
+ .Fc
70
77
.Sh DESCRIPTION
71
78
.Fn X509_STORE_set_verify_cb
72
79
sets the verification callback of
@@ -86,17 +93,34 @@ structure when it is initialized.
86
93
This can be used to set the verification callback when the
87
94
.Vt X509_STORE_CTX
88
95
is otherwise inaccessible (for example during S/MIME verification).
96
+ .Pp
97
+ .Fn X509_STORE_set_verify_func
98
+ sets the final chain verification function for
99
+ .Fa st
100
+ to
101
+ .Fa verify_func .
102
+ Its purpose is to go through the chain of certificates and check
103
+ that all signatures are valid and that the current time is within
104
+ the limits of each certificate's first and last validity time.
105
+ The final chain verification function
106
+ must return 0 on failure and 1 on success.
107
+ If
108
+ .Fn X509_STORE_set_verify_func
109
+ is not called or called with
110
+ .Fa verify_func
111
+ set to a
112
+ .Dv NULL
113
+ pointer, the built-in default function is used.
89
114
.Sh SEE ALSO
90
115
.Xr X509_STORE_CTX_set_verify_cb 3 ,
91
116
.Xr X509_STORE_new 3
92
117
.Sh HISTORY
93
118
.Fn X509_STORE_set_verify_cb_func
94
- first appeared in SSLeay 0.8.0 and has been available since
119
+ and
120
+ .Fn X509_STORE_set_verify_func
121
+ first appeared in SSLeay 0.8.0 and have been available since
95
122
.Ox 2.4 .
96
123
.Pp
97
124
.Fn X509_STORE_set_verify_cb
98
125
first appeared in OpenSSL 1.0.0 and has been available since
99
126
.Ox 4.9 .
100
- .Sh BUGS
101
- The macro version of this function was the only one available before
102
- OpenSSL 1.0.0.
0 commit comments