1X509_verify_cert(3) OpenSSL X509_verify_cert(3)
2
3
4
6 X509_verify_cert - discover and verify X509 certificte chain
7
9 #include <openssl/x509.h>
10
11 int X509_verify_cert(X509_STORE_CTX *ctx);
12
14 The X509_verify_cert() function attempts to discover and validate a
15 certificate chain based on parameters in ctx. A complete description of
16 the process is contained in the verify(1) manual page.
17
19 If a complete chain can be built and validated this function returns 1,
20 otherwise it return zero, in exceptional circumstances it can also
21 return a negative code.
22
23 If the function fails additional error information can be obtained by
24 examining ctx using, for example X509_STORE_CTX_get_error().
25
27 Applications rarely call this function directly but it is used by
28 OpenSSL internally for certificate validation, in both the S/MIME and
29 SSL/TLS code.
30
31 The negative return value from X509_verify_cert() can only occur if no
32 certificate is set in ctx (due to a programming error) or if a retry
33 operation is requested during internal lookups (which never happens
34 with standard lookup methods). It is however recommended that
35 application check for <= 0 return value on error.
36
38 This function uses the header x509.h as opposed to most chain
39 verification functiosn which use x509_vfy.h.
40
42 X509_STORE_CTX_get_error(3)
43
45 X509_verify_cert() is available in all versions of SSLeay and OpenSSL.
46
47
48
491.0.0e 2009-10-18 X509_verify_cert(3)