1ebfedea0SLionel Sambuc=pod 2ebfedea0SLionel Sambuc 3ebfedea0SLionel Sambuc=head1 NAME 4ebfedea0SLionel Sambuc 5ebfedea0SLionel Sambucverify - Utility to verify certificates. 6ebfedea0SLionel Sambuc 7ebfedea0SLionel Sambuc=head1 SYNOPSIS 8ebfedea0SLionel Sambuc 9ebfedea0SLionel SambucB<openssl> B<verify> 10ebfedea0SLionel Sambuc[B<-CApath directory>] 11ebfedea0SLionel Sambuc[B<-CAfile file>] 12ebfedea0SLionel Sambuc[B<-purpose purpose>] 13ebfedea0SLionel Sambuc[B<-policy arg>] 14ebfedea0SLionel Sambuc[B<-ignore_critical>] 15ebfedea0SLionel Sambuc[B<-crl_check>] 16ebfedea0SLionel Sambuc[B<-crl_check_all>] 17ebfedea0SLionel Sambuc[B<-policy_check>] 18ebfedea0SLionel Sambuc[B<-explicit_policy>] 19ebfedea0SLionel Sambuc[B<-inhibit_any>] 20ebfedea0SLionel Sambuc[B<-inhibit_map>] 21ebfedea0SLionel Sambuc[B<-x509_strict>] 22ebfedea0SLionel Sambuc[B<-extended_crl>] 23ebfedea0SLionel Sambuc[B<-use_deltas>] 24ebfedea0SLionel Sambuc[B<-policy_print>] 25*0a6a1f1dSLionel Sambuc[B<-no_alt_chains>] 26ebfedea0SLionel Sambuc[B<-untrusted file>] 27ebfedea0SLionel Sambuc[B<-help>] 28ebfedea0SLionel Sambuc[B<-issuer_checks>] 29*0a6a1f1dSLionel Sambuc[B<-attime timestamp>] 30ebfedea0SLionel Sambuc[B<-verbose>] 31ebfedea0SLionel Sambuc[B<->] 32ebfedea0SLionel Sambuc[certificates] 33ebfedea0SLionel Sambuc 34ebfedea0SLionel Sambuc 35ebfedea0SLionel Sambuc=head1 DESCRIPTION 36ebfedea0SLionel Sambuc 37ebfedea0SLionel SambucThe B<verify> command verifies certificate chains. 38ebfedea0SLionel Sambuc 39ebfedea0SLionel Sambuc=head1 COMMAND OPTIONS 40ebfedea0SLionel Sambuc 41ebfedea0SLionel Sambuc=over 4 42ebfedea0SLionel Sambuc 43ebfedea0SLionel Sambuc=item B<-CApath directory> 44ebfedea0SLionel Sambuc 45ebfedea0SLionel SambucA directory of trusted certificates. The certificates should have names 46ebfedea0SLionel Sambucof the form: hash.0 or have symbolic links to them of this 47ebfedea0SLionel Sambucform ("hash" is the hashed certificate subject name: see the B<-hash> option 48ebfedea0SLionel Sambucof the B<x509> utility). Under Unix the B<c_rehash> script will automatically 49ebfedea0SLionel Sambuccreate symbolic links to a directory of certificates. 50ebfedea0SLionel Sambuc 51ebfedea0SLionel Sambuc=item B<-CAfile file> 52ebfedea0SLionel SambucA file of trusted certificates. The file should contain multiple certificates 53ebfedea0SLionel Sambucin PEM format concatenated together. 54ebfedea0SLionel Sambuc 55ebfedea0SLionel Sambuc=item B<-untrusted file> 56ebfedea0SLionel Sambuc 57ebfedea0SLionel SambucA file of untrusted certificates. The file should contain multiple certificates 58ebfedea0SLionel Sambucin PEM format concatenated together. 59ebfedea0SLionel Sambuc 60ebfedea0SLionel Sambuc=item B<-purpose purpose> 61ebfedea0SLionel Sambuc 62ebfedea0SLionel SambucThe intended use for the certificate. If this option is not specified, 63ebfedea0SLionel SambucB<verify> will not consider certificate purpose during chain verification. 64ebfedea0SLionel SambucCurrently accepted uses are B<sslclient>, B<sslserver>, B<nssslserver>, 65ebfedea0SLionel SambucB<smimesign>, B<smimeencrypt>. See the B<VERIFY OPERATION> section for more 66ebfedea0SLionel Sambucinformation. 67ebfedea0SLionel Sambuc 68ebfedea0SLionel Sambuc=item B<-help> 69ebfedea0SLionel Sambuc 70ebfedea0SLionel SambucPrint out a usage message. 71ebfedea0SLionel Sambuc 72ebfedea0SLionel Sambuc=item B<-verbose> 73ebfedea0SLionel Sambuc 74ebfedea0SLionel SambucPrint extra information about the operations being performed. 75ebfedea0SLionel Sambuc 76ebfedea0SLionel Sambuc=item B<-issuer_checks> 77ebfedea0SLionel Sambuc 78ebfedea0SLionel SambucPrint out diagnostics relating to searches for the issuer certificate of the 79ebfedea0SLionel Sambuccurrent certificate. This shows why each candidate issuer certificate was 80ebfedea0SLionel Sambucrejected. The presence of rejection messages does not itself imply that 81ebfedea0SLionel Sambucanything is wrong; during the normal verification process, several 82ebfedea0SLionel Sambucrejections may take place. 83ebfedea0SLionel Sambuc 84*0a6a1f1dSLionel Sambuc=item B<-attime timestamp> 85*0a6a1f1dSLionel Sambuc 86*0a6a1f1dSLionel SambucPerform validation checks using time specified by B<timestamp> and not 87*0a6a1f1dSLionel Sambuccurrent system time. B<timestamp> is the number of seconds since 88*0a6a1f1dSLionel Sambuc01.01.1970 (UNIX time). 89*0a6a1f1dSLionel Sambuc 90ebfedea0SLionel Sambuc=item B<-policy arg> 91ebfedea0SLionel Sambuc 92ebfedea0SLionel SambucEnable policy processing and add B<arg> to the user-initial-policy-set (see 93ebfedea0SLionel SambucRFC5280). The policy B<arg> can be an object name an OID in numeric form. 94ebfedea0SLionel SambucThis argument can appear more than once. 95ebfedea0SLionel Sambuc 96ebfedea0SLionel Sambuc=item B<-policy_check> 97ebfedea0SLionel Sambuc 98ebfedea0SLionel SambucEnables certificate policy processing. 99ebfedea0SLionel Sambuc 100ebfedea0SLionel Sambuc=item B<-explicit_policy> 101ebfedea0SLionel Sambuc 102ebfedea0SLionel SambucSet policy variable require-explicit-policy (see RFC5280). 103ebfedea0SLionel Sambuc 104ebfedea0SLionel Sambuc=item B<-inhibit_any> 105ebfedea0SLionel Sambuc 106ebfedea0SLionel SambucSet policy variable inhibit-any-policy (see RFC5280). 107ebfedea0SLionel Sambuc 108ebfedea0SLionel Sambuc=item B<-inhibit_map> 109ebfedea0SLionel Sambuc 110ebfedea0SLionel SambucSet policy variable inhibit-policy-mapping (see RFC5280). 111ebfedea0SLionel Sambuc 112*0a6a1f1dSLionel Sambuc=item B<-no_alt_chains> 113*0a6a1f1dSLionel Sambuc 114*0a6a1f1dSLionel SambucWhen building a certificate chain, if the first certificate chain found is not 115*0a6a1f1dSLionel Sambuctrusted, then OpenSSL will continue to check to see if an alternative chain can 116*0a6a1f1dSLionel Sambucbe found that is trusted. With this option that behaviour is suppressed so that 117*0a6a1f1dSLionel Sambuconly the first chain found is ever used. Using this option will force the 118*0a6a1f1dSLionel Sambucbehaviour to match that of previous OpenSSL versions. 119*0a6a1f1dSLionel Sambuc 120ebfedea0SLionel Sambuc=item B<-policy_print> 121ebfedea0SLionel Sambuc 122ebfedea0SLionel SambucPrint out diagnostics related to policy processing. 123ebfedea0SLionel Sambuc 124ebfedea0SLionel Sambuc=item B<-crl_check> 125ebfedea0SLionel Sambuc 126ebfedea0SLionel SambucChecks end entity certificate validity by attempting to look up a valid CRL. 127ebfedea0SLionel SambucIf a valid CRL cannot be found an error occurs. 128ebfedea0SLionel Sambuc 129ebfedea0SLionel Sambuc=item B<-crl_check_all> 130ebfedea0SLionel Sambuc 131ebfedea0SLionel SambucChecks the validity of B<all> certificates in the chain by attempting 132ebfedea0SLionel Sambucto look up valid CRLs. 133ebfedea0SLionel Sambuc 134ebfedea0SLionel Sambuc=item B<-ignore_critical> 135ebfedea0SLionel Sambuc 136ebfedea0SLionel SambucNormally if an unhandled critical extension is present which is not 137ebfedea0SLionel Sambucsupported by OpenSSL the certificate is rejected (as required by RFC5280). 138ebfedea0SLionel SambucIf this option is set critical extensions are ignored. 139ebfedea0SLionel Sambuc 140ebfedea0SLionel Sambuc=item B<-x509_strict> 141ebfedea0SLionel Sambuc 142ebfedea0SLionel SambucFor strict X.509 compliance, disable non-compliant workarounds for broken 143ebfedea0SLionel Sambuccertificates. 144ebfedea0SLionel Sambuc 145ebfedea0SLionel Sambuc=item B<-extended_crl> 146ebfedea0SLionel Sambuc 147ebfedea0SLionel SambucEnable extended CRL features such as indirect CRLs and alternate CRL 148ebfedea0SLionel Sambucsigning keys. 149ebfedea0SLionel Sambuc 150ebfedea0SLionel Sambuc=item B<-use_deltas> 151ebfedea0SLionel Sambuc 152ebfedea0SLionel SambucEnable support for delta CRLs. 153ebfedea0SLionel Sambuc 154ebfedea0SLionel Sambuc=item B<-check_ss_sig> 155ebfedea0SLionel Sambuc 156ebfedea0SLionel SambucVerify the signature on the self-signed root CA. This is disabled by default 157ebfedea0SLionel Sambucbecause it doesn't add any security. 158ebfedea0SLionel Sambuc 159ebfedea0SLionel Sambuc=item B<-> 160ebfedea0SLionel Sambuc 161ebfedea0SLionel SambucIndicates the last option. All arguments following this are assumed to be 162ebfedea0SLionel Sambuccertificate files. This is useful if the first certificate filename begins 163ebfedea0SLionel Sambucwith a B<->. 164ebfedea0SLionel Sambuc 165ebfedea0SLionel Sambuc=item B<certificates> 166ebfedea0SLionel Sambuc 167ebfedea0SLionel SambucOne or more certificates to verify. If no certificates are given, B<verify> 168ebfedea0SLionel Sambucwill attempt to read a certificate from standard input. Certificates must be 169ebfedea0SLionel Sambucin PEM format. 170ebfedea0SLionel Sambuc 171ebfedea0SLionel Sambuc=back 172ebfedea0SLionel Sambuc 173ebfedea0SLionel Sambuc=head1 VERIFY OPERATION 174ebfedea0SLionel Sambuc 175ebfedea0SLionel SambucThe B<verify> program uses the same functions as the internal SSL and S/MIME 176ebfedea0SLionel Sambucverification, therefore this description applies to these verify operations 177ebfedea0SLionel Sambuctoo. 178ebfedea0SLionel Sambuc 179ebfedea0SLionel SambucThere is one crucial difference between the verify operations performed 180ebfedea0SLionel Sambucby the B<verify> program: wherever possible an attempt is made to continue 181ebfedea0SLionel Sambucafter an error whereas normally the verify operation would halt on the 182ebfedea0SLionel Sambucfirst error. This allows all the problems with a certificate chain to be 183ebfedea0SLionel Sambucdetermined. 184ebfedea0SLionel Sambuc 185ebfedea0SLionel SambucThe verify operation consists of a number of separate steps. 186ebfedea0SLionel Sambuc 187ebfedea0SLionel SambucFirstly a certificate chain is built up starting from the supplied certificate 188ebfedea0SLionel Sambucand ending in the root CA. It is an error if the whole chain cannot be built 189ebfedea0SLionel Sambucup. The chain is built up by looking up the issuers certificate of the current 190ebfedea0SLionel Sambuccertificate. If a certificate is found which is its own issuer it is assumed 191ebfedea0SLionel Sambucto be the root CA. 192ebfedea0SLionel Sambuc 193ebfedea0SLionel SambucThe process of 'looking up the issuers certificate' itself involves a number 194ebfedea0SLionel Sambucof steps. In versions of OpenSSL before 0.9.5a the first certificate whose 195ebfedea0SLionel Sambucsubject name matched the issuer of the current certificate was assumed to be 196ebfedea0SLionel Sambucthe issuers certificate. In OpenSSL 0.9.6 and later all certificates 197ebfedea0SLionel Sambucwhose subject name matches the issuer name of the current certificate are 198ebfedea0SLionel Sambucsubject to further tests. The relevant authority key identifier components 199ebfedea0SLionel Sambucof the current certificate (if present) must match the subject key identifier 200ebfedea0SLionel Sambuc(if present) and issuer and serial number of the candidate issuer, in addition 201ebfedea0SLionel Sambucthe keyUsage extension of the candidate issuer (if present) must permit 202ebfedea0SLionel Sambuccertificate signing. 203ebfedea0SLionel Sambuc 204ebfedea0SLionel SambucThe lookup first looks in the list of untrusted certificates and if no match 205ebfedea0SLionel Sambucis found the remaining lookups are from the trusted certificates. The root CA 206ebfedea0SLionel Sambucis always looked up in the trusted certificate list: if the certificate to 207ebfedea0SLionel Sambucverify is a root certificate then an exact match must be found in the trusted 208ebfedea0SLionel Sambuclist. 209ebfedea0SLionel Sambuc 210ebfedea0SLionel SambucThe second operation is to check every untrusted certificate's extensions for 211ebfedea0SLionel Sambucconsistency with the supplied purpose. If the B<-purpose> option is not included 212ebfedea0SLionel Sambucthen no checks are done. The supplied or "leaf" certificate must have extensions 213ebfedea0SLionel Sambuccompatible with the supplied purpose and all other certificates must also be valid 214ebfedea0SLionel SambucCA certificates. The precise extensions required are described in more detail in 215ebfedea0SLionel Sambucthe B<CERTIFICATE EXTENSIONS> section of the B<x509> utility. 216ebfedea0SLionel Sambuc 217ebfedea0SLionel SambucThe third operation is to check the trust settings on the root CA. The root 218ebfedea0SLionel SambucCA should be trusted for the supplied purpose. For compatibility with previous 219ebfedea0SLionel Sambucversions of SSLeay and OpenSSL a certificate with no trust settings is considered 220ebfedea0SLionel Sambucto be valid for all purposes. 221ebfedea0SLionel Sambuc 222ebfedea0SLionel SambucThe final operation is to check the validity of the certificate chain. The validity 223ebfedea0SLionel Sambucperiod is checked against the current system time and the notBefore and notAfter 224ebfedea0SLionel Sambucdates in the certificate. The certificate signatures are also checked at this 225ebfedea0SLionel Sambucpoint. 226ebfedea0SLionel Sambuc 227ebfedea0SLionel SambucIf all operations complete successfully then certificate is considered valid. If 228ebfedea0SLionel Sambucany operation fails then the certificate is not valid. 229ebfedea0SLionel Sambuc 230ebfedea0SLionel Sambuc=head1 DIAGNOSTICS 231ebfedea0SLionel Sambuc 232ebfedea0SLionel SambucWhen a verify operation fails the output messages can be somewhat cryptic. The 233ebfedea0SLionel Sambucgeneral form of the error message is: 234ebfedea0SLionel Sambuc 235ebfedea0SLionel Sambuc server.pem: /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test CA (1024 bit) 236ebfedea0SLionel Sambuc error 24 at 1 depth lookup:invalid CA certificate 237ebfedea0SLionel Sambuc 238ebfedea0SLionel SambucThe first line contains the name of the certificate being verified followed by 239ebfedea0SLionel Sambucthe subject name of the certificate. The second line contains the error number 240ebfedea0SLionel Sambucand the depth. The depth is number of the certificate being verified when a 241ebfedea0SLionel Sambucproblem was detected starting with zero for the certificate being verified itself 242ebfedea0SLionel Sambucthen 1 for the CA that signed the certificate and so on. Finally a text version 243ebfedea0SLionel Sambucof the error number is presented. 244ebfedea0SLionel Sambuc 245ebfedea0SLionel SambucAn exhaustive list of the error codes and messages is shown below, this also 246ebfedea0SLionel Sambucincludes the name of the error code as defined in the header file x509_vfy.h 247ebfedea0SLionel SambucSome of the error codes are defined but never returned: these are described 248ebfedea0SLionel Sambucas "unused". 249ebfedea0SLionel Sambuc 250ebfedea0SLionel Sambuc=over 4 251ebfedea0SLionel Sambuc 252ebfedea0SLionel Sambuc=item B<0 X509_V_OK: ok> 253ebfedea0SLionel Sambuc 254ebfedea0SLionel Sambucthe operation was successful. 255ebfedea0SLionel Sambuc 256ebfedea0SLionel Sambuc=item B<2 X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT: unable to get issuer certificate> 257ebfedea0SLionel Sambuc 258ebfedea0SLionel Sambucthe issuer certificate of a looked up certificate could not be found. This 259ebfedea0SLionel Sambucnormally means the list of trusted certificates is not complete. 260ebfedea0SLionel Sambuc 261ebfedea0SLionel Sambuc=item B<3 X509_V_ERR_UNABLE_TO_GET_CRL: unable to get certificate CRL> 262ebfedea0SLionel Sambuc 263ebfedea0SLionel Sambucthe CRL of a certificate could not be found. 264ebfedea0SLionel Sambuc 265ebfedea0SLionel Sambuc=item B<4 X509_V_ERR_UNABLE_TO_DECRYPT_CERT_SIGNATURE: unable to decrypt certificate's signature> 266ebfedea0SLionel Sambuc 267ebfedea0SLionel Sambucthe certificate signature could not be decrypted. This means that the actual signature value 268ebfedea0SLionel Sambuccould not be determined rather than it not matching the expected value, this is only 269ebfedea0SLionel Sambucmeaningful for RSA keys. 270ebfedea0SLionel Sambuc 271ebfedea0SLionel Sambuc=item B<5 X509_V_ERR_UNABLE_TO_DECRYPT_CRL_SIGNATURE: unable to decrypt CRL's signature> 272ebfedea0SLionel Sambuc 273ebfedea0SLionel Sambucthe CRL signature could not be decrypted: this means that the actual signature value 274ebfedea0SLionel Sambuccould not be determined rather than it not matching the expected value. Unused. 275ebfedea0SLionel Sambuc 276ebfedea0SLionel Sambuc=item B<6 X509_V_ERR_UNABLE_TO_DECODE_ISSUER_PUBLIC_KEY: unable to decode issuer public key> 277ebfedea0SLionel Sambuc 278ebfedea0SLionel Sambucthe public key in the certificate SubjectPublicKeyInfo could not be read. 279ebfedea0SLionel Sambuc 280ebfedea0SLionel Sambuc=item B<7 X509_V_ERR_CERT_SIGNATURE_FAILURE: certificate signature failure> 281ebfedea0SLionel Sambuc 282ebfedea0SLionel Sambucthe signature of the certificate is invalid. 283ebfedea0SLionel Sambuc 284ebfedea0SLionel Sambuc=item B<8 X509_V_ERR_CRL_SIGNATURE_FAILURE: CRL signature failure> 285ebfedea0SLionel Sambuc 286ebfedea0SLionel Sambucthe signature of the certificate is invalid. 287ebfedea0SLionel Sambuc 288ebfedea0SLionel Sambuc=item B<9 X509_V_ERR_CERT_NOT_YET_VALID: certificate is not yet valid> 289ebfedea0SLionel Sambuc 290ebfedea0SLionel Sambucthe certificate is not yet valid: the notBefore date is after the current time. 291ebfedea0SLionel Sambuc 292ebfedea0SLionel Sambuc=item B<10 X509_V_ERR_CERT_HAS_EXPIRED: certificate has expired> 293ebfedea0SLionel Sambuc 294ebfedea0SLionel Sambucthe certificate has expired: that is the notAfter date is before the current time. 295ebfedea0SLionel Sambuc 296ebfedea0SLionel Sambuc=item B<11 X509_V_ERR_CRL_NOT_YET_VALID: CRL is not yet valid> 297ebfedea0SLionel Sambuc 298ebfedea0SLionel Sambucthe CRL is not yet valid. 299ebfedea0SLionel Sambuc 300ebfedea0SLionel Sambuc=item B<12 X509_V_ERR_CRL_HAS_EXPIRED: CRL has expired> 301ebfedea0SLionel Sambuc 302ebfedea0SLionel Sambucthe CRL has expired. 303ebfedea0SLionel Sambuc 304ebfedea0SLionel Sambuc=item B<13 X509_V_ERR_ERROR_IN_CERT_NOT_BEFORE_FIELD: format error in certificate's notBefore field> 305ebfedea0SLionel Sambuc 306ebfedea0SLionel Sambucthe certificate notBefore field contains an invalid time. 307ebfedea0SLionel Sambuc 308ebfedea0SLionel Sambuc=item B<14 X509_V_ERR_ERROR_IN_CERT_NOT_AFTER_FIELD: format error in certificate's notAfter field> 309ebfedea0SLionel Sambuc 310ebfedea0SLionel Sambucthe certificate notAfter field contains an invalid time. 311ebfedea0SLionel Sambuc 312ebfedea0SLionel Sambuc=item B<15 X509_V_ERR_ERROR_IN_CRL_LAST_UPDATE_FIELD: format error in CRL's lastUpdate field> 313ebfedea0SLionel Sambuc 314ebfedea0SLionel Sambucthe CRL lastUpdate field contains an invalid time. 315ebfedea0SLionel Sambuc 316ebfedea0SLionel Sambuc=item B<16 X509_V_ERR_ERROR_IN_CRL_NEXT_UPDATE_FIELD: format error in CRL's nextUpdate field> 317ebfedea0SLionel Sambuc 318ebfedea0SLionel Sambucthe CRL nextUpdate field contains an invalid time. 319ebfedea0SLionel Sambuc 320ebfedea0SLionel Sambuc=item B<17 X509_V_ERR_OUT_OF_MEM: out of memory> 321ebfedea0SLionel Sambuc 322ebfedea0SLionel Sambucan error occurred trying to allocate memory. This should never happen. 323ebfedea0SLionel Sambuc 324ebfedea0SLionel Sambuc=item B<18 X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT: self signed certificate> 325ebfedea0SLionel Sambuc 326ebfedea0SLionel Sambucthe passed certificate is self signed and the same certificate cannot be found in the list of 327ebfedea0SLionel Sambuctrusted certificates. 328ebfedea0SLionel Sambuc 329ebfedea0SLionel Sambuc=item B<19 X509_V_ERR_SELF_SIGNED_CERT_IN_CHAIN: self signed certificate in certificate chain> 330ebfedea0SLionel Sambuc 331ebfedea0SLionel Sambucthe certificate chain could be built up using the untrusted certificates but the root could not 332ebfedea0SLionel Sambucbe found locally. 333ebfedea0SLionel Sambuc 334ebfedea0SLionel Sambuc=item B<20 X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT_LOCALLY: unable to get local issuer certificate> 335ebfedea0SLionel Sambuc 336ebfedea0SLionel Sambucthe issuer certificate could not be found: this occurs if the issuer 337ebfedea0SLionel Sambuccertificate of an untrusted certificate cannot be found. 338ebfedea0SLionel Sambuc 339ebfedea0SLionel Sambuc=item B<21 X509_V_ERR_UNABLE_TO_VERIFY_LEAF_SIGNATURE: unable to verify the first certificate> 340ebfedea0SLionel Sambuc 341ebfedea0SLionel Sambucno signatures could be verified because the chain contains only one certificate and it is not 342ebfedea0SLionel Sambucself signed. 343ebfedea0SLionel Sambuc 344ebfedea0SLionel Sambuc=item B<22 X509_V_ERR_CERT_CHAIN_TOO_LONG: certificate chain too long> 345ebfedea0SLionel Sambuc 346ebfedea0SLionel Sambucthe certificate chain length is greater than the supplied maximum depth. Unused. 347ebfedea0SLionel Sambuc 348ebfedea0SLionel Sambuc=item B<23 X509_V_ERR_CERT_REVOKED: certificate revoked> 349ebfedea0SLionel Sambuc 350ebfedea0SLionel Sambucthe certificate has been revoked. 351ebfedea0SLionel Sambuc 352ebfedea0SLionel Sambuc=item B<24 X509_V_ERR_INVALID_CA: invalid CA certificate> 353ebfedea0SLionel Sambuc 354ebfedea0SLionel Sambuca CA certificate is invalid. Either it is not a CA or its extensions are not consistent 355ebfedea0SLionel Sambucwith the supplied purpose. 356ebfedea0SLionel Sambuc 357ebfedea0SLionel Sambuc=item B<25 X509_V_ERR_PATH_LENGTH_EXCEEDED: path length constraint exceeded> 358ebfedea0SLionel Sambuc 359ebfedea0SLionel Sambucthe basicConstraints pathlength parameter has been exceeded. 360ebfedea0SLionel Sambuc 361ebfedea0SLionel Sambuc=item B<26 X509_V_ERR_INVALID_PURPOSE: unsupported certificate purpose> 362ebfedea0SLionel Sambuc 363ebfedea0SLionel Sambucthe supplied certificate cannot be used for the specified purpose. 364ebfedea0SLionel Sambuc 365ebfedea0SLionel Sambuc=item B<27 X509_V_ERR_CERT_UNTRUSTED: certificate not trusted> 366ebfedea0SLionel Sambuc 367ebfedea0SLionel Sambucthe root CA is not marked as trusted for the specified purpose. 368ebfedea0SLionel Sambuc 369ebfedea0SLionel Sambuc=item B<28 X509_V_ERR_CERT_REJECTED: certificate rejected> 370ebfedea0SLionel Sambuc 371ebfedea0SLionel Sambucthe root CA is marked to reject the specified purpose. 372ebfedea0SLionel Sambuc 373ebfedea0SLionel Sambuc=item B<29 X509_V_ERR_SUBJECT_ISSUER_MISMATCH: subject issuer mismatch> 374ebfedea0SLionel Sambuc 375ebfedea0SLionel Sambucthe current candidate issuer certificate was rejected because its subject name 376ebfedea0SLionel Sambucdid not match the issuer name of the current certificate. Only displayed when 377ebfedea0SLionel Sambucthe B<-issuer_checks> option is set. 378ebfedea0SLionel Sambuc 379ebfedea0SLionel Sambuc=item B<30 X509_V_ERR_AKID_SKID_MISMATCH: authority and subject key identifier mismatch> 380ebfedea0SLionel Sambuc 381ebfedea0SLionel Sambucthe current candidate issuer certificate was rejected because its subject key 382ebfedea0SLionel Sambucidentifier was present and did not match the authority key identifier current 383ebfedea0SLionel Sambuccertificate. Only displayed when the B<-issuer_checks> option is set. 384ebfedea0SLionel Sambuc 385ebfedea0SLionel Sambuc=item B<31 X509_V_ERR_AKID_ISSUER_SERIAL_MISMATCH: authority and issuer serial number mismatch> 386ebfedea0SLionel Sambuc 387ebfedea0SLionel Sambucthe current candidate issuer certificate was rejected because its issuer name 388ebfedea0SLionel Sambucand serial number was present and did not match the authority key identifier 389ebfedea0SLionel Sambucof the current certificate. Only displayed when the B<-issuer_checks> option is set. 390ebfedea0SLionel Sambuc 391ebfedea0SLionel Sambuc=item B<32 X509_V_ERR_KEYUSAGE_NO_CERTSIGN:key usage does not include certificate signing> 392ebfedea0SLionel Sambuc 393ebfedea0SLionel Sambucthe current candidate issuer certificate was rejected because its keyUsage extension 394ebfedea0SLionel Sambucdoes not permit certificate signing. 395ebfedea0SLionel Sambuc 396ebfedea0SLionel Sambuc=item B<50 X509_V_ERR_APPLICATION_VERIFICATION: application verification failure> 397ebfedea0SLionel Sambuc 398ebfedea0SLionel Sambucan application specific error. Unused. 399ebfedea0SLionel Sambuc 400ebfedea0SLionel Sambuc=back 401ebfedea0SLionel Sambuc 402ebfedea0SLionel Sambuc=head1 BUGS 403ebfedea0SLionel Sambuc 404*0a6a1f1dSLionel SambucAlthough the issuer checks are a considerable improvement over the old technique they still 405ebfedea0SLionel Sambucsuffer from limitations in the underlying X509_LOOKUP API. One consequence of this is that 406ebfedea0SLionel Sambuctrusted certificates with matching subject name must either appear in a file (as specified by the 407ebfedea0SLionel SambucB<-CAfile> option) or a directory (as specified by B<-CApath>. If they occur in both then only 408ebfedea0SLionel Sambucthe certificates in the file will be recognised. 409ebfedea0SLionel Sambuc 410ebfedea0SLionel SambucPrevious versions of OpenSSL assume certificates with matching subject name are identical and 411ebfedea0SLionel Sambucmishandled them. 412ebfedea0SLionel Sambuc 413ebfedea0SLionel SambucPrevious versions of this documentation swapped the meaning of the 414ebfedea0SLionel SambucB<X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT> and 415ebfedea0SLionel SambucB<20 X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT_LOCALLY> error codes. 416ebfedea0SLionel Sambuc 417ebfedea0SLionel Sambuc=head1 SEE ALSO 418ebfedea0SLionel Sambuc 419ebfedea0SLionel SambucL<x509(1)|x509(1)> 420ebfedea0SLionel Sambuc 421*0a6a1f1dSLionel Sambuc=head1 HISTORY 422*0a6a1f1dSLionel Sambuc 423*0a6a1f1dSLionel SambucThe -no_alt_chains options was first added to OpenSSL 1.0.1n and 1.0.2b. 424*0a6a1f1dSLionel Sambuc 425ebfedea0SLionel Sambuc=cut 426