summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorjmc <>2016-11-02 17:32:42 +0000
committerjmc <>2016-11-02 17:32:42 +0000
commit7f3dde9cdc415f9a66486001377d723ce4500622 (patch)
treeb0f89a27bfb92c0546079f31e6e9ccaf5156cc20 /src
parent878e440382fa65ddbadca1d2784ef1210f0ff652 (diff)
downloadopenbsd-7f3dde9cdc415f9a66486001377d723ce4500622.tar.gz
openbsd-7f3dde9cdc415f9a66486001377d723ce4500622.tar.bz2
openbsd-7f3dde9cdc415f9a66486001377d723ce4500622.zip
tweak previous;
Diffstat (limited to 'src')
-rw-r--r--src/lib/libtls/tls_init.358
1 files changed, 26 insertions, 32 deletions
diff --git a/src/lib/libtls/tls_init.3 b/src/lib/libtls/tls_init.3
index 2f6ca3d802..75c37e641b 100644
--- a/src/lib/libtls/tls_init.3
+++ b/src/lib/libtls/tls_init.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: tls_init.3,v 1.73 2016/11/02 15:18:42 beck Exp $ 1.\" $OpenBSD: tls_init.3,v 1.74 2016/11/02 17:32:42 jmc Exp $
2.\" 2.\"
3.\" Copyright (c) 2014 Ted Unangst <tedu@openbsd.org> 3.\" Copyright (c) 2014 Ted Unangst <tedu@openbsd.org>
4.\" 4.\"
@@ -50,7 +50,7 @@
50.Nm tls_config_verify , 50.Nm tls_config_verify ,
51.Nm tls_config_verify_client , 51.Nm tls_config_verify_client ,
52.Nm tls_config_verify_client_optional , 52.Nm tls_config_verify_client_optional ,
53.Nm tls_ocsp_process_response, 53.Nm tls_ocsp_process_response ,
54.Nm tls_peer_cert_provided , 54.Nm tls_peer_cert_provided ,
55.Nm tls_peer_cert_contains_name , 55.Nm tls_peer_cert_contains_name ,
56.Nm tls_peer_cert_issuer , 56.Nm tls_peer_cert_issuer ,
@@ -58,14 +58,14 @@
58.Nm tls_peer_cert_hash , 58.Nm tls_peer_cert_hash ,
59.Nm tls_peer_cert_notbefore , 59.Nm tls_peer_cert_notbefore ,
60.Nm tls_peer_cert_notafter , 60.Nm tls_peer_cert_notafter ,
61.Nm tls_peer_ocsp_cert_status, 61.Nm tls_peer_ocsp_cert_status ,
62.Nm tls_peer_ocsp_crl_reason, 62.Nm tls_peer_ocsp_crl_reason ,
63.Nm tls_peer_ocsp_next_update, 63.Nm tls_peer_ocsp_next_update ,
64.Nm tls_peer_ocsp_response_status, 64.Nm tls_peer_ocsp_response_status ,
65.Nm tls_peer_ocsp_result_msg, 65.Nm tls_peer_ocsp_result_msg ,
66.Nm tls_peer_ocsp_revocation_time, 66.Nm tls_peer_ocsp_revocation_time ,
67.Nm tls_peer_ocsp_this_update, 67.Nm tls_peer_ocsp_this_update ,
68.Nm tls_peer_ocsp_url, 68.Nm tls_peer_ocsp_url ,
69.Nm tls_conn_alpn_selected , 69.Nm tls_conn_alpn_selected ,
70.Nm tls_conn_cipher , 70.Nm tls_conn_cipher ,
71.Nm tls_conn_servername , 71.Nm tls_conn_servername ,
@@ -540,50 +540,44 @@ the peer certificate from
540returns the time corresponding to the end of the validity period of 540returns the time corresponding to the end of the validity period of
541the peer certificate from 541the peer certificate from
542.Ar ctx . 542.Ar ctx .
543.Ed
544.It 543.It
545.Fn tls_ocsp_process_response 544.Fn tls_ocsp_process_response
546processes a raw ocsp response in 545processes a raw OCSP response in
547.Ar response 546.Ar response
548of size 547of size
549.Ar size 548.Ar size
550to check the revocation status of the peer certificate from 549to check the revocation status of the peer certificate from
551.Ar ctx . 550.Ar ctx .
552A successful return code of 0 indicates that the certificate has not been revoked. 551A successful return code of 0 indicates that the certificate
553.Ed 552has not been revoked.
554.It 553.It
555.Fn tls_peer_ocsp_url 554.Fn tls_peer_ocsp_url
556returns the URL for OCSP validation of the peer certificate from 555returns the URL for OCSP validation of the peer certificate from
557.Ar ctx 556.Ar ctx
558.El 557.El
559.Pp 558.Pp
560The following functions return informaiton about the peer certificate from 559The following functions return information about the peer certificate from
561.Ar ctx 560.Ar ctx
562tha was obtained by validating a stapled OCSP response during the handshake, or 561that was obtained by validating a stapled OCSP response during the handshake,
563via a previous call to 562or via a previous call to
564.Xr tls_ocsp_process_response 563.Fn tls_ocsp_process_response
565.Bl -bullet -offset four 564.Bl -bullet -offset four
566.It 565.It
567.Fn tls_peer_ocsp_cert_status 566.Fn tls_peer_ocsp_cert_status
568returns the OCSP certificate status code as per RFC 6960 section 2.2 567returns the OCSP certificate status code as per RFC 6960 section 2.2
569.Ed
570.It 568.It
571.Fn tls_peer_ocsp_crl_reason 569.Fn tls_peer_ocsp_crl_reason
572returns the OCSP certificate revocation reason status code as per RFC 5280 570returns the OCSP certificate revocation reason status code as per RFC 5280
573section 5.3.1 571section 5.3.1
574.Ed
575.It 572.It
576.Fn tls_peer_ocsp_next_update 573.Fn tls_peer_ocsp_next_update
577returns the OCSP next update time 574returns the OCSP next update time
578.Ed
579.It 575.It
580.Fn tls_peer_ocsp_response_status 576.Fn tls_peer_ocsp_response_status
581returns the OCSP response status as per RFC 6960 section 2.3 577returns the OCSP response status as per RFC 6960 section 2.3
582.Ed
583.It 578.It
584.Fn tls_peer_ocsp_revocation_time 579.Fn tls_peer_ocsp_revocation_time
585returns the OCSP revocation time 580returns the OCSP revocation time
586.Ed
587.It 581.It
588.Fn tls_peer_ocsp_this_update 582.Fn tls_peer_ocsp_this_update
589returns the OCSP this update time 583returns the OCSP this update time
@@ -699,40 +693,40 @@ Functions that return a
699.Vt ssize_t 693.Vt ssize_t
700will return a size on success, and -1 on error. 694will return a size on success, and -1 on error.
701.Pp 695.Pp
702The 696The
703.Fn tls_peer_ocsp_response_status 697.Fn tls_peer_ocsp_response_status
704function returns one of 698function returns one of
705.Ar TLS_OCSP_RESPONSE_SUCCESSFUL , 699.Ar TLS_OCSP_RESPONSE_SUCCESSFUL ,
706.Ar TLS_OCSP_RESPONSE_MALFORMED , 700.Ar TLS_OCSP_RESPONSE_MALFORMED ,
707.Ar TLS_OCSP_RESPONSE_INTERNALERROR , 701.Ar TLS_OCSP_RESPONSE_INTERNALERROR ,
708.Ar TLS_OCSP_RESPONSE_TRYLATER , 702.Ar TLS_OCSP_RESPONSE_TRYLATER ,
709.Ar TLS_OCSP_RESPONSE_SIGREQUIRED , 703.Ar TLS_OCSP_RESPONSE_SIGREQUIRED ,
710or 704or
711.AR TLS_OCSP_RESPONSE_UNAUTHORIZED 705.Ar TLS_OCSP_RESPONSE_UNAUTHORIZED
712on success, and -1 on error. 706on success, and -1 on error.
713.Pp 707.Pp
714The 708The
715.Fn tls_peer_ocsp_cert_status 709.Fn tls_peer_ocsp_cert_status
716function returns one of 710function returns one of
717.Ar TLS_OCSP_CERT_GOOD , 711.Ar TLS_OCSP_CERT_GOOD ,
718.Ar TLS_OCSP_CERT_REVOKED , 712.Ar TLS_OCSP_CERT_REVOKED ,
719or 713or
720.Ar TLS_OCSP_CERT_UNKNOWN 714.Ar TLS_OCSP_CERT_UNKNOWN
721on success, and -1 on error. 715on success, and -1 on error.
722.Pp 716.Pp
723The 717The
724.Fn tls_peer_ocsp_crl_reason 718.Fn tls_peer_ocsp_crl_reason
725function returns one of 719function returns one of
726.Ar TLS_CRL_REASON_UNSPECIFIED , 720.Ar TLS_CRL_REASON_UNSPECIFIED ,
727.Ar TLS_CRL_REASON_KEY_COMPROMISE , 721.Ar TLS_CRL_REASON_KEY_COMPROMISE ,
728.Ar TLS_CRL_REASON_CA_COMPROMISE , 722.Ar TLS_CRL_REASON_CA_COMPROMISE ,
729.Ar TLS_CRL_REASON_AFFILIATION_CHANGED , 723.Ar TLS_CRL_REASON_AFFILIATION_CHANGED ,
730.Ar TLS_CRL_REASON_SUPERSEDED , 724.Ar TLS_CRL_REASON_SUPERSEDED ,
731.Ar TLS_CRL_REASON_CESSATION_OF_OPERATION , 725.Ar TLS_CRL_REASON_CESSATION_OF_OPERATION ,
732.Ar TLS_CRL_REASON_CERTIFICATE_HOLD , 726.Ar TLS_CRL_REASON_CERTIFICATE_HOLD ,
733.Ar TLS_CRL_REASON_REMOVE_FROM_CRL , 727.Ar TLS_CRL_REASON_REMOVE_FROM_CRL ,
734.Ar TLS_CRL_REASON_PRIVILEGE_WITHDRAWN , 728.Ar TLS_CRL_REASON_PRIVILEGE_WITHDRAWN ,
735or 729or
736.Ar TLS_CRL_REASON_AA_COMPROMISE 730.Ar TLS_CRL_REASON_AA_COMPROMISE
737on success, and -1 on error. 731on success, and -1 on error.
738.Pp 732.Pp