xref: /netbsd-src/crypto/external/bsd/openssl.old/dist/doc/man3/X509_check_issued.pod (revision 4724848cf0da353df257f730694b7882798e5daf)
1*4724848cSchristos=pod
2*4724848cSchristos
3*4724848cSchristos=head1 NAME
4*4724848cSchristos
5*4724848cSchristosX509_check_issued - checks if certificate is apparently issued by another
6*4724848cSchristoscertificate
7*4724848cSchristos
8*4724848cSchristos=head1 SYNOPSIS
9*4724848cSchristos
10*4724848cSchristos #include <openssl/x509v3.h>
11*4724848cSchristos
12*4724848cSchristos int X509_check_issued(X509 *issuer, X509 *subject);
13*4724848cSchristos
14*4724848cSchristos
15*4724848cSchristos=head1 DESCRIPTION
16*4724848cSchristos
17*4724848cSchristosX509_check_issued() checks if certificate I<subject> was apparently issued
18*4724848cSchristosusing (CA) certificate I<issuer>. This function takes into account not only
19*4724848cSchristosmatching of the issuer field of I<subject> with the subject field of I<issuer>,
20*4724848cSchristosbut also compares all sub-fields of the B<authorityKeyIdentifier> extension of
21*4724848cSchristosI<subject>, as far as present, with the respective B<subjectKeyIdentifier>,
22*4724848cSchristosserial number, and issuer fields of I<issuer>, as far as present. It also checks
23*4724848cSchristosif the B<keyUsage> field (if present) of I<issuer> allows certificate signing.
24*4724848cSchristosIt does not check the certificate signature.
25*4724848cSchristos
26*4724848cSchristos=head1 RETURN VALUES
27*4724848cSchristos
28*4724848cSchristosFunction return B<X509_V_OK> if certificate I<subject> is issued by
29*4724848cSchristosI<issuer> or some B<X509_V_ERR*> constant to indicate an error.
30*4724848cSchristos
31*4724848cSchristos=head1 SEE ALSO
32*4724848cSchristos
33*4724848cSchristosL<X509_verify_cert(3)>,
34*4724848cSchristosL<X509_check_ca(3)>,
35*4724848cSchristosL<verify(1)>
36*4724848cSchristos
37*4724848cSchristos=head1 COPYRIGHT
38*4724848cSchristos
39*4724848cSchristosCopyright 2015-2020 The OpenSSL Project Authors. All Rights Reserved.
40*4724848cSchristos
41*4724848cSchristosLicensed under the OpenSSL license (the "License").  You may not use
42*4724848cSchristosthis file except in compliance with the License.  You can obtain a copy
43*4724848cSchristosin the file LICENSE in the source distribution or at
44*4724848cSchristosL<https://www.openssl.org/source/license.html>.
45*4724848cSchristos
46*4724848cSchristos=cut
47