summaryrefslogtreecommitdiff
path: root/src/lib/libtls/tls_init.3
diff options
context:
space:
mode:
authorbeck <>2015-09-13 10:32:46 +0000
committerbeck <>2015-09-13 10:32:46 +0000
commitf93b2a484d9aebe61957094cb379ae61ed797792 (patch)
treeaab2e062ca9f5654643e90c10a858b88227429bb /src/lib/libtls/tls_init.3
parent12350069f382f5c9604542a187f5f13cdc426704 (diff)
downloadopenbsd-f93b2a484d9aebe61957094cb379ae61ed797792.tar.gz
openbsd-f93b2a484d9aebe61957094cb379ae61ed797792.tar.bz2
openbsd-f93b2a484d9aebe61957094cb379ae61ed797792.zip
add visibility of ciper and connection version strings
ok jsing@
Diffstat (limited to 'src/lib/libtls/tls_init.3')
-rw-r--r--src/lib/libtls/tls_init.326
1 files changed, 23 insertions, 3 deletions
diff --git a/src/lib/libtls/tls_init.3 b/src/lib/libtls/tls_init.3
index 90cbdb3f3b..ead2a8095d 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.43 2015/09/12 21:00:38 beck Exp $ 1.\" $OpenBSD: tls_init.3,v 1.44 2015/09/13 10:32:46 beck Exp $
2.\" 2.\"
3.\" Copyright (c) 2014 Ted Unangst <tedu@openbsd.org> 3.\" Copyright (c) 2014 Ted Unangst <tedu@openbsd.org>
4.\" 4.\"
@@ -14,7 +14,7 @@
14.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 14.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 15.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16.\" 16.\"
17.Dd $Mdocdate: September 12 2015 $ 17.Dd $Mdocdate: September 13 2015 $
18.Dt TLS_INIT 3 18.Dt TLS_INIT 3
19.Os 19.Os
20.Sh NAME 20.Sh NAME
@@ -127,6 +127,10 @@
127.Fn tls_peer_cert_subject "struct tls *ctx" 127.Fn tls_peer_cert_subject "struct tls *ctx"
128.Ft "const char *" 128.Ft "const char *"
129.Fn tls_peer_cert_hash "struct tls *ctx" 129.Fn tls_peer_cert_hash "struct tls *ctx"
130.Ft "const char *"
131.Fn tls_conn_version "struct tls *ctx"
132.Ft "const char *"
133.Fn tls_conn_cipher "struct tls *ctx"
130.Ft "uint8_t *" 134.Ft "uint8_t *"
131.Fn tls_load_file "const char *file" "size_t *len" "char *password" 135.Fn tls_load_file "const char *file" "size_t *len" "char *password"
132.Ft "struct tls *" 136.Ft "struct tls *"
@@ -416,7 +420,23 @@ h=$(openssl x509 -outform der -in mycert.crt | sha256)
416printf "SHA256:${h}\\n" 420printf "SHA256:${h}\\n"
417.Ed 421.Ed
418.Pp 422.Pp
419.Fn tls_peer_cert_subject 423.It
424.Fn tls_conn_version
425returns a string
426corresponding to a TLS version negotiated with the peer
427connected to
428.Ar ctx
429.It
430.Fn tls_conn_version
431will only succeed after the handshake is complete.
432.It
433.Fn tls_conn_cipher
434returns a string
435corresponding to a the cipher suite negotated with the peer
436connected to
437.Ar ctx
438.It
439.Fn tls_conn_cipher
420will only succeed after the handshake is complete. 440will only succeed after the handshake is complete.
421.Em (Server and client) 441.Em (Server and client)
422.It 442.It