提交 5fba3912 编写于 作者: V Viktor Dukhovni

Clarify negative return from X509_verify_cert()

Reviewed-by: NRichard Levitte <levitte@openssl.org>
上级 87275905
......@@ -31,12 +31,13 @@ Applications rarely call this function directly but it is used by
OpenSSL internally for certificate validation, in both the S/MIME and
SSL/TLS code.
The negative return value from X509_verify_cert() can only occur if no
certificate is set in B<ctx> (due to a programming error); if X509_verify_cert()
twice without reinitialising B<ctx> in between; or if a retry
operation is requested during internal lookups (which never happens with
standard lookup methods). It is however recommended that application check
for <= 0 return value on error.
A negative return value from X509_verify_cert() can occur if it is invoked
incurrectly, such as with no certificate set in B<ctx>, or when it is called
twice in succession without reinitialising B<ctx> for the second call.
A negative return value can also happen due to internal resource problems or if
a retry operation is requested during internal lookups (which never happens
with standard lookup methods).
Applications must check for <= 0 return value on error.
=head1 BUGS
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册