Hex Artifact Content

Artifact e9944a86e0f9a518d2eb9852abd118e2a490210ea0e4e84fbea7852fad15619a:


0000: 3c 21 44 4f 43 54 59 50 45 20 68 74 6d 6c 3e 3c  <!DOCTYPE html><
0010: 68 74 6d 6c 3e 3c 68 65 61 64 3e 0a 3c 6d 65 74  html><head>.<met
0020: 61 20 63 68 61 72 73 65 74 3d 22 55 54 46 2d 38  a charset="UTF-8
0030: 22 3e 0a 3c 6d 65 74 61 20 6e 61 6d 65 3d 22 76  ">.<meta name="v
0040: 69 65 77 70 6f 72 74 22 20 63 6f 6e 74 65 6e 74  iewport" content
0050: 3d 22 77 69 64 74 68 3d 64 65 76 69 63 65 2d 77  ="width=device-w
0060: 69 64 74 68 2c 20 69 6e 69 74 69 61 6c 2d 73 63  idth, initial-sc
0070: 61 6c 65 3d 31 22 3e 0a 3c 74 69 74 6c 65 3e 74  ale=1">.<title>t
0080: 6c 73 20 2d 20 54 63 6c 20 54 4c 53 20 65 78 74  ls - Tcl TLS ext
0090: 65 6e 73 69 6f 6e 3c 2f 74 69 74 6c 65 3e 0a 3c  ension</title>.<
00a0: 73 74 79 6c 65 20 74 79 70 65 3d 22 74 65 78 74  style type="text
00b0: 2f 63 73 73 22 3e 3c 21 2d 2d 0a 20 20 20 20 48  /css"><!--.    H
00c0: 54 4d 4c 20 7b 0a 09 62 61 63 6b 67 72 6f 75 6e  TML {..backgroun
00d0: 64 3a 20 09 23 46 46 46 46 46 46 3b 0a 09 63 6f  d: .#FFFFFF;..co
00e0: 6c 6f 72 3a 20 09 09 62 6c 61 63 6b 3b 0a 20 20  lor: ..black;.  
00f0: 20 20 7d 0a 20 20 20 20 42 4f 44 59 20 7b 0a 09    }.    BODY {..
0100: 62 61 63 6b 67 72 6f 75 6e 64 3a 20 09 23 46 46  background: .#FF
0110: 46 46 46 46 3b 0a 09 63 6f 6c 6f 72 3a 09 20 09  FFFF;..color:. .
0120: 62 6c 61 63 6b 3b 0a 20 20 20 20 7d 0a 20 20 20  black;.    }.   
0130: 20 44 49 56 2e 64 6f 63 74 6f 6f 6c 73 20 7b 0a   DIV.doctools {.
0140: 09 6d 61 72 67 69 6e 2d 6c 65 66 74 3a 09 31 30  .margin-left:.10
0150: 25 3b 0a 09 6d 61 72 67 69 6e 2d 72 69 67 68 74  %;..margin-right
0160: 3a 09 31 30 25 3b 0a 20 20 20 20 7d 0a 20 20 20  :.10%;.    }.   
0170: 20 44 49 56 2e 64 6f 63 74 6f 6f 6c 73 20 48 31   DIV.doctools H1
0180: 2c 44 49 56 2e 64 6f 63 74 6f 6f 6c 73 20 48 32  ,DIV.doctools H2
0190: 20 7b 0a 09 6d 61 72 67 69 6e 2d 6c 65 66 74 3a   {..margin-left:
01a0: 09 2d 35 25 3b 0a 20 20 20 20 7d 0a 20 20 20 20  .-5%;.    }.    
01b0: 48 31 2c 20 48 32 2c 20 48 33 2c 20 48 34 20 7b  H1, H2, H3, H4 {
01c0: 0a 09 6d 61 72 67 69 6e 2d 74 6f 70 3a 20 09 31  ..margin-top: .1
01d0: 65 6d 3b 0a 09 66 6f 6e 74 2d 66 61 6d 69 6c 79  em;..font-family
01e0: 3a 09 73 61 6e 73 2d 73 65 72 69 66 3b 0a 09 66  :.sans-serif;..f
01f0: 6f 6e 74 2d 73 69 7a 65 3a 09 6c 61 72 67 65 3b  ont-size:.large;
0200: 0a 09 63 6f 6c 6f 72 3a 09 09 23 30 30 35 41 39  ..color:..#005A9
0210: 43 3b 0a 09 62 61 63 6b 67 72 6f 75 6e 64 3a 20  C;..background: 
0220: 09 74 72 61 6e 73 70 61 72 65 6e 74 3b 0a 09 74  .transparent;..t
0230: 65 78 74 2d 61 6c 69 67 6e 3a 09 09 6c 65 66 74  ext-align:..left
0240: 3b 0a 20 20 20 20 7d 0a 20 20 20 20 48 31 2e 64  ;.    }.    H1.d
0250: 6f 63 74 6f 6f 6c 73 5f 74 69 74 6c 65 20 7b 0a  octools_title {.
0260: 09 74 65 78 74 2d 61 6c 69 67 6e 3a 20 63 65 6e  .text-align: cen
0270: 74 65 72 3b 0a 20 20 20 20 7d 0a 20 20 20 20 55  ter;.    }.    U
0280: 4c 2c 4f 4c 20 7b 0a 09 6d 61 72 67 69 6e 2d 72  L,OL {..margin-r
0290: 69 67 68 74 3a 20 30 65 6d 3b 0a 09 6d 61 72 67  ight: 0em;..marg
02a0: 69 6e 2d 74 6f 70 3a 20 33 70 74 3b 0a 09 6d 61  in-top: 3pt;..ma
02b0: 72 67 69 6e 2d 62 6f 74 74 6f 6d 3a 20 33 70 74  rgin-bottom: 3pt
02c0: 3b 0a 20 20 20 20 7d 0a 20 20 20 20 55 4c 20 4c  ;.    }.    UL L
02d0: 49 20 7b 0a 09 6c 69 73 74 2d 73 74 79 6c 65 3a  I {..list-style:
02e0: 20 64 69 73 63 3b 0a 20 20 20 20 7d 0a 20 20 20   disc;.    }.   
02f0: 20 4f 4c 20 4c 49 20 7b 0a 09 6c 69 73 74 2d 73   OL LI {..list-s
0300: 74 79 6c 65 3a 20 64 65 63 69 6d 61 6c 3b 0a 20  tyle: decimal;. 
0310: 20 20 20 7d 0a 20 20 20 20 44 54 20 7b 0a 09 70     }.    DT {..p
0320: 61 64 64 69 6e 67 2d 74 6f 70 3a 20 09 31 65 78  adding-top: .1ex
0330: 3b 0a 20 20 20 20 7d 0a 20 20 20 20 55 4c 2e 64  ;.    }.    UL.d
0340: 6f 63 74 6f 6f 6c 73 5f 74 6f 63 2c 55 4c 2e 64  octools_toc,UL.d
0350: 6f 63 74 6f 6f 6c 73 5f 74 6f 63 20 55 4c 2c 20  octools_toc UL, 
0360: 55 4c 2e 64 6f 63 74 6f 6f 6c 73 5f 74 6f 63 20  UL.doctools_toc 
0370: 55 4c 20 55 4c 20 7b 0a 09 66 6f 6e 74 3a 09 09  UL UL {..font:..
0380: 6e 6f 72 6d 61 6c 20 31 32 70 74 2f 31 34 70 74  normal 12pt/14pt
0390: 20 73 61 6e 73 2d 73 65 72 69 66 3b 0a 09 6c 69   sans-serif;..li
03a0: 73 74 2d 73 74 79 6c 65 3a 09 6e 6f 6e 65 3b 0a  st-style:.none;.
03b0: 20 20 20 20 7d 0a 20 20 20 20 4c 49 2e 64 6f 63      }.    LI.doc
03c0: 74 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e 2c 20 4c  tools_section, L
03d0: 49 2e 64 6f 63 74 6f 6f 6c 73 5f 73 75 62 73 65  I.doctools_subse
03e0: 63 74 69 6f 6e 20 7b 0a 09 6c 69 73 74 2d 73 74  ction {..list-st
03f0: 79 6c 65 3a 20 09 6e 6f 6e 65 3b 0a 09 6d 61 72  yle: .none;..mar
0400: 67 69 6e 2d 6c 65 66 74 3a 20 09 30 65 6d 3b 0a  gin-left: .0em;.
0410: 09 74 65 78 74 2d 69 6e 64 65 6e 74 3a 09 30 65  .text-indent:.0e
0420: 6d 3b 0a 09 70 61 64 64 69 6e 67 3a 20 09 30 65  m;..padding: .0e
0430: 6d 3b 0a 20 20 20 20 7d 0a 20 20 20 20 50 52 45  m;.    }.    PRE
0440: 20 7b 0a 09 64 69 73 70 6c 61 79 3a 20 09 62 6c   {..display: .bl
0450: 6f 63 6b 3b 0a 09 66 6f 6e 74 2d 66 61 6d 69 6c  ock;..font-famil
0460: 79 3a 09 6d 6f 6e 6f 73 70 61 63 65 3b 0a 09 77  y:.monospace;..w
0470: 68 69 74 65 2d 73 70 61 63 65 3a 09 70 72 65 3b  hite-space:.pre;
0480: 0a 09 6d 61 72 67 69 6e 3a 09 09 30 25 3b 0a 09  ..margin:..0%;..
0490: 70 61 64 64 69 6e 67 2d 74 6f 70 3a 09 30 2e 35  padding-top:.0.5
04a0: 65 78 3b 0a 09 70 61 64 64 69 6e 67 2d 62 6f 74  ex;..padding-bot
04b0: 74 6f 6d 3a 09 30 2e 35 65 78 3b 0a 09 70 61 64  tom:.0.5ex;..pad
04c0: 64 69 6e 67 2d 6c 65 66 74 3a 09 31 65 78 3b 0a  ding-left:.1ex;.
04d0: 09 70 61 64 64 69 6e 67 2d 72 69 67 68 74 3a 09  .padding-right:.
04e0: 31 65 78 3b 0a 09 77 69 64 74 68 3a 09 09 31 30  1ex;..width:..10
04f0: 30 25 3b 0a 20 20 20 20 7d 0a 20 20 20 20 50 52  0%;.    }.    PR
0500: 45 2e 64 6f 63 74 6f 6f 6c 73 5f 65 78 61 6d 70  E.doctools_examp
0510: 6c 65 20 7b 0a 09 63 6f 6c 6f 72 3a 20 09 09 62  le {..color: ..b
0520: 6c 61 63 6b 3b 0a 09 62 61 63 6b 67 72 6f 75 6e  lack;..backgroun
0530: 64 3a 20 09 23 66 35 64 63 62 33 3b 0a 09 62 6f  d: .#f5dcb3;..bo
0540: 72 64 65 72 3a 09 09 31 70 78 20 73 6f 6c 69 64  rder:..1px solid
0550: 20 62 6c 61 63 6b 3b 0a 20 20 20 20 7d 0a 20 20   black;.    }.  
0560: 20 20 55 4c 2e 64 6f 63 74 6f 6f 6c 73 5f 72 65    UL.doctools_re
0570: 71 75 69 72 65 6d 65 6e 74 73 20 4c 49 2c 20 55  quirements LI, U
0580: 4c 2e 64 6f 63 74 6f 6f 6c 73 5f 73 79 6e 74 61  L.doctools_synta
0590: 78 20 4c 49 20 7b 0a 09 6c 69 73 74 2d 73 74 79  x LI {..list-sty
05a0: 6c 65 3a 20 09 6e 6f 6e 65 3b 0a 09 6d 61 72 67  le: .none;..marg
05b0: 69 6e 2d 6c 65 66 74 3a 20 09 30 65 6d 3b 0a 09  in-left: .0em;..
05c0: 74 65 78 74 2d 69 6e 64 65 6e 74 3a 09 30 65 6d  text-indent:.0em
05d0: 3b 0a 09 70 61 64 64 69 6e 67 3a 09 30 65 6d 3b  ;..padding:.0em;
05e0: 0a 20 20 20 20 7d 0a 20 20 20 20 44 49 56 2e 64  .    }.    DIV.d
05f0: 6f 63 74 6f 6f 6c 73 5f 73 79 6e 6f 70 73 69 73  octools_synopsis
0600: 20 7b 0a 09 63 6f 6c 6f 72 3a 20 09 09 62 6c 61   {..color: ..bla
0610: 63 6b 3b 0a 09 62 61 63 6b 67 72 6f 75 6e 64 3a  ck;..background:
0620: 20 09 23 38 30 66 66 66 66 3b 0a 09 62 6f 72 64   .#80ffff;..bord
0630: 65 72 3a 09 09 31 70 78 20 73 6f 6c 69 64 20 62  er:..1px solid b
0640: 6c 61 63 6b 3b 0a 09 66 6f 6e 74 2d 66 61 6d 69  lack;..font-fami
0650: 6c 79 3a 09 73 65 72 69 66 3b 0a 09 6d 61 72 67  ly:.serif;..marg
0660: 69 6e 2d 74 6f 70 3a 20 09 31 65 6d 3b 0a 09 6d  in-top: .1em;..m
0670: 61 72 67 69 6e 2d 62 6f 74 74 6f 6d 3a 20 09 31  argin-bottom: .1
0680: 65 6d 3b 0a 20 20 20 20 7d 0a 20 20 20 20 55 4c  em;.    }.    UL
0690: 2e 64 6f 63 74 6f 6f 6c 73 5f 73 79 6e 74 61 78  .doctools_syntax
06a0: 20 7b 0a 09 6d 61 72 67 69 6e 2d 74 6f 70 3a 20   {..margin-top: 
06b0: 09 31 65 6d 3b 0a 09 62 6f 72 64 65 72 2d 74 6f  .1em;..border-to
06c0: 70 3a 09 31 70 78 20 73 6f 6c 69 64 20 62 6c 61  p:.1px solid bla
06d0: 63 6b 3b 0a 20 20 20 20 7d 0a 20 20 20 20 55 4c  ck;.    }.    UL
06e0: 2e 64 6f 63 74 6f 6f 6c 73 5f 72 65 71 75 69 72  .doctools_requir
06f0: 65 6d 65 6e 74 73 20 7b 0a 09 6d 61 72 67 69 6e  ements {..margin
0700: 2d 62 6f 74 74 6f 6d 3a 20 09 31 65 6d 3b 0a 09  -bottom: .1em;..
0710: 62 6f 72 64 65 72 2d 62 6f 74 74 6f 6d 3a 09 31  border-bottom:.1
0720: 70 78 20 73 6f 6c 69 64 20 62 6c 61 63 6b 3b 0a  px solid black;.
0730: 20 20 20 20 7d 0a 2d 2d 3e 3c 2f 73 74 79 6c 65      }.--></style
0740: 3e 0a 3c 2f 68 65 61 64 3e 0a 3c 21 2d 2d 20 47  >.</head>.<!-- G
0750: 65 6e 65 72 61 74 65 64 20 66 72 6f 6d 20 66 69  enerated from fi
0760: 6c 65 20 27 74 6c 73 2e 6d 61 6e 27 20 62 79 20  le 'tls.man' by 
0770: 74 63 6c 6c 69 62 2f 64 6f 63 74 6f 6f 6c 73 20  tcllib/doctools 
0780: 77 69 74 68 20 66 6f 72 6d 61 74 20 27 68 74 6d  with format 'htm
0790: 6c 27 0a 20 20 20 2d 2d 3e 0a 3c 21 2d 2d 20 43  l'.   -->.<!-- C
07a0: 6f 70 79 72 69 67 68 74 20 26 61 6d 70 3b 63 6f  opyright &amp;co
07b0: 70 79 3b 20 31 39 39 39 20 4d 61 74 74 20 4e 65  py; 1999 Matt Ne
07c0: 77 6d 61 6e 20 20 20 2d 2d 20 43 6f 70 79 72 69  wman   -- Copyri
07d0: 67 68 74 20 26 61 6d 70 3b 63 6f 70 79 3b 20 32  ght &amp;copy; 2
07e0: 30 30 34 20 53 74 61 72 66 69 73 68 20 53 79 73  004 Starfish Sys
07f0: 74 65 6d 73 20 20 20 2d 2d 20 43 6f 70 79 72 69  tems   -- Copyri
0800: 67 68 74 20 26 61 6d 70 3b 63 6f 70 79 3b 20 32  ght &amp;copy; 2
0810: 30 32 34 20 42 72 69 61 6e 20 4f 27 48 61 67 61  024 Brian O'Haga
0820: 6e 0a 20 20 20 2d 2d 3e 0a 3c 21 2d 2d 20 74 6c  n.   -->.<!-- tl
0830: 73 2e 6e 0a 20 20 20 2d 2d 3e 0a 3c 62 6f 64 79  s.n.   -->.<body
0840: 3e 3c 64 69 76 20 63 6c 61 73 73 3d 22 64 6f 63  ><div class="doc
0850: 74 6f 6f 6c 73 22 3e 0a 3c 68 31 20 63 6c 61 73  tools">.<h1 clas
0860: 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 74 69 74 6c  s="doctools_titl
0870: 65 22 3e 74 6c 73 28 6e 29 20 32 2e 30 62 31 20  e">tls(n) 2.0b1 
0880: 74 6c 73 20 26 71 75 6f 74 3b 54 63 6c 20 54 4c  tls &quot;Tcl TL
0890: 53 20 65 78 74 65 6e 73 69 6f 6e 26 71 75 6f 74  S extension&quot
08a0: 3b 3c 2f 68 31 3e 0a 3c 64 69 76 20 69 64 3d 22  ;</h1>.<div id="
08b0: 6e 61 6d 65 22 20 63 6c 61 73 73 3d 22 64 6f 63  name" class="doc
08c0: 74 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c  tools_section"><
08d0: 68 32 3e 3c 61 20 6e 61 6d 65 3d 22 6e 61 6d 65  h2><a name="name
08e0: 22 3e 4e 61 6d 65 3c 2f 61 3e 3c 2f 68 32 3e 0a  ">Name</a></h2>.
08f0: 3c 70 3e 74 6c 73 20 2d 20 62 69 6e 64 69 6e 67  <p>tls - binding
0900: 20 74 6f 20 74 68 65 20 4f 70 65 6e 53 53 4c 20   to the OpenSSL 
0910: 6c 69 62 72 61 72 79 20 66 6f 72 20 65 6e 63 72  library for encr
0920: 79 70 74 65 64 20 73 6f 63 6b 65 74 20 61 6e 64  ypted socket and
0930: 20 49 2f 4f 20 63 68 61 6e 6e 65 6c 20 63 6f 6d   I/O channel com
0940: 6d 75 6e 69 63 61 74 69 6f 6e 73 3c 2f 70 3e 0a  munications</p>.
0950: 3c 2f 64 69 76 3e 0a 3c 64 69 76 20 69 64 3d 22  </div>.<div id="
0960: 74 6f 63 22 20 63 6c 61 73 73 3d 22 64 6f 63 74  toc" class="doct
0970: 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c 68  ools_section"><h
0980: 32 3e 3c 61 20 6e 61 6d 65 3d 22 74 6f 63 22 3e  2><a name="toc">
0990: 54 61 62 6c 65 20 4f 66 20 43 6f 6e 74 65 6e 74  Table Of Content
09a0: 73 3c 2f 61 3e 3c 2f 68 32 3e 0a 3c 75 6c 20 63  s</a></h2>.<ul c
09b0: 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 74  lass="doctools_t
09c0: 6f 63 22 3e 0a 3c 6c 69 20 63 6c 61 73 73 3d 22  oc">.<li class="
09d0: 64 6f 63 74 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e  doctools_section
09e0: 22 3e 3c 61 20 68 72 65 66 3d 22 23 74 6f 63 22  "><a href="#toc"
09f0: 3e 54 61 62 6c 65 20 4f 66 20 43 6f 6e 74 65 6e  >Table Of Conten
0a00: 74 73 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c 69 20  ts</a></li>.<li 
0a10: 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f  class="doctools_
0a20: 73 65 63 74 69 6f 6e 22 3e 3c 61 20 68 72 65 66  section"><a href
0a30: 3d 22 23 73 79 6e 6f 70 73 69 73 22 3e 53 79 6e  ="#synopsis">Syn
0a40: 6f 70 73 69 73 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c  opsis</a></li>.<
0a50: 6c 69 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f  li class="doctoo
0a60: 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c 61 20 68  ls_section"><a h
0a70: 72 65 66 3d 22 23 73 65 63 74 69 6f 6e 31 22 3e  ref="#section1">
0a80: 44 65 73 63 72 69 70 74 69 6f 6e 3c 2f 61 3e 3c  Description</a><
0a90: 2f 6c 69 3e 0a 3c 6c 69 20 63 6c 61 73 73 3d 22  /li>.<li class="
0aa0: 64 6f 63 74 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e  doctools_section
0ab0: 22 3e 3c 61 20 68 72 65 66 3d 22 23 73 65 63 74  "><a href="#sect
0ac0: 69 6f 6e 32 22 3e 43 6f 6d 70 61 74 69 62 69 6c  ion2">Compatibil
0ad0: 69 74 79 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c 69  ity</a></li>.<li
0ae0: 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73   class="doctools
0af0: 5f 73 65 63 74 69 6f 6e 22 3e 3c 61 20 68 72 65  _section"><a hre
0b00: 66 3d 22 23 73 65 63 74 69 6f 6e 33 22 3e 43 6f  f="#section3">Co
0b10: 6d 6d 61 6e 64 73 3c 2f 61 3e 3c 2f 6c 69 3e 0a  mmands</a></li>.
0b20: 3c 6c 69 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f  <li class="docto
0b30: 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c 61 20  ols_section"><a 
0b40: 68 72 65 66 3d 22 23 73 65 63 74 69 6f 6e 34 22  href="#section4"
0b50: 3e 43 65 72 74 69 66 69 63 61 74 65 20 56 61 6c  >Certificate Val
0b60: 69 64 61 74 69 6f 6e 3c 2f 61 3e 0a 3c 75 6c 3e  idation</a>.<ul>
0b70: 0a 3c 6c 69 20 63 6c 61 73 73 3d 22 64 6f 63 74  .<li class="doct
0b80: 6f 6f 6c 73 5f 73 75 62 73 65 63 74 69 6f 6e 22  ools_subsection"
0b90: 3e 3c 61 20 68 72 65 66 3d 22 23 73 75 62 73 65  ><a href="#subse
0ba0: 63 74 69 6f 6e 31 22 3e 50 4b 49 20 61 6e 64 20  ction1">PKI and 
0bb0: 43 65 72 74 69 66 69 63 61 74 65 73 3c 2f 61 3e  Certificates</a>
0bc0: 3c 2f 6c 69 3e 0a 3c 6c 69 20 63 6c 61 73 73 3d  </li>.<li class=
0bd0: 22 64 6f 63 74 6f 6f 6c 73 5f 73 75 62 73 65 63  "doctools_subsec
0be0: 74 69 6f 6e 22 3e 3c 61 20 68 72 65 66 3d 22 23  tion"><a href="#
0bf0: 73 75 62 73 65 63 74 69 6f 6e 32 22 3e 53 75 6d  subsection2">Sum
0c00: 6d 61 72 79 20 6f 66 20 63 6f 6d 6d 61 6e 64 20  mary of command 
0c10: 6c 69 6e 65 20 6f 70 74 69 6f 6e 73 3c 2f 61 3e  line options</a>
0c20: 3c 2f 6c 69 3e 0a 3c 6c 69 20 63 6c 61 73 73 3d  </li>.<li class=
0c30: 22 64 6f 63 74 6f 6f 6c 73 5f 73 75 62 73 65 63  "doctools_subsec
0c40: 74 69 6f 6e 22 3e 3c 61 20 68 72 65 66 3d 22 23  tion"><a href="#
0c50: 73 75 62 73 65 63 74 69 6f 6e 33 22 3e 57 68 65  subsection3">Whe
0c60: 6e 20 61 72 65 20 63 6f 6d 6d 61 6e 64 20 6c 69  n are command li
0c70: 6e 65 20 6f 70 74 69 6f 6e 73 20 6e 65 65 64 65  ne options neede
0c80: 64 3f 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 2f 75 6c  d?</a></li>.</ul
0c90: 3e 0a 3c 2f 6c 69 3e 0a 3c 6c 69 20 63 6c 61 73  >.</li>.<li clas
0ca0: 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73 65 63 74  s="doctools_sect
0cb0: 69 6f 6e 22 3e 3c 61 20 68 72 65 66 3d 22 23 73  ion"><a href="#s
0cc0: 65 63 74 69 6f 6e 35 22 3e 43 61 6c 6c 62 61 63  ection5">Callbac
0cd0: 6b 20 4f 70 74 69 6f 6e 73 3c 2f 61 3e 0a 3c 75  k Options</a>.<u
0ce0: 6c 3e 0a 3c 6c 69 20 63 6c 61 73 73 3d 22 64 6f  l>.<li class="do
0cf0: 63 74 6f 6f 6c 73 5f 73 75 62 73 65 63 74 69 6f  ctools_subsectio
0d00: 6e 22 3e 3c 61 20 68 72 65 66 3d 22 23 73 75 62  n"><a href="#sub
0d10: 73 65 63 74 69 6f 6e 34 22 3e 56 61 6c 75 65 73  section4">Values
0d20: 20 66 6f 72 20 43 6f 6d 6d 61 6e 64 20 43 61 6c   for Command Cal
0d30: 6c 62 61 63 6b 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c  lback</a></li>.<
0d40: 6c 69 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f  li class="doctoo
0d50: 6c 73 5f 73 75 62 73 65 63 74 69 6f 6e 22 3e 3c  ls_subsection"><
0d60: 61 20 68 72 65 66 3d 22 23 73 75 62 73 65 63 74  a href="#subsect
0d70: 69 6f 6e 35 22 3e 56 61 6c 75 65 73 20 66 6f 72  ion5">Values for
0d80: 20 50 61 73 73 77 6f 72 64 20 43 61 6c 6c 62 61   Password Callba
0d90: 63 6b 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c 69 20  ck</a></li>.<li 
0da0: 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f  class="doctools_
0db0: 73 75 62 73 65 63 74 69 6f 6e 22 3e 3c 61 20 68  subsection"><a h
0dc0: 72 65 66 3d 22 23 73 75 62 73 65 63 74 69 6f 6e  ref="#subsection
0dd0: 36 22 3e 56 61 6c 75 65 73 20 66 6f 72 20 56 61  6">Values for Va
0de0: 6c 69 64 61 74 65 20 43 6f 6d 6d 61 6e 64 20 43  lidate Command C
0df0: 61 6c 6c 62 61 63 6b 3c 2f 61 3e 3c 2f 6c 69 3e  allback</a></li>
0e00: 0a 3c 2f 75 6c 3e 0a 3c 2f 6c 69 3e 0a 3c 6c 69  .</ul>.</li>.<li
0e10: 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73   class="doctools
0e20: 5f 73 65 63 74 69 6f 6e 22 3e 3c 61 20 68 72 65  _section"><a hre
0e30: 66 3d 22 23 73 65 63 74 69 6f 6e 36 22 3e 44 65  f="#section6">De
0e40: 62 75 67 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c 69  bug</a></li>.<li
0e50: 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73   class="doctools
0e60: 5f 73 65 63 74 69 6f 6e 22 3e 3c 61 20 68 72 65  _section"><a hre
0e70: 66 3d 22 23 73 65 63 74 69 6f 6e 37 22 3e 45 78  f="#section7">Ex
0e80: 61 6d 70 6c 65 73 3c 2f 61 3e 3c 2f 6c 69 3e 0a  amples</a></li>.
0e90: 3c 6c 69 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f  <li class="docto
0ea0: 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c 61 20  ols_section"><a 
0eb0: 68 72 65 66 3d 22 23 73 65 63 74 69 6f 6e 38 22  href="#section8"
0ec0: 3e 53 70 65 63 69 61 6c 20 43 6f 6e 73 69 64 65  >Special Conside
0ed0: 72 61 74 69 6f 6e 73 3c 2f 61 3e 3c 2f 6c 69 3e  rations</a></li>
0ee0: 0a 3c 6c 69 20 63 6c 61 73 73 3d 22 64 6f 63 74  .<li class="doct
0ef0: 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c 61  ools_section"><a
0f00: 20 68 72 65 66 3d 22 23 73 65 65 2d 61 6c 73 6f   href="#see-also
0f10: 22 3e 53 65 65 20 41 6c 73 6f 3c 2f 61 3e 3c 2f  ">See Also</a></
0f20: 6c 69 3e 0a 3c 6c 69 20 63 6c 61 73 73 3d 22 64  li>.<li class="d
0f30: 6f 63 74 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e 22  octools_section"
0f40: 3e 3c 61 20 68 72 65 66 3d 22 23 6b 65 79 77 6f  ><a href="#keywo
0f50: 72 64 73 22 3e 4b 65 79 77 6f 72 64 73 3c 2f 61  rds">Keywords</a
0f60: 3e 3c 2f 6c 69 3e 0a 3c 6c 69 20 63 6c 61 73 73  ></li>.<li class
0f70: 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73 65 63 74 69  ="doctools_secti
0f80: 6f 6e 22 3e 3c 61 20 68 72 65 66 3d 22 23 63 61  on"><a href="#ca
0f90: 74 65 67 6f 72 79 22 3e 43 61 74 65 67 6f 72 79  tegory">Category
0fa0: 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c 69 20 63 6c  </a></li>.<li cl
0fb0: 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73 65  ass="doctools_se
0fc0: 63 74 69 6f 6e 22 3e 3c 61 20 68 72 65 66 3d 22  ction"><a href="
0fd0: 23 63 6f 70 79 72 69 67 68 74 22 3e 43 6f 70 79  #copyright">Copy
0fe0: 72 69 67 68 74 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c  right</a></li>.<
0ff0: 2f 75 6c 3e 0a 3c 2f 64 69 76 3e 0a 3c 64 69 76  /ul>.</div>.<div
1000: 20 69 64 3d 22 73 79 6e 6f 70 73 69 73 22 20 63   id="synopsis" c
1010: 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73  lass="doctools_s
1020: 65 63 74 69 6f 6e 22 3e 3c 68 32 3e 3c 61 20 6e  ection"><h2><a n
1030: 61 6d 65 3d 22 73 79 6e 6f 70 73 69 73 22 3e 53  ame="synopsis">S
1040: 79 6e 6f 70 73 69 73 3c 2f 61 3e 3c 2f 68 32 3e  ynopsis</a></h2>
1050: 0a 3c 64 69 76 20 63 6c 61 73 73 3d 22 64 6f 63  .<div class="doc
1060: 74 6f 6f 6c 73 5f 73 79 6e 6f 70 73 69 73 22 3e  tools_synopsis">
1070: 0a 3c 75 6c 20 63 6c 61 73 73 3d 22 64 6f 63 74  .<ul class="doct
1080: 6f 6f 6c 73 5f 72 65 71 75 69 72 65 6d 65 6e 74  ools_requirement
1090: 73 22 3e 0a 3c 6c 69 3e 70 61 63 6b 61 67 65 20  s">.<li>package 
10a0: 72 65 71 75 69 72 65 20 3c 62 20 63 6c 61 73 73  require <b class
10b0: 3d 22 70 6b 67 6e 61 6d 65 22 3e 54 63 6c 20 38  ="pkgname">Tcl 8
10c0: 2e 35 2d 3c 2f 62 3e 3c 2f 6c 69 3e 0a 3c 6c 69  .5-</b></li>.<li
10d0: 3e 70 61 63 6b 61 67 65 20 72 65 71 75 69 72 65  >package require
10e0: 20 3c 62 20 63 6c 61 73 73 3d 22 70 6b 67 6e 61   <b class="pkgna
10f0: 6d 65 22 3e 74 6c 73 20 32 2e 30 62 31 3c 2f 62  me">tls 2.0b1</b
1100: 3e 3c 2f 6c 69 3e 0a 3c 2f 75 6c 3e 0a 3c 75 6c  ></li>.</ul>.<ul
1110: 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73   class="doctools
1120: 5f 73 79 6e 74 61 78 22 3e 0a 3c 6c 69 3e 3c 61  _syntax">.<li><a
1130: 20 68 72 65 66 3d 22 23 31 22 3e 3c 62 20 63 6c   href="#1"><b cl
1140: 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 69  ass="cmd">tls::i
1150: 6e 69 74 3c 2f 62 3e 20 3c 73 70 61 6e 20 63 6c  nit</b> <span cl
1160: 61 73 73 3d 22 6f 70 74 22 3e 3f 3c 69 20 63 6c  ass="opt">?<i cl
1170: 61 73 73 3d 22 61 72 67 22 3e 2d 6f 70 74 69 6f  ass="arg">-optio
1180: 6e 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e 20 3c 73  n</i>?</span> <s
1190: 70 61 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22 3e  pan class="opt">
11a0: 3f 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e  ?<i class="arg">
11b0: 76 61 6c 75 65 3c 2f 69 3e 3f 3c 2f 73 70 61 6e  value</i>?</span
11c0: 3e 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 6f  > <span class="o
11d0: 70 74 22 3e 3f 3c 69 20 63 6c 61 73 73 3d 22 61  pt">?<i class="a
11e0: 72 67 22 3e 2d 6f 70 74 69 6f 6e 20 76 61 6c 75  rg">-option valu
11f0: 65 20 2e 2e 2e 3c 2f 69 3e 3f 3c 2f 73 70 61 6e  e ...</i>?</span
1200: 3e 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c 69 3e 3c  ></a></li>.<li><
1210: 61 20 68 72 65 66 3d 22 23 32 22 3e 3c 62 20 63  a href="#2"><b c
1220: 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a  lass="cmd">tls::
1230: 73 6f 63 6b 65 74 3c 2f 62 3e 20 3c 73 70 61 6e  socket</b> <span
1240: 20 63 6c 61 73 73 3d 22 6f 70 74 22 3e 3f 3c 69   class="opt">?<i
1250: 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 2d 6f 70   class="arg">-op
1260: 74 69 6f 6e 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e  tion</i>?</span>
1270: 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 6f 70   <span class="op
1280: 74 22 3e 3f 3c 69 20 63 6c 61 73 73 3d 22 61 72  t">?<i class="ar
1290: 67 22 3e 76 61 6c 75 65 3c 2f 69 3e 3f 3c 2f 73  g">value</i>?</s
12a0: 70 61 6e 3e 20 3c 73 70 61 6e 20 63 6c 61 73 73  pan> <span class
12b0: 3d 22 6f 70 74 22 3e 3f 3c 69 20 63 6c 61 73 73  ="opt">?<i class
12c0: 3d 22 61 72 67 22 3e 2d 6f 70 74 69 6f 6e 20 76  ="arg">-option v
12d0: 61 6c 75 65 20 2e 2e 2e 3c 2f 69 3e 3f 3c 2f 73  alue ...</i>?</s
12e0: 70 61 6e 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61  pan> <i class="a
12f0: 72 67 22 3e 68 6f 73 74 3c 2f 69 3e 20 3c 69 20  rg">host</i> <i 
1300: 63 6c 61 73 73 3d 22 61 72 67 22 3e 70 6f 72 74  class="arg">port
1310: 3c 2f 69 3e 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c  </i></a></li>.<l
1320: 69 3e 3c 61 20 68 72 65 66 3d 22 23 33 22 3e 3c  i><a href="#3"><
1330: 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c  b class="cmd">tl
1340: 73 3a 3a 73 6f 63 6b 65 74 3c 2f 62 3e 20 3c 62  s::socket</b> <b
1350: 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e   class="option">
1360: 2d 73 65 72 76 65 72 3c 2f 62 3e 20 3c 69 20 63  -server</b> <i c
1370: 6c 61 73 73 3d 22 61 72 67 22 3e 63 6f 6d 6d 61  lass="arg">comma
1380: 6e 64 3c 2f 69 3e 20 3c 73 70 61 6e 20 63 6c 61  nd</i> <span cla
1390: 73 73 3d 22 6f 70 74 22 3e 3f 3c 69 20 63 6c 61  ss="opt">?<i cla
13a0: 73 73 3d 22 61 72 67 22 3e 2d 6f 70 74 69 6f 6e  ss="arg">-option
13b0: 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e 20 3c 73 70  </i>?</span> <sp
13c0: 61 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22 3e 3f  an class="opt">?
13d0: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 76  <i class="arg">v
13e0: 61 6c 75 65 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e  alue</i>?</span>
13f0: 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 6f 70   <span class="op
1400: 74 22 3e 3f 3c 69 20 63 6c 61 73 73 3d 22 61 72  t">?<i class="ar
1410: 67 22 3e 2d 6f 70 74 69 6f 6e 20 76 61 6c 75 65  g">-option value
1420: 20 2e 2e 2e 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e   ...</i>?</span>
1430: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
1440: 70 6f 72 74 3c 2f 69 3e 3c 2f 61 3e 3c 2f 6c 69  port</i></a></li
1450: 3e 0a 3c 6c 69 3e 3c 61 20 68 72 65 66 3d 22 23  >.<li><a href="#
1460: 34 22 3e 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64  4"><b class="cmd
1470: 22 3e 74 6c 73 3a 3a 69 6d 70 6f 72 74 3c 2f 62  ">tls::import</b
1480: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  > <i class="arg"
1490: 3e 63 68 61 6e 6e 65 6c 3c 2f 69 3e 20 3c 73 70  >channel</i> <sp
14a0: 61 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22 3e 3f  an class="opt">?
14b0: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 2d  <i class="arg">-
14c0: 6f 70 74 69 6f 6e 3c 2f 69 3e 3f 3c 2f 73 70 61  option</i>?</spa
14d0: 6e 3e 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22  n> <span class="
14e0: 6f 70 74 22 3e 3f 3c 69 20 63 6c 61 73 73 3d 22  opt">?<i class="
14f0: 61 72 67 22 3e 76 61 6c 75 65 3c 2f 69 3e 3f 3c  arg">value</i>?<
1500: 2f 73 70 61 6e 3e 20 3c 73 70 61 6e 20 63 6c 61  /span> <span cla
1510: 73 73 3d 22 6f 70 74 22 3e 3f 3c 69 20 63 6c 61  ss="opt">?<i cla
1520: 73 73 3d 22 61 72 67 22 3e 2d 6f 70 74 69 6f 6e  ss="arg">-option
1530: 20 76 61 6c 75 65 20 2e 2e 2e 3c 2f 69 3e 3f 3c   value ...</i>?<
1540: 2f 73 70 61 6e 3e 3c 2f 61 3e 3c 2f 6c 69 3e 0a  /span></a></li>.
1550: 3c 6c 69 3e 3c 61 20 68 72 65 66 3d 22 23 35 22  <li><a href="#5"
1560: 3e 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e  ><b class="cmd">
1570: 74 6c 73 3a 3a 75 6e 69 6d 70 6f 72 74 3c 2f 62  tls::unimport</b
1580: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  > <i class="arg"
1590: 3e 63 68 61 6e 6e 65 6c 3c 2f 69 3e 3c 2f 61 3e  >channel</i></a>
15a0: 3c 2f 6c 69 3e 0a 3c 6c 69 3e 3c 61 20 68 72 65  </li>.<li><a hre
15b0: 66 3d 22 23 36 22 3e 3c 62 20 63 6c 61 73 73 3d  f="#6"><b class=
15c0: 22 63 6d 64 22 3e 74 6c 73 3a 3a 68 61 6e 64 73  "cmd">tls::hands
15d0: 68 61 6b 65 3c 2f 62 3e 20 3c 69 20 63 6c 61 73  hake</b> <i clas
15e0: 73 3d 22 61 72 67 22 3e 63 68 61 6e 6e 65 6c 3c  s="arg">channel<
15f0: 2f 69 3e 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c 69  /i></a></li>.<li
1600: 3e 3c 61 20 68 72 65 66 3d 22 23 37 22 3e 3c 62  ><a href="#7"><b
1610: 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73   class="cmd">tls
1620: 3a 3a 73 74 61 74 75 73 3c 2f 62 3e 20 3c 73 70  ::status</b> <sp
1630: 61 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22 3e 3f  an class="opt">?
1640: 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e  <b class="option
1650: 22 3e 2d 6c 6f 63 61 6c 3c 2f 62 3e 3f 3c 2f 73  ">-local</b>?</s
1660: 70 61 6e 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61  pan> <i class="a
1670: 72 67 22 3e 63 68 61 6e 6e 65 6c 3c 2f 69 3e 3c  rg">channel</i><
1680: 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c 69 3e 3c 61 20  /a></li>.<li><a 
1690: 68 72 65 66 3d 22 23 38 22 3e 3c 62 20 63 6c 61  href="#8"><b cla
16a0: 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 63 6f  ss="cmd">tls::co
16b0: 6e 6e 65 63 74 69 6f 6e 3c 2f 62 3e 20 3c 69 20  nnection</b> <i 
16c0: 63 6c 61 73 73 3d 22 61 72 67 22 3e 63 68 61 6e  class="arg">chan
16d0: 6e 65 6c 3c 2f 69 3e 3c 2f 61 3e 3c 2f 6c 69 3e  nel</i></a></li>
16e0: 0a 3c 6c 69 3e 3c 61 20 68 72 65 66 3d 22 23 39  .<li><a href="#9
16f0: 22 3e 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22  "><b class="cmd"
1700: 3e 74 6c 73 3a 3a 63 69 70 68 65 72 73 3c 2f 62  >tls::ciphers</b
1710: 3e 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 6f  > <span class="o
1720: 70 74 22 3e 3f 3c 69 20 63 6c 61 73 73 3d 22 61  pt">?<i class="a
1730: 72 67 22 3e 70 72 6f 74 6f 63 6f 6c 3c 2f 69 3e  rg">protocol</i>
1740: 3f 3c 2f 73 70 61 6e 3e 20 3c 73 70 61 6e 20 63  ?</span> <span c
1750: 6c 61 73 73 3d 22 6f 70 74 22 3e 3f 3c 69 20 63  lass="opt">?<i c
1760: 6c 61 73 73 3d 22 61 72 67 22 3e 76 65 72 62 6f  lass="arg">verbo
1770: 73 65 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e 20 3c  se</i>?</span> <
1780: 73 70 61 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22  span class="opt"
1790: 3e 3f 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  >?<i class="arg"
17a0: 3e 73 75 70 70 6f 72 74 65 64 3c 2f 69 3e 3f 3c  >supported</i>?<
17b0: 2f 73 70 61 6e 3e 3c 2f 61 3e 3c 2f 6c 69 3e 0a  /span></a></li>.
17c0: 3c 6c 69 3e 3c 61 20 68 72 65 66 3d 22 23 31 30  <li><a href="#10
17d0: 22 3e 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22  "><b class="cmd"
17e0: 3e 74 6c 73 3a 3a 70 72 6f 74 6f 63 6f 6c 73 3c  >tls::protocols<
17f0: 2f 62 3e 3c 2f 61 3e 3c 2f 6c 69 3e 0a 3c 6c 69  /b></a></li>.<li
1800: 3e 3c 61 20 68 72 65 66 3d 22 23 31 31 22 3e 3c  ><a href="#11"><
1810: 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c  b class="cmd">tl
1820: 73 3a 3a 76 65 72 73 69 6f 6e 3c 2f 62 3e 3c 2f  s::version</b></
1830: 61 3e 3c 2f 6c 69 3e 0a 3c 2f 75 6c 3e 0a 3c 2f  a></li>.</ul>.</
1840: 64 69 76 3e 0a 3c 2f 64 69 76 3e 0a 3c 64 69 76  div>.</div>.<div
1850: 20 69 64 3d 22 73 65 63 74 69 6f 6e 31 22 20 63   id="section1" c
1860: 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73  lass="doctools_s
1870: 65 63 74 69 6f 6e 22 3e 3c 68 32 3e 3c 61 20 6e  ection"><h2><a n
1880: 61 6d 65 3d 22 73 65 63 74 69 6f 6e 31 22 3e 44  ame="section1">D
1890: 65 73 63 72 69 70 74 69 6f 6e 3c 2f 61 3e 3c 2f  escription</a></
18a0: 68 32 3e 0a 3c 70 3e 54 68 69 73 20 65 78 74 65  h2>.<p>This exte
18b0: 6e 73 69 6f 6e 20 70 72 6f 76 69 64 65 73 20 54  nsion provides T
18c0: 43 4c 20 73 63 72 69 70 74 20 61 63 63 65 73 73  CL script access
18d0: 20 74 6f 20 73 65 63 75 72 65 20 73 6f 63 6b 65   to secure socke
18e0: 74 20 63 6f 6d 6d 75 6e 69 63 61 74 69 6f 6e 73  t communications
18f0: 0a 75 73 69 6e 67 20 74 68 65 20 54 72 61 6e 73  .using the Trans
1900: 70 6f 72 74 20 4c 61 79 65 72 20 53 65 63 75 72  port Layer Secur
1910: 69 74 79 20 28 54 4c 53 29 20 70 72 6f 74 6f 63  ity (TLS) protoc
1920: 6f 6c 2e 20 49 74 20 70 72 6f 76 69 64 65 73 20  ol. It provides 
1930: 61 20 67 65 6e 65 72 69 63 0a 62 69 6e 64 69 6e  a generic.bindin
1940: 67 20 74 6f 20 3c 61 20 68 72 65 66 3d 22 68 74  g to <a href="ht
1950: 74 70 73 3a 2f 2f 77 77 77 2e 6f 70 65 6e 73 73  tps://www.openss
1960: 6c 2e 6f 72 67 2f 22 3e 4f 70 65 6e 53 53 4c 3c  l.org/">OpenSSL<
1970: 2f 61 3e 2c 20 75 74 69 6c 69 7a 69 6e 67 20 74  /a>, utilizing t
1980: 68 65 0a 3c 62 20 63 6c 61 73 73 3d 22 73 79 73  he.<b class="sys
1990: 63 6d 64 22 3e 54 63 6c 5f 53 74 61 63 6b 43 68  cmd">Tcl_StackCh
19a0: 61 6e 6e 65 6c 3c 2f 62 3e 20 41 50 49 20 69 6e  annel</b> API in
19b0: 20 54 43 4c 20 38 2e 34 20 61 6e 64 20 68 69 67   TCL 8.4 and hig
19c0: 68 65 72 2e 0a 54 68 65 73 65 20 73 6f 63 6b 65  her..These socke
19d0: 74 73 20 62 65 68 61 76 65 20 65 78 61 63 74 6c  ts behave exactl
19e0: 79 20 74 68 65 20 73 61 6d 65 20 61 73 20 63 68  y the same as ch
19f0: 61 6e 6e 65 6c 73 20 63 72 65 61 74 65 64 20 75  annels created u
1a00: 73 69 6e 67 20 74 68 65 20 62 75 69 6c 74 2d 69  sing the built-i
1a10: 6e 0a 3c 62 20 63 6c 61 73 73 3d 22 73 79 73 63  n.<b class="sysc
1a20: 6d 64 22 3e 73 6f 63 6b 65 74 3c 2f 62 3e 20 63  md">socket</b> c
1a30: 6f 6d 6d 61 6e 64 2c 20 62 75 74 20 70 72 6f 76  ommand, but prov
1a40: 69 64 65 20 61 64 64 69 74 69 6f 6e 61 6c 20 6f  ide additional o
1a50: 70 74 69 6f 6e 73 20 66 6f 72 20 63 6f 6e 74 72  ptions for contr
1a60: 6f 6c 6c 69 6e 67 0a 74 68 65 20 53 53 4c 2f 54  olling.the SSL/T
1a70: 4c 53 20 73 65 73 73 69 6f 6e 2e 3c 2f 70 3e 0a  LS session.</p>.
1a80: 3c 2f 64 69 76 3e 0a 3c 64 69 76 20 69 64 3d 22  </div>.<div id="
1a90: 73 65 63 74 69 6f 6e 32 22 20 63 6c 61 73 73 3d  section2" class=
1aa0: 22 64 6f 63 74 6f 6f 6c 73 5f 73 65 63 74 69 6f  "doctools_sectio
1ab0: 6e 22 3e 3c 68 32 3e 3c 61 20 6e 61 6d 65 3d 22  n"><h2><a name="
1ac0: 73 65 63 74 69 6f 6e 32 22 3e 43 6f 6d 70 61 74  section2">Compat
1ad0: 69 62 69 6c 69 74 79 3c 2f 61 3e 3c 2f 68 32 3e  ibility</a></h2>
1ae0: 0a 3c 70 3e 54 68 69 73 20 65 78 74 65 6e 73 69  .<p>This extensi
1af0: 6f 6e 20 69 73 20 63 6f 6d 70 61 74 69 62 6c 65  on is compatible
1b00: 20 77 69 74 68 20 4f 70 65 6e 53 53 4c 20 31 2e   with OpenSSL 1.
1b10: 31 2e 31 20 6f 72 20 6c 61 74 65 72 2e 20 49 74  1.1 or later. It
1b20: 20 72 65 71 75 69 72 65 73 20 54 63 6c 0a 76 65   requires Tcl.ve
1b30: 72 73 69 6f 6e 20 38 2e 35 20 6f 72 20 6c 61 74  rsion 8.5 or lat
1b40: 65 72 20 61 6e 64 20 77 69 6c 6c 20 77 6f 72 6b  er and will work
1b50: 20 77 69 74 68 20 54 63 6c 20 39 2e 30 2e 3c 2f   with Tcl 9.0.</
1b60: 70 3e 0a 3c 2f 64 69 76 3e 0a 3c 64 69 76 20 69  p>.</div>.<div i
1b70: 64 3d 22 73 65 63 74 69 6f 6e 33 22 20 63 6c 61  d="section3" cla
1b80: 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73 65 63  ss="doctools_sec
1b90: 74 69 6f 6e 22 3e 3c 68 32 3e 3c 61 20 6e 61 6d  tion"><h2><a nam
1ba0: 65 3d 22 73 65 63 74 69 6f 6e 33 22 3e 43 6f 6d  e="section3">Com
1bb0: 6d 61 6e 64 73 3c 2f 61 3e 3c 2f 68 32 3e 0a 3c  mands</a></h2>.<
1bc0: 70 3e 54 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20  p>The following 
1bd0: 61 72 65 20 74 68 65 20 63 6f 6d 6d 61 6e 64 73  are the commands
1be0: 20 70 72 6f 76 69 64 65 64 20 62 79 20 74 68 65   provided by the
1bf0: 20 54 63 4c 54 4c 53 20 70 61 63 6b 61 67 65 2e   TcLTLS package.
1c00: 20 53 65 65 20 74 68 65 0a 3c 73 70 61 6e 20 63   See the.<span c
1c10: 6c 61 73 73 3d 22 73 65 63 74 72 65 66 22 3e 3c  lass="sectref"><
1c20: 61 20 68 72 65 66 3d 22 23 73 65 63 74 69 6f 6e  a href="#section
1c30: 37 22 3e 45 78 61 6d 70 6c 65 73 3c 2f 61 3e 3c  7">Examples</a><
1c40: 2f 73 70 61 6e 3e 20 66 6f 72 20 65 78 61 6d 70  /span> for examp
1c50: 6c 65 20 75 73 61 67 65 20 61 6e 64 20 74 68 65  le usage and the
1c60: 20 26 71 75 6f 74 3b 3c 62 20 63 6c 61 73 73 3d   &quot;<b class=
1c70: 22 66 69 6c 65 22 3e 64 65 6d 6f 73 3c 2f 62 3e  "file">demos</b>
1c80: 26 71 75 6f 74 3b 20 64 69 72 65 63 74 6f 72 79  &quot; directory
1c90: 20 66 6f 72 0a 6d 6f 72 65 20 65 78 61 6d 70 6c   for.more exampl
1ca0: 65 20 75 73 61 67 65 2e 3c 2f 70 3e 0a 3c 64 6c  e usage.</p>.<dl
1cb0: 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73   class="doctools
1cc0: 5f 64 65 66 69 6e 69 74 69 6f 6e 73 22 3e 0a 3c  _definitions">.<
1cd0: 64 74 3e 3c 61 20 6e 61 6d 65 3d 22 31 22 3e 3c  dt><a name="1"><
1ce0: 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c  b class="cmd">tl
1cf0: 73 3a 3a 69 6e 69 74 3c 2f 62 3e 20 3c 73 70 61  s::init</b> <spa
1d00: 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22 3e 3f 3c  n class="opt">?<
1d10: 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 2d 6f  i class="arg">-o
1d20: 70 74 69 6f 6e 3c 2f 69 3e 3f 3c 2f 73 70 61 6e  ption</i>?</span
1d30: 3e 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 6f  > <span class="o
1d40: 70 74 22 3e 3f 3c 69 20 63 6c 61 73 73 3d 22 61  pt">?<i class="a
1d50: 72 67 22 3e 76 61 6c 75 65 3c 2f 69 3e 3f 3c 2f  rg">value</i>?</
1d60: 73 70 61 6e 3e 20 3c 73 70 61 6e 20 63 6c 61 73  span> <span clas
1d70: 73 3d 22 6f 70 74 22 3e 3f 3c 69 20 63 6c 61 73  s="opt">?<i clas
1d80: 73 3d 22 61 72 67 22 3e 2d 6f 70 74 69 6f 6e 20  s="arg">-option 
1d90: 76 61 6c 75 65 20 2e 2e 2e 3c 2f 69 3e 3f 3c 2f  value ...</i>?</
1da0: 73 70 61 6e 3e 3c 2f 61 3e 3c 2f 64 74 3e 0a 3c  span></a></dt>.<
1db0: 64 64 3e 3c 70 3e 4f 70 74 69 6f 6e 61 6c 20 66  dd><p>Optional f
1dc0: 75 6e 63 74 69 6f 6e 20 74 6f 20 73 65 74 20 74  unction to set t
1dd0: 68 65 20 64 65 66 61 75 6c 74 20 6f 70 74 69 6f  he default optio
1de0: 6e 73 20 75 73 65 64 20 62 79 20 3c 62 20 63 6c  ns used by <b cl
1df0: 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 73  ass="cmd">tls::s
1e00: 6f 63 6b 65 74 3c 2f 62 3e 2e 20 49 66 20 79 6f  ocket</b>. If yo
1e10: 75 0a 63 61 6c 6c 20 3c 62 20 63 6c 61 73 73 3d  u.call <b class=
1e20: 22 63 6d 64 22 3e 74 6c 73 3a 3a 69 6d 70 6f 72  "cmd">tls::impor
1e30: 74 3c 2f 62 3e 20 64 69 72 65 63 74 6c 79 2c 20  t</b> directly, 
1e40: 74 68 65 20 76 61 6c 75 65 73 20 73 65 74 20 62  the values set b
1e50: 79 20 74 68 69 73 20 63 6f 6d 6d 61 6e 64 20 68  y this command h
1e60: 61 76 65 20 6e 6f 20 65 66 66 65 63 74 2e 0a 54  ave no effect..T
1e70: 68 69 73 20 63 6f 6d 6d 61 6e 64 20 73 75 70 70  his command supp
1e80: 6f 72 74 73 20 61 6c 6c 20 6f 66 20 74 68 65 20  orts all of the 
1e90: 73 61 6d 65 20 6f 70 74 69 6f 6e 73 20 61 73 20  same options as 
1ea0: 74 68 65 20 3c 62 20 63 6c 61 73 73 3d 22 63 6d  the <b class="cm
1eb0: 64 22 3e 74 6c 73 3a 3a 73 6f 63 6b 65 74 3c 2f  d">tls::socket</
1ec0: 62 3e 20 63 6f 6d 6d 61 6e 64 2c 0a 74 68 6f 75  b> command,.thou
1ed0: 67 68 20 79 6f 75 20 73 68 6f 75 6c 64 20 6c 69  gh you should li
1ee0: 6d 69 74 20 79 6f 75 72 20 6f 70 74 69 6f 6e 73  mit your options
1ef0: 20 74 6f 20 6f 6e 6c 79 20 54 4c 53 20 72 65 6c   to only TLS rel
1f00: 61 74 65 64 20 6f 6e 65 73 2e 3c 2f 70 3e 3c 2f  ated ones.</p></
1f10: 64 64 3e 0a 3c 64 74 3e 3c 61 20 6e 61 6d 65 3d  dd>.<dt><a name=
1f20: 22 32 22 3e 3c 62 20 63 6c 61 73 73 3d 22 63 6d  "2"><b class="cm
1f30: 64 22 3e 74 6c 73 3a 3a 73 6f 63 6b 65 74 3c 2f  d">tls::socket</
1f40: 62 3e 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22  b> <span class="
1f50: 6f 70 74 22 3e 3f 3c 69 20 63 6c 61 73 73 3d 22  opt">?<i class="
1f60: 61 72 67 22 3e 2d 6f 70 74 69 6f 6e 3c 2f 69 3e  arg">-option</i>
1f70: 3f 3c 2f 73 70 61 6e 3e 20 3c 73 70 61 6e 20 63  ?</span> <span c
1f80: 6c 61 73 73 3d 22 6f 70 74 22 3e 3f 3c 69 20 63  lass="opt">?<i c
1f90: 6c 61 73 73 3d 22 61 72 67 22 3e 76 61 6c 75 65  lass="arg">value
1fa0: 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e 20 3c 73 70  </i>?</span> <sp
1fb0: 61 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22 3e 3f  an class="opt">?
1fc0: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 2d  <i class="arg">-
1fd0: 6f 70 74 69 6f 6e 20 76 61 6c 75 65 20 2e 2e 2e  option value ...
1fe0: 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e 20 3c 69 20  </i>?</span> <i 
1ff0: 63 6c 61 73 73 3d 22 61 72 67 22 3e 68 6f 73 74  class="arg">host
2000: 3c 2f 69 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61  </i> <i class="a
2010: 72 67 22 3e 70 6f 72 74 3c 2f 69 3e 3c 2f 61 3e  rg">port</i></a>
2020: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 69  </dt>.<dd><p>Thi
2030: 73 20 69 73 20 61 20 68 65 6c 70 65 72 20 66 75  s is a helper fu
2040: 6e 63 74 69 6f 6e 20 74 68 61 74 20 75 74 69 6c  nction that util
2050: 69 7a 65 73 20 74 68 65 20 75 6e 64 65 72 6c 79  izes the underly
2060: 69 6e 67 20 63 6f 6d 6d 61 6e 64 73 20 3c 62 20  ing commands <b 
2070: 63 6c 61 73 73 3d 22 73 79 73 63 6d 64 22 3e 73  class="syscmd">s
2080: 6f 63 6b 65 74 3c 2f 62 3e 0a 61 6e 64 20 3c 62  ocket</b>.and <b
2090: 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73   class="cmd">tls
20a0: 3a 3a 69 6d 70 6f 72 74 3c 2f 62 3e 20 74 6f 20  ::import</b> to 
20b0: 63 72 65 61 74 65 20 74 68 65 20 63 6f 6e 6e 65  create the conne
20c0: 63 74 69 6f 6e 2e 20 49 74 20 62 65 68 61 76 65  ction. It behave
20d0: 73 20 74 68 65 20 73 61 6d 65 20 61 73 20 74 68  s the same as th
20e0: 65 0a 6e 61 74 69 76 65 20 54 43 4c 20 3c 62 20  e.native TCL <b 
20f0: 63 6c 61 73 73 3d 22 73 79 73 63 6d 64 22 3e 73  class="syscmd">s
2100: 6f 63 6b 65 74 3c 2f 62 3e 20 63 6f 6d 6d 61 6e  ocket</b> comman
2110: 64 2c 20 62 75 74 20 61 6c 73 6f 20 73 75 70 70  d, but also supp
2120: 6f 72 74 73 20 74 68 65 20 3c 62 20 63 6c 61 73  orts the <b clas
2130: 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 69 6d 70 6f  s="cmd">tls:impo
2140: 72 74 3c 2f 62 3e 0a 63 6f 6d 6d 61 6e 64 20 6f  rt</b>.command o
2150: 70 74 69 6f 6e 73 20 77 69 74 68 20 6f 6e 65 20  ptions with one 
2160: 61 64 64 69 74 69 6f 6e 61 6c 20 6f 70 74 69 6f  additional optio
2170: 6e 2e 20 49 74 20 72 65 74 75 72 6e 73 20 74 68  n. It returns th
2180: 65 20 63 68 61 6e 6e 65 6c 20 68 61 6e 64 6c 65  e channel handle
2190: 20 69 64 0a 66 6f 72 20 74 68 65 20 6e 65 77 20   id.for the new 
21a0: 73 6f 63 6b 65 74 2e 3c 2f 70 3e 0a 3c 64 6c 20  socket.</p>.<dl 
21b0: 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f  class="doctools_
21c0: 6f 70 74 69 6f 6e 73 22 3e 0a 3c 64 74 3e 3c 62  options">.<dt><b
21d0: 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e   class="option">
21e0: 2d 61 75 74 6f 73 65 72 76 65 72 6e 61 6d 65 3c  -autoservername<
21f0: 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72  /b> <i class="ar
2200: 67 22 3e 62 6f 6f 6c 3c 2f 69 3e 3c 2f 64 74 3e  g">bool</i></dt>
2210: 0a 3c 64 64 3e 3c 70 3e 49 66 20 3c 62 20 63 6c  .<dd><p>If <b cl
2220: 61 73 73 3d 22 63 6f 6e 73 74 22 3e 74 72 75 65  ass="const">true
2230: 3c 2f 62 3e 2c 20 61 75 74 6f 6d 61 74 69 63 61  </b>, automatica
2240: 6c 6c 79 20 73 65 74 20 74 68 65 20 3c 62 20 63  lly set the <b c
2250: 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 73  lass="option">-s
2260: 65 72 76 65 72 6e 61 6d 65 3c 2f 62 3e 20 61 72  ervername</b> ar
2270: 67 75 6d 65 6e 74 20 74 6f 20 74 68 65 0a 3c 65  gument to the.<e
2280: 6d 3e 68 6f 73 74 3c 2f 65 6d 3e 20 61 72 67 75  m>host</em> argu
2290: 6d 65 6e 74 2e 20 50 72 69 6f 72 20 74 6f 20 54  ment. Prior to T
22a0: 63 6c 54 4c 53 20 32 2e 30 2c 20 74 68 65 20 64  clTLS 2.0, the d
22b0: 65 66 61 75 6c 74 20 69 73 20 3c 62 20 63 6c 61  efault is <b cla
22c0: 73 73 3d 22 63 6f 6e 73 74 22 3e 66 61 6c 73 65  ss="const">false
22d0: 3c 2f 62 3e 2e 0a 53 74 61 72 74 69 6e 67 20 69  </b>..Starting i
22e0: 6e 20 54 63 6c 54 4c 53 20 32 2e 30 2c 20 74 68  n TclTLS 2.0, th
22f0: 65 20 64 65 66 61 75 6c 74 20 69 73 20 3c 62 20  e default is <b 
2300: 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 74 72  class="const">tr
2310: 75 65 3c 2f 62 3e 20 75 6e 6c 65 73 73 20 3c 62  ue</b> unless <b
2320: 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e   class="option">
2330: 2d 73 65 72 76 65 72 6e 61 6d 65 3c 2f 62 3e 0a  -servername</b>.
2340: 69 73 20 61 6c 73 6f 20 73 70 65 63 69 66 69 65  is also specifie
2350: 64 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 2f 64 6c  d.</p></dd>.</dl
2360: 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 61 20 6e 61  ></dd>.<dt><a na
2370: 6d 65 3d 22 33 22 3e 3c 62 20 63 6c 61 73 73 3d  me="3"><b class=
2380: 22 63 6d 64 22 3e 74 6c 73 3a 3a 73 6f 63 6b 65  "cmd">tls::socke
2390: 74 3c 2f 62 3e 20 3c 62 20 63 6c 61 73 73 3d 22  t</b> <b class="
23a0: 6f 70 74 69 6f 6e 22 3e 2d 73 65 72 76 65 72 3c  option">-server<
23b0: 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72  /b> <i class="ar
23c0: 67 22 3e 63 6f 6d 6d 61 6e 64 3c 2f 69 3e 20 3c  g">command</i> <
23d0: 73 70 61 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22  span class="opt"
23e0: 3e 3f 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  >?<i class="arg"
23f0: 3e 2d 6f 70 74 69 6f 6e 3c 2f 69 3e 3f 3c 2f 73  >-option</i>?</s
2400: 70 61 6e 3e 20 3c 73 70 61 6e 20 63 6c 61 73 73  pan> <span class
2410: 3d 22 6f 70 74 22 3e 3f 3c 69 20 63 6c 61 73 73  ="opt">?<i class
2420: 3d 22 61 72 67 22 3e 76 61 6c 75 65 3c 2f 69 3e  ="arg">value</i>
2430: 3f 3c 2f 73 70 61 6e 3e 20 3c 73 70 61 6e 20 63  ?</span> <span c
2440: 6c 61 73 73 3d 22 6f 70 74 22 3e 3f 3c 69 20 63  lass="opt">?<i c
2450: 6c 61 73 73 3d 22 61 72 67 22 3e 2d 6f 70 74 69  lass="arg">-opti
2460: 6f 6e 20 76 61 6c 75 65 20 2e 2e 2e 3c 2f 69 3e  on value ...</i>
2470: 3f 3c 2f 73 70 61 6e 3e 20 3c 69 20 63 6c 61 73  ?</span> <i clas
2480: 73 3d 22 61 72 67 22 3e 70 6f 72 74 3c 2f 69 3e  s="arg">port</i>
2490: 3c 2f 61 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </a></dt>.<dd><p
24a0: 3e 53 61 6d 65 20 61 73 20 70 72 65 76 69 6f 75  >Same as previou
24b0: 73 2c 20 62 75 74 20 69 6e 73 74 65 61 64 20 63  s, but instead c
24c0: 72 65 61 74 65 73 20 61 20 73 65 72 76 65 72 20  reates a server 
24d0: 73 6f 63 6b 65 74 20 66 6f 72 20 63 6c 69 65 6e  socket for clien
24e0: 74 73 20 74 6f 20 63 6f 6e 6e 65 63 74 20 74 6f  ts to connect to
24f0: 0a 6a 75 73 74 20 6c 69 6b 65 20 74 68 65 20 54  .just like the T
2500: 63 6c 20 3c 62 20 63 6c 61 73 73 3d 22 73 79 73  cl <b class="sys
2510: 63 6d 64 22 3e 73 6f 63 6b 65 74 20 2d 73 65 72  cmd">socket -ser
2520: 76 65 72 3c 2f 62 3e 20 63 6f 6d 6d 61 6e 64 2e  ver</b> command.
2530: 20 49 74 20 72 65 74 75 72 6e 73 20 74 68 65 20   It returns the 
2540: 63 68 61 6e 6e 65 6c 0a 68 61 6e 64 6c 65 20 69  channel.handle i
2550: 64 20 66 6f 72 20 74 68 65 20 6e 65 77 20 73 6f  d for the new so
2560: 63 6b 65 74 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c  cket.</p></dd>.<
2570: 64 74 3e 3c 61 20 6e 61 6d 65 3d 22 34 22 3e 3c  dt><a name="4"><
2580: 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c  b class="cmd">tl
2590: 73 3a 3a 69 6d 70 6f 72 74 3c 2f 62 3e 20 3c 69  s::import</b> <i
25a0: 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 63 68 61   class="arg">cha
25b0: 6e 6e 65 6c 3c 2f 69 3e 20 3c 73 70 61 6e 20 63  nnel</i> <span c
25c0: 6c 61 73 73 3d 22 6f 70 74 22 3e 3f 3c 69 20 63  lass="opt">?<i c
25d0: 6c 61 73 73 3d 22 61 72 67 22 3e 2d 6f 70 74 69  lass="arg">-opti
25e0: 6f 6e 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e 20 3c  on</i>?</span> <
25f0: 73 70 61 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22  span class="opt"
2600: 3e 3f 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  >?<i class="arg"
2610: 3e 76 61 6c 75 65 3c 2f 69 3e 3f 3c 2f 73 70 61  >value</i>?</spa
2620: 6e 3e 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22  n> <span class="
2630: 6f 70 74 22 3e 3f 3c 69 20 63 6c 61 73 73 3d 22  opt">?<i class="
2640: 61 72 67 22 3e 2d 6f 70 74 69 6f 6e 20 76 61 6c  arg">-option val
2650: 75 65 20 2e 2e 2e 3c 2f 69 3e 3f 3c 2f 73 70 61  ue ...</i>?</spa
2660: 6e 3e 3c 2f 61 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  n></a></dt>.<dd>
2670: 3c 70 3e 53 74 61 72 74 20 54 4c 53 20 65 6e 63  <p>Start TLS enc
2680: 72 79 70 74 69 6f 6e 20 6f 6e 20 54 43 4c 20 63  ryption on TCL c
2690: 68 61 6e 6e 65 6c 20 3c 69 20 63 6c 61 73 73 3d  hannel <i class=
26a0: 22 61 72 67 22 3e 63 68 61 6e 6e 65 6c 3c 2f 69  "arg">channel</i
26b0: 3e 20 76 69 61 20 61 20 73 74 61 63 6b 65 64 20  > via a stacked 
26c0: 63 68 61 6e 6e 65 6c 2e 20 49 74 0a 6e 65 65 64  channel. It.need
26d0: 20 6e 6f 74 20 62 65 20 61 20 73 6f 63 6b 65 74   not be a socket
26e0: 2c 20 62 75 74 20 6d 75 73 74 20 70 72 6f 76 69  , but must provi
26f0: 64 65 20 62 69 2d 64 69 72 65 63 74 69 6f 6e 61  de bi-directiona
2700: 6c 20 66 6c 6f 77 2e 20 41 6c 73 6f 20 73 65 74  l flow. Also set
2710: 73 20 73 65 73 73 69 6f 6e 0a 70 61 72 61 6d 65  s session.parame
2720: 74 65 72 73 20 66 6f 72 20 53 53 4c 20 68 61 6e  ters for SSL han
2730: 64 73 68 61 6b 65 2e 20 56 61 6c 69 64 20 6f 70  dshake. Valid op
2740: 74 69 6f 6e 73 20 61 72 65 3a 3c 2f 70 3e 0a 3c  tions are:</p>.<
2750: 64 6c 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f  dl class="doctoo
2760: 6c 73 5f 6f 70 74 69 6f 6e 73 22 3e 0a 3c 64 74  ls_options">.<dt
2770: 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f  ><b class="optio
2780: 6e 22 3e 2d 61 6c 70 6e 3c 2f 62 3e 20 3c 69 20  n">-alpn</b> <i 
2790: 63 6c 61 73 73 3d 22 61 72 67 22 3e 6c 69 73 74  class="arg">list
27a0: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
27b0: 3e 4c 69 73 74 20 6f 66 20 70 72 6f 74 6f 63 6f  >List of protoco
27c0: 6c 73 20 74 6f 20 6f 66 66 65 72 20 64 75 72 69  ls to offer duri
27d0: 6e 67 20 41 70 70 6c 69 63 61 74 69 6f 6e 2d 4c  ng Application-L
27e0: 61 79 65 72 20 50 72 6f 74 6f 63 6f 6c 20 4e 65  ayer Protocol Ne
27f0: 67 6f 74 69 61 74 69 6f 6e 0a 28 41 4c 50 4e 29  gotiation.(ALPN)
2800: 2e 20 46 6f 72 20 65 78 61 6d 70 6c 65 3a 20 3c  . For example: <
2810: 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e  b class="const">
2820: 68 32 3c 2f 62 3e 20 61 6e 64 20 3c 62 20 63 6c  h2</b> and <b cl
2830: 61 73 73 3d 22 63 6f 6e 73 74 22 3e 68 74 74 70  ass="const">http
2840: 2f 31 2e 31 3c 2f 62 3e 2c 20 62 75 74 20 6e 6f  /1.1</b>, but no
2850: 74 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73  t <b class="cons
2860: 74 22 3e 68 33 3c 2f 62 3e 20 6f 72 0a 3c 62 20  t">h3</b> or.<b 
2870: 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 71 75  class="const">qu
2880: 69 63 3c 2f 62 3e 2e 20 54 68 69 73 20 6f 70 74  ic</b>. This opt
2890: 69 6f 6e 20 69 73 20 6e 65 77 20 66 6f 72 20 54  ion is new for T
28a0: 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f  clTLS 1.8.</p></
28b0: 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73  dd>.<dt><b class
28c0: 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 64 69 72  ="option">-cadir
28d0: 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61  </b> <i class="a
28e0: 72 67 22 3e 64 69 72 65 63 74 6f 72 79 3c 2f 69  rg">directory</i
28f0: 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 53 70  ></dt>.<dd><p>Sp
2900: 65 63 69 66 69 65 73 20 74 68 65 20 64 69 72 65  ecifies the dire
2910: 63 74 6f 72 79 20 77 68 65 72 65 20 74 68 65 20  ctory where the 
2920: 43 65 72 74 69 66 69 63 61 74 65 20 41 75 74 68  Certificate Auth
2930: 6f 72 69 74 79 20 28 43 41 29 20 63 65 72 74 69  ority (CA) certi
2940: 66 69 63 61 74 65 73 20 61 72 65 0a 73 74 6f 72  ficates are.stor
2950: 65 64 2e 20 54 68 65 20 64 65 66 61 75 6c 74 20  ed. The default 
2960: 69 73 20 70 6c 61 74 66 6f 72 6d 20 73 70 65 63  is platform spec
2970: 69 66 69 63 20 61 6e 64 20 63 61 6e 20 62 65 20  ific and can be 
2980: 73 65 74 20 61 74 20 63 6f 6d 70 69 6c 65 20 74  set at compile t
2990: 69 6d 65 2e 20 54 68 65 0a 64 65 66 61 75 6c 74  ime. The.default
29a0: 20 6c 6f 63 61 74 69 6f 6e 20 63 61 6e 20 62 65   location can be
29b0: 20 6f 76 65 72 72 69 64 64 65 6e 20 62 79 20 74   overridden by t
29c0: 68 65 20 3c 62 20 63 6c 61 73 73 3d 22 76 61 72  he <b class="var
29d0: 69 61 62 6c 65 22 3e 53 53 4c 5f 43 45 52 54 5f  iable">SSL_CERT_
29e0: 44 49 52 3c 2f 62 3e 20 65 6e 76 69 72 6f 6e 6d  DIR</b> environm
29f0: 65 6e 74 0a 76 61 72 69 61 62 6c 65 2e 20 53 65  ent.variable. Se
2a00: 65 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 73  e <span class="s
2a10: 65 63 74 72 65 66 22 3e 3c 61 20 68 72 65 66 3d  ectref"><a href=
2a20: 22 23 73 65 63 74 69 6f 6e 34 22 3e 43 65 72 74  "#section4">Cert
2a30: 69 66 69 63 61 74 65 20 56 61 6c 69 64 61 74 69  ificate Validati
2a40: 6f 6e 3c 2f 61 3e 3c 2f 73 70 61 6e 3e 20 66 6f  on</a></span> fo
2a50: 72 20 6d 6f 72 65 20 64 65 74 61 69 6c 73 2e 3c  r more details.<
2a60: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
2a70: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
2a80: 63 61 66 69 6c 65 3c 2f 62 3e 20 3c 69 20 63 6c  cafile</b> <i cl
2a90: 61 73 73 3d 22 61 72 67 22 3e 66 69 6c 65 6e 61  ass="arg">filena
2aa0: 6d 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  me</i></dt>.<dd>
2ab0: 3c 70 3e 53 70 65 63 69 66 69 65 73 20 74 68 65  <p>Specifies the
2ac0: 20 66 69 6c 65 20 77 69 74 68 20 74 68 65 20 43   file with the C
2ad0: 65 72 74 69 66 69 63 61 74 65 20 41 75 74 68 6f  ertificate Autho
2ae0: 72 69 74 79 20 28 43 41 29 20 63 65 72 74 69 66  rity (CA) certif
2af0: 69 63 61 74 65 73 20 74 6f 20 75 73 65 20 69 6e  icates to use in
2b00: 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74  .<b class="const
2b10: 22 3e 50 45 4d 3c 2f 62 3e 20 66 69 6c 65 20 66  ">PEM</b> file f
2b20: 6f 72 6d 61 74 2e 20 54 68 65 20 64 65 66 61 75  ormat. The defau
2b30: 6c 74 20 69 73 20 26 71 75 6f 74 3b 3c 62 20 63  lt is &quot;<b c
2b40: 6c 61 73 73 3d 22 66 69 6c 65 22 3e 63 65 72 74  lass="file">cert
2b50: 2e 70 65 6d 3c 2f 62 3e 26 71 75 6f 74 3b 2c 20  .pem</b>&quot;, 
2b60: 69 6e 20 74 68 65 20 4f 70 65 6e 53 53 4c 0a 64  in the OpenSSL.d
2b70: 69 72 65 63 74 6f 72 79 2e 20 54 68 65 20 64 65  irectory. The de
2b80: 66 61 75 6c 74 20 66 69 6c 65 20 63 61 6e 20 62  fault file can b
2b90: 65 20 6f 76 65 72 72 69 64 64 65 6e 20 62 79 20  e overridden by 
2ba0: 74 68 65 20 3c 62 20 63 6c 61 73 73 3d 22 76 61  the <b class="va
2bb0: 72 69 61 62 6c 65 22 3e 53 53 4c 5f 43 45 52 54  riable">SSL_CERT
2bc0: 5f 46 49 4c 45 3c 2f 62 3e 20 65 6e 76 69 72 6f  _FILE</b> enviro
2bd0: 6e 6d 65 6e 74 0a 76 61 72 69 61 62 6c 65 2e 20  nment.variable. 
2be0: 53 65 65 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d  See <span class=
2bf0: 22 73 65 63 74 72 65 66 22 3e 3c 61 20 68 72 65  "sectref"><a hre
2c00: 66 3d 22 23 73 65 63 74 69 6f 6e 34 22 3e 43 65  f="#section4">Ce
2c10: 72 74 69 66 69 63 61 74 65 20 56 61 6c 69 64 61  rtificate Valida
2c20: 74 69 6f 6e 3c 2f 61 3e 3c 2f 73 70 61 6e 3e 20  tion</a></span> 
2c30: 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 69 6c 73  for more details
2c40: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
2c50: 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22  b class="option"
2c60: 3e 2d 63 61 73 74 6f 72 65 3c 2f 62 3e 20 3c 69  >-castore</b> <i
2c70: 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 55 52 49   class="arg">URI
2c80: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
2c90: 3e 53 70 65 63 69 66 69 65 73 20 74 68 65 20 55  >Specifies the U
2ca0: 6e 69 66 6f 72 6d 20 52 65 73 6f 75 72 63 65 20  niform Resource 
2cb0: 49 64 65 6e 74 69 66 69 65 72 20 28 55 52 49 29  Identifier (URI)
2cc0: 20 66 6f 72 20 74 68 65 20 43 65 72 74 69 66 69   for the Certifi
2cd0: 63 61 74 65 20 41 75 74 68 6f 72 69 74 79 0a 28  cate Authority.(
2ce0: 43 41 29 20 73 74 6f 72 65 2c 20 77 68 69 63 68  CA) store, which
2cf0: 20 6d 61 79 20 62 65 20 61 20 73 69 6e 67 6c 65   may be a single
2d00: 20 63 6f 6e 74 61 69 6e 65 72 20 6f 72 20 61 20   container or a 
2d10: 63 61 74 61 6c 6f 67 20 6f 66 20 63 6f 6e 74 61  catalog of conta
2d20: 69 6e 65 72 73 2e 0a 53 74 61 72 74 69 6e 67 20  iners..Starting 
2d30: 77 69 74 68 20 4f 70 65 6e 53 53 4c 20 33 2e 32  with OpenSSL 3.2
2d40: 20 6f 6e 20 4d 53 20 57 69 6e 64 6f 77 73 2c 20   on MS Windows, 
2d50: 73 65 74 20 74 6f 20 26 71 75 6f 74 3b 3c 62 20  set to &quot;<b 
2d60: 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 6f 72  class="const">or
2d70: 67 2e 6f 70 65 6e 73 73 6c 2e 77 69 6e 73 74 6f  g.openssl.winsto
2d80: 72 65 3a 2f 2f 3c 2f 62 3e 26 71 75 6f 74 3b 0a  re://</b>&quot;.
2d90: 74 6f 20 75 73 65 20 74 68 65 20 62 75 69 6c 74  to use the built
2da0: 2d 69 6e 20 4d 53 20 57 69 6e 64 6f 77 73 20 43  -in MS Windows C
2db0: 65 72 74 69 66 69 63 61 74 65 20 53 74 6f 72 65  ertificate Store
2dc0: 2e 0a 53 65 65 20 3c 73 70 61 6e 20 63 6c 61 73  ..See <span clas
2dd0: 73 3d 22 73 65 63 74 72 65 66 22 3e 3c 61 20 68  s="sectref"><a h
2de0: 72 65 66 3d 22 23 73 65 63 74 69 6f 6e 34 22 3e  ref="#section4">
2df0: 43 65 72 74 69 66 69 63 61 74 65 20 56 61 6c 69  Certificate Vali
2e00: 64 61 74 69 6f 6e 3c 2f 61 3e 3c 2f 73 70 61 6e  dation</a></span
2e10: 3e 20 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 69  > for more detai
2e20: 6c 73 2e 0a 54 68 69 73 20 6f 70 74 69 6f 6e 20  ls..This option 
2e30: 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c  is new for TclTL
2e40: 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a  S 1.8.</p></dd>.
2e50: 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70  <dt><b class="op
2e60: 74 69 6f 6e 22 3e 2d 63 65 72 74 66 69 6c 65 3c  tion">-certfile<
2e70: 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72  /b> <i class="ar
2e80: 67 22 3e 66 69 6c 65 6e 61 6d 65 3c 2f 69 3e 3c  g">filename</i><
2e90: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 53 70 65 63  /dt>.<dd><p>Spec
2ea0: 69 66 69 65 73 20 74 68 65 20 6e 61 6d 65 20 6f  ifies the name o
2eb0: 66 20 74 68 65 20 66 69 6c 65 20 77 69 74 68 20  f the file with 
2ec0: 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65 20  the certificate 
2ed0: 74 6f 20 75 73 65 20 69 6e 20 50 45 4d 20 66 6f  to use in PEM fo
2ee0: 72 6d 61 74 0a 61 73 20 74 68 65 20 6c 6f 63 61  rmat.as the loca
2ef0: 6c 20 28 63 6c 69 65 6e 74 20 6f 72 20 73 65 72  l (client or ser
2f00: 76 65 72 29 20 63 65 72 74 69 66 69 63 61 74 65  ver) certificate
2f10: 2e 20 49 74 20 61 6c 73 6f 20 63 6f 6e 74 61 69  . It also contai
2f20: 6e 73 20 74 68 65 20 70 75 62 6c 69 63 20 6b 65  ns the public ke
2f30: 79 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  y.</p></dd>.<dt>
2f40: 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e  <b class="option
2f50: 22 3e 2d 63 65 72 74 3c 2f 62 3e 20 3c 69 20 63  ">-cert</b> <i c
2f60: 6c 61 73 73 3d 22 61 72 67 22 3e 73 74 72 69 6e  lass="arg">strin
2f70: 67 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c  g</i></dt>.<dd><
2f80: 70 3e 53 70 65 63 69 66 69 65 73 20 74 68 65 20  p>Specifies the 
2f90: 63 65 72 74 69 66 69 63 61 74 65 20 74 6f 20 75  certificate to u
2fa0: 73 65 20 61 73 20 61 20 44 45 52 20 65 6e 63 6f  se as a DER enco
2fb0: 64 65 64 20 73 74 72 69 6e 67 20 28 58 2e 35 30  ded string (X.50
2fc0: 39 20 44 45 52 29 2e 3c 2f 70 3e 3c 2f 64 64 3e  9 DER).</p></dd>
2fd0: 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f  .<dt><b class="o
2fe0: 70 74 69 6f 6e 22 3e 2d 63 69 70 68 65 72 3c 2f  ption">-cipher</
2ff0: 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67  b> <i class="arg
3000: 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 3c 2f 64 74  ">string</i></dt
3010: 3e 0a 3c 64 64 3e 3c 70 3e 53 70 65 63 69 66 69  >.<dd><p>Specifi
3020: 65 73 20 74 68 65 20 6c 69 73 74 20 6f 66 20 63  es the list of c
3030: 69 70 68 65 72 73 20 74 6f 20 75 73 65 20 66 6f  iphers to use fo
3040: 72 20 54 4c 53 20 31 2e 32 20 61 6e 64 20 65 61  r TLS 1.2 and ea
3050: 72 6c 69 65 72 20 63 6f 6e 6e 65 63 74 69 6f 6e  rlier connection
3060: 73 2e 0a 53 74 72 69 6e 67 20 69 73 20 61 20 63  s..String is a c
3070: 6f 6c 6f 6e 20 26 71 75 6f 74 3b 3c 62 20 63 6c  olon &quot;<b cl
3080: 61 73 73 3d 22 63 6f 6e 73 74 22 3e 3a 3c 2f 62  ass="const">:</b
3090: 3e 26 71 75 6f 74 3b 20 73 65 70 61 72 61 74 65  >&quot; separate
30a0: 64 20 6c 69 73 74 20 6f 66 20 63 69 70 68 65 72  d list of cipher
30b0: 73 2e 0a 43 69 70 68 65 72 73 20 63 61 6e 20 62  s..Ciphers can b
30c0: 65 20 63 6f 6d 62 69 6e 65 64 20 75 73 69 6e 67  e combined using
30d0: 20 74 68 65 20 26 71 75 6f 74 3b 3c 62 20 63 6c   the &quot;<b cl
30e0: 61 73 73 3d 22 63 6f 6e 73 74 22 3e 2b 3c 2f 62  ass="const">+</b
30f0: 3e 26 71 75 6f 74 3b 20 63 68 61 72 61 63 74 65  >&quot; characte
3100: 72 2e 0a 50 72 65 66 69 78 65 73 20 63 61 6e 20  r..Prefixes can 
3110: 62 65 20 75 73 65 64 20 74 6f 20 70 65 72 6d 61  be used to perma
3120: 6e 65 6e 74 6c 79 20 72 65 6d 6f 76 65 20 26 71  nently remove &q
3130: 75 6f 74 3b 3c 62 20 63 6c 61 73 73 3d 22 63 6f  uot;<b class="co
3140: 6e 73 74 22 3e 21 3c 2f 62 3e 26 71 75 6f 74 3b  nst">!</b>&quot;
3150: 2c 20 64 65 6c 65 74 65 20 26 71 75 6f 74 3b 3c  , delete &quot;<
3160: 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e  b class="const">
3170: 2d 3c 2f 62 3e 26 71 75 6f 74 3b 2c 20 6f 72 0a  -</b>&quot;, or.
3180: 6d 6f 76 65 20 74 6f 20 74 68 65 20 65 6e 64 20  move to the end 
3190: 26 71 75 6f 74 3b 3c 62 20 63 6c 61 73 73 3d 22  &quot;<b class="
31a0: 63 6f 6e 73 74 22 3e 2b 3c 2f 62 3e 26 71 75 6f  const">+</b>&quo
31b0: 74 3b 20 61 20 73 70 65 63 69 66 69 65 64 20 63  t; a specified c
31c0: 69 70 68 65 72 2e 0a 4b 65 79 77 6f 72 64 73 20  ipher..Keywords 
31d0: 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22  <b class="const"
31e0: 3e 40 53 54 52 45 4e 47 54 48 3c 2f 62 3e 20 28  >@STRENGTH</b> (
31f0: 73 6f 72 74 20 62 79 20 61 6c 67 6f 72 69 74 68  sort by algorith
3200: 6d 20 6b 65 79 20 6c 65 6e 67 74 68 29 2c 0a 3c  m key length),.<
3210: 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e  b class="const">
3220: 40 53 45 43 4c 45 56 45 4c 3d 3c 2f 62 3e 3c 65  @SECLEVEL=</b><e
3230: 6d 3e 6e 3c 2f 65 6d 3e 20 28 73 65 74 20 73 65  m>n</em> (set se
3240: 63 75 72 69 74 79 20 6c 65 76 65 6c 20 74 6f 20  curity level to 
3250: 6e 29 2c 20 61 6e 64 0a 3c 62 20 63 6c 61 73 73  n), and.<b class
3260: 3d 22 63 6f 6e 73 74 22 3e 44 45 46 41 55 4c 54  ="const">DEFAULT
3270: 3c 2f 62 3e 20 28 75 73 65 20 64 65 66 61 75 6c  </b> (use defaul
3280: 74 20 63 69 70 68 65 72 20 6c 69 73 74 2c 20 61  t cipher list, a
3290: 74 20 73 74 61 72 74 20 6f 6e 6c 79 29 20 63 61  t start only) ca
32a0: 6e 20 61 6c 73 6f 20 62 65 20 73 70 65 63 69 66  n also be specif
32b0: 69 65 64 2e 0a 53 65 65 20 74 68 65 20 3c 61 20  ied..See the <a 
32c0: 68 72 65 66 3d 22 68 74 74 70 73 3a 2f 2f 64 6f  href="https://do
32d0: 63 73 2e 6f 70 65 6e 73 73 6c 2e 6f 72 67 2f 6d  cs.openssl.org/m
32e0: 61 73 74 65 72 2f 6d 61 6e 31 2f 6f 70 65 6e 73  aster/man1/opens
32f0: 73 6c 2d 63 69 70 68 65 72 73 2f 23 6f 70 74 69  sl-ciphers/#opti
3300: 6f 6e 73 22 3e 4f 70 65 6e 53 53 4c 3c 2f 61 3e  ons">OpenSSL</a>
3310: 0a 64 6f 63 75 6d 65 6e 74 61 74 69 6f 6e 20 66  .documentation f
3320: 6f 72 20 74 68 65 20 66 75 6c 6c 20 6c 69 73 74  or the full list
3330: 20 6f 66 20 76 61 6c 69 64 20 76 61 6c 75 65 73   of valid values
3340: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
3350: 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22  b class="option"
3360: 3e 2d 63 69 70 68 65 72 73 75 69 74 65 73 3c 2f  >-ciphersuites</
3370: 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67  b> <i class="arg
3380: 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 3c 2f 64 74  ">string</i></dt
3390: 3e 0a 3c 64 64 3e 3c 70 3e 53 70 65 63 69 66 69  >.<dd><p>Specifi
33a0: 65 73 20 74 68 65 20 6c 69 73 74 20 6f 66 20 63  es the list of c
33b0: 69 70 68 65 72 20 73 75 69 74 65 73 20 74 6f 20  ipher suites to 
33c0: 75 73 65 20 66 6f 72 20 54 4c 53 20 31 2e 33 20  use for TLS 1.3 
33d0: 61 73 20 61 20 63 6f 6c 6f 6e 0a 26 71 75 6f 74  as a colon.&quot
33e0: 3b 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74  ;<b class="const
33f0: 22 3e 3a 3c 2f 62 3e 26 71 75 6f 74 3b 20 73 65  ">:</b>&quot; se
3400: 70 61 72 61 74 65 64 20 6c 69 73 74 20 6f 66 20  parated list of 
3410: 63 69 70 68 65 72 20 73 75 69 74 65 20 6e 61 6d  cipher suite nam
3420: 65 73 2e 20 53 65 65 20 74 68 65 0a 3c 61 20 68  es. See the.<a h
3430: 72 65 66 3d 22 68 74 74 70 73 3a 2f 2f 64 6f 63  ref="https://doc
3440: 73 2e 6f 70 65 6e 73 73 6c 2e 6f 72 67 2f 6d 61  s.openssl.org/ma
3450: 73 74 65 72 2f 6d 61 6e 31 2f 6f 70 65 6e 73 73  ster/man1/openss
3460: 6c 2d 63 69 70 68 65 72 73 2f 23 6f 70 74 69 6f  l-ciphers/#optio
3470: 6e 73 22 3e 4f 70 65 6e 53 53 4c 3c 2f 61 3e 0a  ns">OpenSSL</a>.
3480: 64 6f 63 75 6d 65 6e 74 61 74 69 6f 6e 20 66 6f  documentation fo
3490: 72 20 74 68 65 20 66 75 6c 6c 20 6c 69 73 74 20  r the full list 
34a0: 6f 66 20 76 61 6c 69 64 20 76 61 6c 75 65 73 2e  of valid values.
34b0: 0a 54 68 69 73 20 6f 70 74 69 6f 6e 20 69 73 20  .This option is 
34c0: 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c 53 20 31  new for TclTLS 1
34d0: 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  .8.</p></dd>.<dt
34e0: 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f  ><b class="optio
34f0: 6e 22 3e 2d 63 6f 6d 6d 61 6e 64 3c 2f 62 3e 20  n">-command</b> 
3500: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 63  <i class="arg">c
3510: 61 6c 6c 62 61 63 6b 3c 2f 69 3e 3c 2f 64 74 3e  allback</i></dt>
3520: 0a 3c 64 64 3e 3c 70 3e 53 70 65 63 69 66 69 65  .<dd><p>Specifie
3530: 73 20 74 68 65 20 63 61 6c 6c 62 61 63 6b 20 63  s the callback c
3540: 6f 6d 6d 61 6e 64 20 74 6f 20 62 65 20 69 6e 76  ommand to be inv
3550: 6f 6b 65 64 20 61 74 20 73 65 76 65 72 61 6c 20  oked at several 
3560: 70 6f 69 6e 74 73 20 64 75 72 69 6e 67 20 74 68  points during th
3570: 65 0a 68 61 6e 64 73 68 61 6b 65 20 74 6f 20 70  e.handshake to p
3580: 61 73 73 20 65 72 72 6f 72 73 2c 20 74 72 61 63  ass errors, trac
3590: 69 6e 67 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c  ing information,
35a0: 20 61 6e 64 20 70 72 6f 74 6f 63 6f 6c 20 6d 65   and protocol me
35b0: 73 73 61 67 65 73 2e 0a 53 65 65 20 3c 73 70 61  ssages..See <spa
35c0: 6e 20 63 6c 61 73 73 3d 22 73 65 63 74 72 65 66  n class="sectref
35d0: 22 3e 3c 61 20 68 72 65 66 3d 22 23 73 65 63 74  "><a href="#sect
35e0: 69 6f 6e 35 22 3e 43 61 6c 6c 62 61 63 6b 20 4f  ion5">Callback O
35f0: 70 74 69 6f 6e 73 3c 2f 61 3e 3c 2f 73 70 61 6e  ptions</a></span
3600: 3e 20 66 6f 72 20 6d 6f 72 65 20 69 6e 66 6f 2e  > for more info.
3610: 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62  </p></dd>.<dt><b
3620: 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e   class="option">
3630: 2d 64 68 70 61 72 61 6d 73 3c 2f 62 3e 20 3c 69  -dhparams</b> <i
3640: 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 66 69 6c   class="arg">fil
3650: 65 6e 61 6d 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c  ename</i></dt>.<
3660: 64 64 3e 3c 70 3e 53 70 65 63 69 66 69 65 73 20  dd><p>Specifies 
3670: 74 68 65 20 44 69 66 66 69 65 2d 48 65 6c 6c 6d  the Diffie-Hellm
3680: 61 6e 20 28 44 48 29 20 70 61 72 61 6d 65 74 65  an (DH) paramete
3690: 72 73 20 66 69 6c 65 2e 3c 2f 70 3e 3c 2f 64 64  rs file.</p></dd
36a0: 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22  >.<dt><b class="
36b0: 6f 70 74 69 6f 6e 22 3e 2d 6b 65 79 66 69 6c 65  option">-keyfile
36c0: 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61  </b> <i class="a
36d0: 72 67 22 3e 66 69 6c 65 6e 61 6d 65 3c 2f 69 3e  rg">filename</i>
36e0: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 53 70 65  </dt>.<dd><p>Spe
36f0: 63 69 66 69 65 73 20 74 68 65 20 70 72 69 76 61  cifies the priva
3700: 74 65 20 6b 65 79 20 66 69 6c 65 2e 20 54 68 65  te key file. The
3710: 20 64 65 66 61 75 6c 74 20 69 73 20 74 6f 20 75   default is to u
3720: 73 65 20 74 68 65 20 66 69 6c 65 0a 73 70 65 63  se the file.spec
3730: 69 66 69 65 64 20 62 79 20 74 68 65 20 3c 69 20  ified by the <i 
3740: 63 6c 61 73 73 3d 22 61 72 67 22 3e 2d 63 65 72  class="arg">-cer
3750: 74 66 69 6c 65 3c 2f 69 3e 20 6f 70 74 69 6f 6e  tfile</i> option
3760: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
3770: 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22  b class="option"
3780: 3e 2d 6b 65 79 3c 2f 62 3e 20 3c 69 20 63 6c 61  >-key</b> <i cla
3790: 73 73 3d 22 61 72 67 22 3e 73 74 72 69 6e 67 3c  ss="arg">string<
37a0: 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e  /i></dt>.<dd><p>
37b0: 53 70 65 63 69 66 69 65 73 20 74 68 65 20 70 72  Specifies the pr
37c0: 69 76 61 74 65 20 6b 65 79 20 74 6f 20 75 73 65  ivate key to use
37d0: 20 61 73 20 61 20 44 45 52 20 65 6e 63 6f 64 65   as a DER encode
37e0: 64 20 73 74 72 69 6e 67 20 28 50 4b 43 53 23 31  d string (PKCS#1
37f0: 20 44 45 52 29 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a   DER).</p></dd>.
3800: 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70  <dt><b class="op
3810: 74 69 6f 6e 22 3e 2d 6d 6f 64 65 6c 3c 2f 62 3e  tion">-model</b>
3820: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
3830: 63 68 61 6e 6e 65 6c 3c 2f 69 3e 3c 2f 64 74 3e  channel</i></dt>
3840: 0a 3c 64 64 3e 3c 70 3e 46 6f 72 63 65 20 74 68  .<dd><p>Force th
3850: 69 73 20 63 68 61 6e 6e 65 6c 20 74 6f 20 73 68  is channel to sh
3860: 61 72 65 20 74 68 65 20 73 61 6d 65 20 3c 69 20  are the same <i 
3870: 63 6c 61 73 73 3d 22 74 65 72 6d 22 3e 53 53 4c  class="term">SSL
3880: 5f 43 54 58 3c 2f 69 3e 20 73 74 72 75 63 74 75  _CTX</i> structu
3890: 72 65 20 61 73 20 74 68 65 0a 73 70 65 63 69 66  re as the.specif
38a0: 69 65 64 20 3c 69 20 63 6c 61 73 73 3d 22 61 72  ied <i class="ar
38b0: 67 22 3e 63 68 61 6e 6e 65 6c 3c 2f 69 3e 2c 20  g">channel</i>, 
38c0: 61 6e 64 20 74 68 65 72 65 66 6f 72 65 20 73 68  and therefore sh
38d0: 61 72 65 20 63 6f 6e 66 69 67 2c 20 63 61 6c 6c  are config, call
38e0: 62 61 63 6b 73 2c 20 65 74 63 2e 3c 2f 70 3e 3c  backs, etc.</p><
38f0: 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73  /dd>.<dt><b clas
3900: 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 70 61 73 73  s="option">-pass
3910: 77 6f 72 64 3c 2f 62 3e 20 3c 69 20 63 6c 61 73  word</b> <i clas
3920: 73 3d 22 61 72 67 22 3e 63 61 6c 6c 62 61 63 6b  s="arg">callback
3930: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
3940: 3e 53 70 65 63 69 66 69 65 73 20 74 68 65 20 63  >Specifies the c
3950: 61 6c 6c 62 61 63 6b 20 63 6f 6d 6d 61 6e 64 20  allback command 
3960: 74 6f 20 69 6e 76 6f 6b 65 20 77 68 65 6e 20 4f  to invoke when O
3970: 70 65 6e 53 53 4c 20 6e 65 65 64 73 20 74 6f 20  penSSL needs to 
3980: 6f 62 74 61 69 6e 20 61 0a 70 61 73 73 77 6f 72  obtain a.passwor
3990: 64 2e 20 54 68 69 73 20 69 73 20 74 79 70 69 63  d. This is typic
39a0: 61 6c 6c 79 20 75 73 65 64 20 74 6f 20 75 6e 6c  ally used to unl
39b0: 6f 63 6b 20 74 68 65 20 70 72 69 76 61 74 65 20  ock the private 
39c0: 6b 65 79 20 6f 66 20 61 20 63 65 72 74 69 66 69  key of a certifi
39d0: 63 61 74 65 2e 0a 54 68 65 20 63 61 6c 6c 62 61  cate..The callba
39e0: 63 6b 20 73 68 6f 75 6c 64 20 72 65 74 75 72 6e  ck should return
39f0: 20 61 20 70 61 73 73 77 6f 72 64 20 73 74 72 69   a password stri
3a00: 6e 67 2e 20 54 68 69 73 20 6f 70 74 69 6f 6e 20  ng. This option 
3a10: 68 61 73 20 63 68 61 6e 67 65 64 20 66 6f 72 0a  has changed for.
3a20: 54 63 6c 54 4c 53 20 31 2e 38 2e 20 53 65 65 20  TclTLS 1.8. See 
3a30: 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 73 65 63  <span class="sec
3a40: 74 72 65 66 22 3e 3c 61 20 68 72 65 66 3d 22 23  tref"><a href="#
3a50: 73 65 63 74 69 6f 6e 35 22 3e 43 61 6c 6c 62 61  section5">Callba
3a60: 63 6b 20 4f 70 74 69 6f 6e 73 3c 2f 61 3e 3c 2f  ck Options</a></
3a70: 73 70 61 6e 3e 20 66 6f 72 20 6d 6f 72 65 20 69  span> for more i
3a80: 6e 66 6f 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64  nfo.</p></dd>.<d
3a90: 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  t><b class="opti
3aa0: 6f 6e 22 3e 2d 70 6f 73 74 5f 68 61 6e 64 73 68  on">-post_handsh
3ab0: 61 6b 65 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73  ake</b> <i class
3ac0: 3d 22 61 72 67 22 3e 62 6f 6f 6c 3c 2f 69 3e 3c  ="arg">bool</i><
3ad0: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 41 6c 6c 6f  /dt>.<dd><p>Allo
3ae0: 77 20 70 6f 73 74 2d 68 61 6e 64 73 68 61 6b 65  w post-handshake
3af0: 20 73 65 73 73 69 6f 6e 20 74 69 63 6b 65 74 20   session ticket 
3b00: 75 70 64 61 74 65 73 2e 20 54 68 69 73 20 6f 70  updates. This op
3b10: 74 69 6f 6e 20 69 73 20 6e 65 77 20 66 6f 72 20  tion is new for 
3b20: 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c  TclTLS 1.8.</p><
3b30: 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73  /dd>.<dt><b clas
3b40: 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 72 65 71 75  s="option">-requ
3b50: 65 73 74 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73  est</b> <i class
3b60: 3d 22 61 72 67 22 3e 62 6f 6f 6c 3c 2f 69 3e 3c  ="arg">bool</i><
3b70: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 52 65 71 75  /dt>.<dd><p>Requ
3b80: 65 73 74 20 61 20 63 65 72 74 69 66 69 63 61 74  est a certificat
3b90: 65 20 66 72 6f 6d 20 74 68 65 20 70 65 65 72 20  e from the peer 
3ba0: 64 75 72 69 6e 67 20 74 68 65 20 53 53 4c 20 68  during the SSL h
3bb0: 61 6e 64 73 68 61 6b 65 2e 20 54 68 69 73 20 69  andshake. This i
3bc0: 73 20 6e 65 65 64 65 64 0a 74 6f 20 64 6f 20 43  s needed.to do C
3bd0: 65 72 74 69 66 69 63 61 74 65 20 56 61 6c 69 64  ertificate Valid
3be0: 61 74 69 6f 6e 2e 20 53 74 61 72 74 69 6e 67 20  ation. Starting 
3bf0: 69 6e 20 54 63 6c 54 4c 53 20 31 2e 38 2c 20 74  in TclTLS 1.8, t
3c00: 68 65 20 64 65 66 61 75 6c 74 20 69 73 0a 3c 62  he default is.<b
3c10: 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 74   class="const">t
3c20: 72 75 65 3c 2f 62 3e 2e 20 53 74 61 72 74 69 6e  rue</b>. Startin
3c30: 67 20 69 6e 20 54 63 6c 54 4c 53 20 32 2e 30 2c  g in TclTLS 2.0,
3c40: 20 49 66 20 73 65 74 20 74 6f 20 3c 62 20 63 6c   If set to <b cl
3c50: 61 73 73 3d 22 63 6f 6e 73 74 22 3e 66 61 6c 73  ass="const">fals
3c60: 65 3c 2f 62 3e 20 61 6e 64 0a 3c 62 20 63 6c 61  e</b> and.<b cla
3c70: 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 72 65 71  ss="option">-req
3c80: 75 69 72 65 3c 2f 62 3e 20 69 73 20 3c 62 20 63  uire</b> is <b c
3c90: 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 74 72 75  lass="const">tru
3ca0: 65 3c 2f 62 3e 2c 20 74 68 65 6e 20 74 68 69 73  e</b>, then this
3cb0: 20 77 69 6c 6c 20 62 65 20 6f 76 65 72 72 69 64   will be overrid
3cc0: 64 65 6e 20 74 6f 20 3c 62 20 63 6c 61 73 73 3d  den to <b class=
3cd0: 22 63 6f 6e 73 74 22 3e 74 72 75 65 3c 2f 62 3e  "const">true</b>
3ce0: 2e 0a 53 65 65 20 3c 73 70 61 6e 20 63 6c 61 73  ..See <span clas
3cf0: 73 3d 22 73 65 63 74 72 65 66 22 3e 3c 61 20 68  s="sectref"><a h
3d00: 72 65 66 3d 22 23 73 65 63 74 69 6f 6e 34 22 3e  ref="#section4">
3d10: 43 65 72 74 69 66 69 63 61 74 65 20 56 61 6c 69  Certificate Vali
3d20: 64 61 74 69 6f 6e 3c 2f 61 3e 3c 2f 73 70 61 6e  dation</a></span
3d30: 3e 20 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 69  > for more detai
3d40: 6c 73 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  ls.</p></dd>.<dt
3d50: 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f  ><b class="optio
3d60: 6e 22 3e 2d 72 65 71 75 69 72 65 3c 2f 62 3e 20  n">-require</b> 
3d70: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 62  <i class="arg">b
3d80: 6f 6f 6c 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64  ool</i></dt>.<dd
3d90: 3e 3c 70 3e 52 65 71 75 69 72 65 20 61 20 76 61  ><p>Require a va
3da0: 6c 69 64 20 63 65 72 74 69 66 69 63 61 74 65 20  lid certificate 
3db0: 66 72 6f 6d 20 74 68 65 20 70 65 65 72 20 64 75  from the peer du
3dc0: 72 69 6e 67 20 74 68 65 20 53 53 4c 20 68 61 6e  ring the SSL han
3dd0: 64 73 68 61 6b 65 2e 20 49 66 20 74 68 69 73 20  dshake. If this 
3de0: 69 73 0a 73 65 74 20 74 6f 20 74 72 75 65 2c 20  is.set to true, 
3df0: 74 68 65 6e 20 3c 62 20 63 6c 61 73 73 3d 22 6f  then <b class="o
3e00: 70 74 69 6f 6e 22 3e 2d 72 65 71 75 65 73 74 3c  ption">-request<
3e10: 2f 62 3e 20 6d 75 73 74 20 61 6c 73 6f 20 62 65  /b> must also be
3e20: 20 73 65 74 20 74 6f 20 74 72 75 65 20 61 6e 64   set to true and
3e30: 20 61 20 65 69 74 68 65 72 0a 3c 62 20 63 6c 61   a either.<b cla
3e40: 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 64  ss="option">-cad
3e50: 69 72 3c 2f 62 3e 2c 20 3c 62 20 63 6c 61 73 73  ir</b>, <b class
3e60: 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 66 69 6c  ="option">-cafil
3e70: 65 3c 2f 62 3e 2c 20 3c 62 20 63 6c 61 73 73 3d  e</b>, <b class=
3e80: 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 73 74 6f 72  "option">-castor
3e90: 65 3c 2f 62 3e 2c 20 6f 72 20 61 20 70 6c 61 74  e</b>, or a plat
3ea0: 66 6f 72 6d 20 64 65 66 61 75 6c 74 0a 6d 75 73  form default.mus
3eb0: 74 20 62 65 20 70 72 6f 76 69 64 65 64 20 69 6e  t be provided in
3ec0: 20 6f 72 64 65 72 20 74 6f 20 76 61 6c 69 64 61   order to valida
3ed0: 74 65 20 61 67 61 69 6e 73 74 2e 20 54 68 65 20  te against. The 
3ee0: 64 65 66 61 75 6c 74 20 69 6e 20 54 63 6c 54 4c  default in TclTL
3ef0: 53 20 31 2e 38 20 61 6e 64 0a 65 61 72 6c 69 65  S 1.8 and.earlie
3f00: 72 20 76 65 72 73 69 6f 6e 73 20 69 73 20 3c 62  r versions is <b
3f10: 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 66   class="const">f
3f20: 61 6c 73 65 3c 2f 62 3e 20 73 69 6e 63 65 20 6e  alse</b> since n
3f30: 6f 74 20 61 6c 6c 20 70 6c 61 74 66 6f 72 6d 73  ot all platforms
3f40: 20 68 61 76 65 20 63 65 72 74 69 66 69 63 61 74   have certificat
3f50: 65 73 20 74 6f 0a 76 61 6c 69 64 61 74 65 20 61  es to.validate a
3f60: 67 61 69 6e 73 74 20 69 6e 20 61 20 66 6f 72 6d  gainst in a form
3f70: 20 63 6f 6d 70 61 74 69 62 6c 65 20 77 69 74 68   compatible with
3f80: 20 4f 70 65 6e 53 53 4c 2e 20 53 74 61 72 74 69   OpenSSL. Starti
3f90: 6e 67 20 69 6e 20 54 63 6c 54 4c 53 20 32 2e 30  ng in TclTLS 2.0
3fa0: 2c 0a 74 68 65 20 64 65 66 61 75 6c 74 20 69 73  ,.the default is
3fb0: 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74   <b class="const
3fc0: 22 3e 74 72 75 65 3c 2f 62 3e 2e 0a 53 65 65 20  ">true</b>..See 
3fd0: 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 73 65 63  <span class="sec
3fe0: 74 72 65 66 22 3e 3c 61 20 68 72 65 66 3d 22 23  tref"><a href="#
3ff0: 73 65 63 74 69 6f 6e 34 22 3e 43 65 72 74 69 66  section4">Certif
4000: 69 63 61 74 65 20 56 61 6c 69 64 61 74 69 6f 6e  icate Validation
4010: 3c 2f 61 3e 3c 2f 73 70 61 6e 3e 20 66 6f 72 20  </a></span> for 
4020: 6d 6f 72 65 20 64 65 74 61 69 6c 73 2e 3c 2f 70  more details.</p
4030: 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c  ></dd>.<dt><b cl
4040: 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 73 65  ass="option">-se
4050: 63 75 72 69 74 79 5f 6c 65 76 65 6c 3c 2f 62 3e  curity_level</b>
4060: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
4070: 69 6e 74 65 67 65 72 3c 2f 69 3e 3c 2f 64 74 3e  integer</i></dt>
4080: 0a 3c 64 64 3e 3c 70 3e 53 70 65 63 69 66 69 65  .<dd><p>Specifie
4090: 73 20 74 68 65 20 73 65 63 75 72 69 74 79 20 6c  s the security l
40a0: 65 76 65 6c 20 28 76 61 6c 75 65 20 66 72 6f 6d  evel (value from
40b0: 20 30 20 74 6f 20 35 29 2e 20 54 68 65 20 73 65   0 to 5). The se
40c0: 63 75 72 69 74 79 20 6c 65 76 65 6c 20 61 66 66  curity level aff
40d0: 65 63 74 73 0a 74 68 65 20 61 6c 6c 6f 77 65 64  ects.the allowed
40e0: 20 63 69 70 68 65 72 20 73 75 69 74 65 20 65 6e   cipher suite en
40f0: 63 72 79 70 74 69 6f 6e 20 61 6c 67 6f 72 69 74  cryption algorit
4100: 68 6d 73 2c 20 73 75 70 70 6f 72 74 65 64 20 45  hms, supported E
4110: 43 43 20 63 75 72 76 65 73 2c 0a 73 75 70 70 6f  CC curves,.suppo
4120: 72 74 65 64 20 73 69 67 6e 61 74 75 72 65 20 61  rted signature a
4130: 6c 67 6f 72 69 74 68 6d 73 2c 20 44 48 20 70 61  lgorithms, DH pa
4140: 72 61 6d 65 74 65 72 20 73 69 7a 65 73 2c 20 63  rameter sizes, c
4150: 65 72 74 69 66 69 63 61 74 65 20 6b 65 79 20 73  ertificate key s
4160: 69 7a 65 73 0a 61 6e 64 20 73 69 67 6e 61 74 75  izes.and signatu
4170: 72 65 20 61 6c 67 6f 72 69 74 68 6d 73 2e 20 54  re algorithms. T
4180: 68 65 20 64 65 66 61 75 6c 74 20 69 73 20 31 20  he default is 1 
4190: 70 72 69 6f 72 20 74 6f 20 4f 70 65 6e 53 53 4c  prior to OpenSSL
41a0: 20 33 2e 32 20 61 6e 64 20 32 0a 74 68 65 72 65   3.2 and 2.there
41b0: 61 66 74 65 72 2e 20 4c 65 76 65 6c 20 33 20 61  after. Level 3 a
41c0: 6e 64 20 68 69 67 68 65 72 20 64 69 73 61 62 6c  nd higher disabl
41d0: 65 20 73 75 70 70 6f 72 74 20 66 6f 72 20 73 65  e support for se
41e0: 73 73 69 6f 6e 20 74 69 63 6b 65 74 73 20 61 6e  ssion tickets an
41f0: 64 0a 6f 6e 6c 79 20 61 63 63 65 70 74 20 63 69  d.only accept ci
4200: 70 68 65 72 20 73 75 69 74 65 73 20 74 68 61 74  pher suites that
4210: 20 70 72 6f 76 69 64 65 20 66 6f 72 77 61 72 64   provide forward
4220: 20 73 65 63 72 65 63 79 2e 0a 54 68 69 73 20 6f   secrecy..This o
4230: 70 74 69 6f 6e 20 69 73 20 6e 65 77 20 66 6f 72  ption is new for
4240: 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e   TclTLS 1.8.</p>
4250: 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61  </dd>.<dt><b cla
4260: 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 73 65 72  ss="option">-ser
4270: 76 65 72 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73  ver</b> <i class
4280: 3d 22 61 72 67 22 3e 62 6f 6f 6c 3c 2f 69 3e 3c  ="arg">bool</i><
4290: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 53 70 65 63  /dt>.<dd><p>Spec
42a0: 69 66 69 65 73 20 77 68 65 74 68 65 72 20 74 6f  ifies whether to
42b0: 20 61 63 74 20 61 73 20 61 20 73 65 72 76 65 72   act as a server
42c0: 20 61 6e 64 20 72 65 73 70 6f 6e 64 20 77 69 74   and respond wit
42d0: 68 20 61 20 73 65 72 76 65 72 20 68 61 6e 64 73  h a server hands
42e0: 68 61 6b 65 20 77 68 65 6e 20 61 0a 63 6c 69 65  hake when a.clie
42f0: 6e 74 20 63 6f 6e 6e 65 63 74 73 20 61 6e 64 20  nt connects and 
4300: 70 72 6f 76 69 64 65 73 20 61 20 63 6c 69 65 6e  provides a clien
4310: 74 20 68 61 6e 64 73 68 61 6b 65 2e 20 54 68 65  t handshake. The
4320: 20 64 65 66 61 75 6c 74 20 69 73 20 3c 62 20 63   default is <b c
4330: 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 66 61 6c  lass="const">fal
4340: 73 65 3c 2f 62 3e 2e 3c 2f 70 3e 3c 2f 64 64 3e  se</b>.</p></dd>
4350: 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f  .<dt><b class="o
4360: 70 74 69 6f 6e 22 3e 2d 73 65 72 76 65 72 6e 61  ption">-serverna
4370: 6d 65 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  me</b> <i class=
4380: 22 61 72 67 22 3e 68 6f 73 74 6e 61 6d 65 3c 2f  "arg">hostname</
4390: 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 53  i></dt>.<dd><p>S
43a0: 70 65 63 69 66 79 20 74 68 65 20 70 65 65 72 27  pecify the peer'
43b0: 73 20 68 6f 73 74 6e 61 6d 65 2e 20 54 68 69 73  s hostname. This
43c0: 20 69 73 20 75 73 65 64 20 74 6f 20 73 65 74 20   is used to set 
43d0: 74 68 65 20 54 4c 53 20 53 65 72 76 65 72 20 4e  the TLS Server N
43e0: 61 6d 65 20 49 6e 64 69 63 61 74 69 6f 6e 0a 28  ame Indication.(
43f0: 53 4e 49 29 20 65 78 74 65 6e 73 69 6f 6e 2e 20  SNI) extension. 
4400: 53 65 74 20 74 68 69 73 20 74 6f 20 74 68 65 20  Set this to the 
4410: 65 78 70 65 63 74 65 64 20 73 65 72 76 65 72 6e  expected servern
4420: 61 6d 65 20 69 6e 20 74 68 65 20 73 65 72 76 65  ame in the serve
4430: 72 27 73 20 63 65 72 74 69 66 69 63 61 74 65 0a  r's certificate.
4440: 6f 72 20 6f 6e 65 20 6f 66 20 74 68 65 20 53 75  or one of the Su
4450: 62 6a 65 63 74 20 41 6c 74 65 72 6e 61 74 65 20  bject Alternate 
4460: 4e 61 6d 65 73 20 28 53 41 4e 29 2e 20 53 74 61  Names (SAN). Sta
4470: 72 74 69 6e 67 20 69 6e 20 54 63 6c 54 4c 53 20  rting in TclTLS 
4480: 32 2e 30 2c 20 74 68 69 73 20 77 69 6c 6c 0a 64  2.0, this will.d
4490: 65 66 61 75 6c 74 20 74 6f 20 74 68 65 20 68 6f  efault to the ho
44a0: 73 74 20 66 6f 72 20 74 68 65 20 3c 62 20 63 6c  st for the <b cl
44b0: 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 73  ass="cmd">tls::s
44c0: 6f 63 6b 65 74 3c 2f 62 3e 20 63 6f 6d 6d 61 6e  ocket</b> comman
44d0: 64 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  d.</p></dd>.<dt>
44e0: 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e  <b class="option
44f0: 22 3e 2d 73 65 73 73 69 6f 6e 5f 69 64 3c 2f 62  ">-session_id</b
4500: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  > <i class="arg"
4510: 3e 62 69 6e 61 72 79 5f 73 74 72 69 6e 67 3c 2f  >binary_string</
4520: 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 53  i></dt>.<dd><p>S
4530: 70 65 63 69 66 69 65 73 20 74 68 65 20 73 65 73  pecifies the ses
4540: 73 69 6f 6e 20 69 64 20 74 6f 20 72 65 73 75 6d  sion id to resum
4550: 65 20 61 20 73 65 73 73 69 6f 6e 2e 20 4e 6f 74  e a session. Not
4560: 20 73 75 70 70 6f 72 74 65 64 20 79 65 74 2e 0a   supported yet..
4570: 54 68 69 73 20 6f 70 74 69 6f 6e 20 69 73 20 6e  This option is n
4580: 65 77 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e  ew for TclTLS 1.
4590: 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  8.</p></dd>.<dt>
45a0: 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e  <b class="option
45b0: 22 3e 2d 73 73 6c 32 3c 2f 62 3e 20 3c 69 20 63  ">-ssl2</b> <i c
45c0: 6c 61 73 73 3d 22 61 72 67 22 3e 62 6f 6f 6c 3c  lass="arg">bool<
45d0: 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e  /i></dt>.<dd><p>
45e0: 45 6e 61 62 6c 65 20 75 73 65 20 6f 66 20 53 53  Enable use of SS
45f0: 4c 20 76 32 2e 54 68 65 20 64 65 66 61 75 6c 74  L v2.The default
4600: 20 69 73 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f   is <b class="co
4610: 6e 73 74 22 3e 66 61 6c 73 65 3c 2f 62 3e 2e 0a  nst">false</b>..
4620: 4f 70 65 6e 53 53 4c 20 31 2e 31 2b 20 6e 6f 20  OpenSSL 1.1+ no 
4630: 6c 6f 6e 67 65 72 20 73 75 70 70 6f 72 74 73 20  longer supports 
4640: 53 53 4c 20 76 32 2c 20 73 6f 20 74 68 69 73 20  SSL v2, so this 
4650: 6d 61 79 20 6e 6f 74 20 68 61 76 65 20 61 6e 79  may not have any
4660: 20 65 66 66 65 63 74 2e 0a 53 65 65 20 74 68 65   effect..See the
4670: 20 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e   <b class="cmd">
4680: 74 6c 73 3a 3a 70 72 6f 74 6f 63 6f 6c 73 3c 2f  tls::protocols</
4690: 62 3e 20 63 6f 6d 6d 61 6e 64 20 66 6f 72 20 73  b> command for s
46a0: 75 70 70 6f 72 74 65 64 20 70 72 6f 74 6f 63 6f  upported protoco
46b0: 6c 73 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  ls.</p></dd>.<dt
46c0: 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f  ><b class="optio
46d0: 6e 22 3e 2d 73 73 6c 33 3c 2f 62 3e 20 3c 69 20  n">-ssl3</b> <i 
46e0: 63 6c 61 73 73 3d 22 61 72 67 22 3e 62 6f 6f 6c  class="arg">bool
46f0: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
4700: 3e 45 6e 61 62 6c 65 20 75 73 65 20 6f 66 20 53  >Enable use of S
4710: 53 4c 20 76 33 2e 20 54 68 65 20 64 65 66 61 75  SL v3. The defau
4720: 6c 74 20 69 73 20 3c 62 20 63 6c 61 73 73 3d 22  lt is <b class="
4730: 63 6f 6e 73 74 22 3e 66 61 6c 73 65 3c 2f 62 3e  const">false</b>
4740: 2e 20 53 74 61 72 74 69 6e 67 20 69 6e 20 54 63  . Starting in Tc
4750: 6c 54 4c 53 20 31 2e 38 2c 0a 75 73 65 20 6f 66  lTLS 1.8,.use of
4760: 20 53 53 4c 20 76 33 20 69 66 20 6f 6e 6c 79 20   SSL v3 if only 
4770: 61 76 61 69 6c 61 62 6c 65 20 76 69 61 20 61 20  available via a 
4780: 63 6f 6d 70 69 6c 65 20 74 69 6d 65 20 6f 70 74  compile time opt
4790: 69 6f 6e 2e 0a 53 65 65 20 74 68 65 20 3c 62 20  ion..See the <b 
47a0: 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a  class="cmd">tls:
47b0: 3a 70 72 6f 74 6f 63 6f 6c 73 3c 2f 62 3e 20 63  :protocols</b> c
47c0: 6f 6d 6d 61 6e 64 20 66 6f 72 20 73 75 70 70 6f  ommand for suppo
47d0: 72 74 65 64 20 70 72 6f 74 6f 63 6f 6c 73 2e 3c  rted protocols.<
47e0: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
47f0: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
4800: 74 6c 73 31 3c 2f 62 3e 20 3c 69 20 63 6c 61 73  tls1</b> <i clas
4810: 73 3d 22 61 72 67 22 3e 62 6f 6f 6c 3c 2f 69 3e  s="arg">bool</i>
4820: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 45 6e 61  </dt>.<dd><p>Ena
4830: 62 6c 65 20 75 73 65 20 6f 66 20 54 4c 53 20 76  ble use of TLS v
4840: 31 2e 20 53 74 61 72 74 69 6e 67 20 69 6e 20 54  1. Starting in T
4850: 63 6c 54 4c 53 20 32 2e 30 2c 20 74 68 65 20 64  clTLS 2.0, the d
4860: 65 66 61 75 6c 74 20 69 73 20 3c 62 20 63 6c 61  efault is <b cla
4870: 73 73 3d 22 63 6f 6e 73 74 22 3e 66 61 6c 73 65  ss="const">false
4880: 3c 2f 62 3e 2e 0a 4e 6f 74 65 3a 20 54 4c 53 20  </b>..Note: TLS 
4890: 31 2e 30 20 6e 65 65 64 73 20 53 48 41 31 20 74  1.0 needs SHA1 t
48a0: 6f 20 6f 70 65 72 61 74 65 2c 20 77 68 69 63 68  o operate, which
48b0: 20 69 73 20 6f 6e 6c 79 20 61 76 61 69 6c 61 62   is only availab
48c0: 6c 65 20 69 6e 20 73 65 63 75 72 69 74 79 20 6c  le in security l
48d0: 65 76 65 6c 0a 30 20 66 6f 72 20 4f 70 65 6e 20  evel.0 for Open 
48e0: 53 53 4c 20 33 2e 30 2b 2e 20 53 65 65 20 74 68  SSL 3.0+. See th
48f0: 65 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  e <i class="arg"
4900: 3e 2d 73 65 63 75 72 69 74 79 5f 6c 65 76 65 6c  >-security_level
4910: 3c 2f 69 3e 20 6f 70 74 69 6f 6e 2e 3c 2f 70 3e  </i> option.</p>
4920: 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61  </dd>.<dt><b cla
4930: 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 74 6c 73  ss="option">-tls
4940: 31 2e 31 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73  1.1</b> <i class
4950: 3d 22 61 72 67 22 3e 62 6f 6f 6c 3c 2f 69 3e 3c  ="arg">bool</i><
4960: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 45 6e 61 62  /dt>.<dd><p>Enab
4970: 6c 65 20 75 73 65 20 6f 66 20 54 4c 53 20 76 31  le use of TLS v1
4980: 2e 31 2e 20 53 74 61 72 74 69 6e 67 20 69 6e 20  .1. Starting in 
4990: 54 63 6c 54 4c 53 20 32 2e 30 2c 20 74 68 65 20  TclTLS 2.0, the 
49a0: 64 65 66 61 75 6c 74 20 69 73 20 3c 62 20 63 6c  default is <b cl
49b0: 61 73 73 3d 22 63 6f 6e 73 74 22 3e 66 61 6c 73  ass="const">fals
49c0: 65 3c 2f 62 3e 2e 0a 4e 6f 74 65 3a 20 54 4c 53  e</b>..Note: TLS
49d0: 20 31 2e 31 20 6e 65 65 64 73 20 53 48 41 31 20   1.1 needs SHA1 
49e0: 74 6f 20 6f 70 65 72 61 74 65 2c 20 77 68 69 63  to operate, whic
49f0: 68 20 69 73 20 6f 6e 6c 79 20 61 76 61 69 6c 61  h is only availa
4a00: 62 6c 65 20 69 6e 20 73 65 63 75 72 69 74 79 20  ble in security 
4a10: 6c 65 76 65 6c 0a 30 20 66 6f 72 20 4f 70 65 6e  level.0 for Open
4a20: 20 53 53 4c 20 33 2e 30 2b 2e 20 53 65 65 20 74   SSL 3.0+. See t
4a30: 68 65 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67  he <i class="arg
4a40: 22 3e 2d 73 65 63 75 72 69 74 79 5f 6c 65 76 65  ">-security_leve
4a50: 6c 3c 2f 69 3e 20 6f 70 74 69 6f 6e 2e 3c 2f 70  l</i> option.</p
4a60: 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c  ></dd>.<dt><b cl
4a70: 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 74 6c  ass="option">-tl
4a80: 73 31 2e 32 3c 2f 62 3e 20 3c 69 20 63 6c 61 73  s1.2</b> <i clas
4a90: 73 3d 22 61 72 67 22 3e 62 6f 6f 6c 3c 2f 69 3e  s="arg">bool</i>
4aa0: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 45 6e 61  </dt>.<dd><p>Ena
4ab0: 62 6c 65 20 75 73 65 20 6f 66 20 54 4c 53 20 76  ble use of TLS v
4ac0: 31 2e 32 2e 20 54 68 65 20 64 65 66 61 75 6c 74  1.2. The default
4ad0: 20 69 73 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f   is <b class="co
4ae0: 6e 73 74 22 3e 74 72 75 65 3c 2f 62 3e 2e 3c 2f  nst">true</b>.</
4af0: 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63  p></dd>.<dt><b c
4b00: 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 74  lass="option">-t
4b10: 6c 73 31 2e 33 3c 2f 62 3e 20 3c 69 20 63 6c 61  ls1.3</b> <i cla
4b20: 73 73 3d 22 61 72 67 22 3e 62 6f 6f 6c 3c 2f 69  ss="arg">bool</i
4b30: 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 45 6e  ></dt>.<dd><p>En
4b40: 61 62 6c 65 20 75 73 65 20 6f 66 20 54 4c 53 20  able use of TLS 
4b50: 76 31 2e 33 2e 20 54 68 65 20 64 65 66 61 75 6c  v1.3. The defaul
4b60: 74 20 69 73 20 3c 62 20 63 6c 61 73 73 3d 22 63  t is <b class="c
4b70: 6f 6e 73 74 22 3e 74 72 75 65 3c 2f 62 3e 2e 20  onst">true</b>. 
4b80: 54 68 69 73 20 69 73 20 6f 6e 6c 79 20 61 76 61  This is only ava
4b90: 69 6c 61 62 6c 65 0a 73 74 61 72 74 69 6e 67 20  ilable.starting 
4ba0: 77 69 74 68 20 4f 70 65 6e 53 53 4c 20 31 2e 31  with OpenSSL 1.1
4bb0: 2e 31 20 61 6e 64 20 54 63 6c 54 4c 53 20 31 2e  .1 and TclTLS 1.
4bc0: 37 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  7.</p></dd>.<dt>
4bd0: 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e  <b class="option
4be0: 22 3e 2d 76 61 6c 69 64 61 74 65 63 6f 6d 6d 61  ">-validatecomma
4bf0: 6e 64 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  nd</b> <i class=
4c00: 22 61 72 67 22 3e 63 61 6c 6c 62 61 63 6b 3c 2f  "arg">callback</
4c10: 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 53  i></dt>.<dd><p>S
4c20: 70 65 63 69 66 69 65 73 20 74 68 65 20 63 61 6c  pecifies the cal
4c30: 6c 62 61 63 6b 20 63 6f 6d 6d 61 6e 64 20 74 6f  lback command to
4c40: 20 69 6e 76 6f 6b 65 20 74 6f 20 76 61 6c 69 64   invoke to valid
4c50: 61 74 65 20 74 68 65 20 70 65 65 72 20 63 65 72  ate the peer cer
4c60: 74 69 66 69 63 61 74 65 73 0a 61 6e 64 20 6f 74  tificates.and ot
4c70: 68 65 72 20 63 6f 6e 66 69 67 20 69 6e 66 6f 20  her config info 
4c80: 64 75 72 69 6e 67 20 74 68 65 20 70 72 6f 74 6f  during the proto
4c90: 63 6f 6c 20 6e 65 67 6f 74 69 61 74 69 6f 6e 20  col negotiation 
4ca0: 70 68 61 73 65 2e 20 54 68 69 73 20 63 61 6e 20  phase. This can 
4cb0: 62 65 20 75 73 65 64 0a 62 79 20 54 43 4c 20 73  be used.by TCL s
4cc0: 63 72 69 70 74 73 20 74 6f 20 70 65 72 66 6f 72  cripts to perfor
4cd0: 6d 20 74 68 65 69 72 20 6f 77 6e 20 43 65 72 74  m their own Cert
4ce0: 69 66 69 63 61 74 65 20 56 61 6c 69 64 61 74 69  ificate Validati
4cf0: 6f 6e 20 74 6f 20 73 75 70 70 6c 65 6d 65 6e 74  on to supplement
4d00: 20 74 68 65 0a 64 65 66 61 75 6c 74 20 76 61 6c   the.default val
4d10: 69 64 61 74 69 6f 6e 20 70 72 6f 76 69 64 65 64  idation provided
4d20: 20 62 79 20 4f 70 65 6e 53 53 4c 2e 20 54 68 65   by OpenSSL. The
4d30: 20 73 63 72 69 70 74 20 6d 75 73 74 20 72 65 74   script must ret
4d40: 75 72 6e 20 61 20 62 6f 6f 6c 65 61 6e 20 74 72  urn a boolean tr
4d50: 75 65 0a 74 6f 20 63 6f 6e 74 69 6e 75 65 20 74  ue.to continue t
4d60: 68 65 20 6e 65 67 6f 74 69 61 74 69 6f 6e 2e 20  he negotiation. 
4d70: 53 65 65 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d  See <span class=
4d80: 22 73 65 63 74 72 65 66 22 3e 3c 61 20 68 72 65  "sectref"><a hre
4d90: 66 3d 22 23 73 65 63 74 69 6f 6e 35 22 3e 43 61  f="#section5">Ca
4da0: 6c 6c 62 61 63 6b 20 4f 70 74 69 6f 6e 73 3c 2f  llback Options</
4db0: 61 3e 3c 2f 73 70 61 6e 3e 20 66 6f 72 20 6d 6f  a></span> for mo
4dc0: 72 65 20 69 6e 66 6f 2e 0a 54 68 69 73 20 6f 70  re info..This op
4dd0: 74 69 6f 6e 20 69 73 20 6e 65 77 20 66 6f 72 20  tion is new for 
4de0: 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c  TclTLS 1.8.</p><
4df0: 2f 64 64 3e 0a 3c 2f 64 6c 3e 3c 2f 64 64 3e 0a  /dd>.</dl></dd>.
4e00: 3c 64 74 3e 3c 61 20 6e 61 6d 65 3d 22 35 22 3e  <dt><a name="5">
4e10: 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74  <b class="cmd">t
4e20: 6c 73 3a 3a 75 6e 69 6d 70 6f 72 74 3c 2f 62 3e  ls::unimport</b>
4e30: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
4e40: 63 68 61 6e 6e 65 6c 3c 2f 69 3e 3c 2f 61 3e 3c  channel</i></a><
4e50: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 43 6f 6d 70  /dt>.<dd><p>Comp
4e60: 6c 69 6d 65 6e 74 20 74 6f 20 3c 62 20 63 6c 61  liment to <b cla
4e70: 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 69 6d  ss="cmd">tls::im
4e80: 70 6f 72 74 3c 2f 62 3e 2e 20 55 73 65 64 20 74  port</b>. Used t
4e90: 6f 20 72 65 6d 6f 76 65 20 74 68 65 20 74 6f 70  o remove the top
4ea0: 20 6c 65 76 65 6c 20 73 74 61 63 6b 65 64 20 63   level stacked c
4eb0: 68 61 6e 6e 65 6c 0a 66 72 6f 6d 20 3c 69 20 63  hannel.from <i c
4ec0: 6c 61 73 73 3d 22 61 72 67 22 3e 63 68 61 6e 6e  lass="arg">chann
4ed0: 65 6c 3c 2f 69 3e 2e 20 54 68 69 73 20 75 6e 73  el</i>. This uns
4ee0: 74 61 63 6b 73 20 74 68 65 20 65 6e 63 72 79 70  tacks the encryp
4ef0: 74 69 6f 6e 20 6f 66 20 61 20 72 65 67 75 6c 61  tion of a regula
4f00: 72 20 54 43 4c 20 63 68 61 6e 6e 65 6c 2e 20 41  r TCL channel. A
4f10: 6e 0a 65 72 72 6f 72 20 69 73 20 74 68 72 6f 77  n.error is throw
4f20: 6e 20 69 66 20 54 4c 53 20 69 73 20 6e 6f 74 20  n if TLS is not 
4f30: 74 68 65 20 74 6f 70 20 73 74 61 63 6b 65 64 20  the top stacked 
4f40: 63 68 61 6e 6e 65 6c 20 74 79 70 65 2e 3c 2f 70  channel type.</p
4f50: 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 61 20 6e 61  ></dd>.<dt><a na
4f60: 6d 65 3d 22 36 22 3e 3c 62 20 63 6c 61 73 73 3d  me="6"><b class=
4f70: 22 63 6d 64 22 3e 74 6c 73 3a 3a 68 61 6e 64 73  "cmd">tls::hands
4f80: 68 61 6b 65 3c 2f 62 3e 20 3c 69 20 63 6c 61 73  hake</b> <i clas
4f90: 73 3d 22 61 72 67 22 3e 63 68 61 6e 6e 65 6c 3c  s="arg">channel<
4fa0: 2f 69 3e 3c 2f 61 3e 3c 2f 64 74 3e 0a 3c 64 64  /i></a></dt>.<dd
4fb0: 3e 3c 70 3e 46 6f 72 63 65 73 20 74 68 65 20 54  ><p>Forces the T
4fc0: 4c 53 20 6e 65 67 6f 74 69 61 74 69 6f 6e 20 68  LS negotiation h
4fd0: 61 6e 64 73 68 61 6b 65 20 74 6f 20 74 61 6b 65  andshake to take
4fe0: 20 70 6c 61 63 65 20 69 6d 6d 65 64 69 61 74 65   place immediate
4ff0: 6c 79 2c 20 61 6e 64 20 72 65 74 75 72 6e 73 20  ly, and returns 
5000: 30 0a 69 66 20 68 61 6e 64 73 68 61 6b 65 20 69  0.if handshake i
5010: 73 20 73 74 69 6c 6c 20 69 6e 20 70 72 6f 67 72  s still in progr
5020: 65 73 73 20 28 6e 6f 6e 2d 62 6c 6f 63 6b 69 6e  ess (non-blockin
5030: 67 29 2c 20 6f 72 20 31 20 69 66 20 74 68 65 20  g), or 1 if the 
5040: 68 61 6e 64 73 68 61 6b 65 20 77 61 73 0a 73 75  handshake was.su
5050: 63 63 65 73 73 66 75 6c 2e 20 49 66 20 74 68 65  ccessful. If the
5060: 20 68 61 6e 64 73 68 61 6b 65 20 66 61 69 6c 65   handshake faile
5070: 64 2c 20 61 6e 20 65 72 72 6f 72 20 77 69 6c 6c  d, an error will
5080: 20 62 65 20 72 65 74 75 72 6e 65 64 2e 3c 2f 70   be returned.</p
5090: 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 61 20 6e 61  ></dd>.<dt><a na
50a0: 6d 65 3d 22 37 22 3e 3c 62 20 63 6c 61 73 73 3d  me="7"><b class=
50b0: 22 63 6d 64 22 3e 74 6c 73 3a 3a 73 74 61 74 75  "cmd">tls::statu
50c0: 73 3c 2f 62 3e 20 3c 73 70 61 6e 20 63 6c 61 73  s</b> <span clas
50d0: 73 3d 22 6f 70 74 22 3e 3f 3c 62 20 63 6c 61 73  s="opt">?<b clas
50e0: 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 6c 6f 63 61  s="option">-loca
50f0: 6c 3c 2f 62 3e 3f 3c 2f 73 70 61 6e 3e 20 3c 69  l</b>?</span> <i
5100: 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 63 68 61   class="arg">cha
5110: 6e 6e 65 6c 3c 2f 69 3e 3c 2f 61 3e 3c 2f 64 74  nnel</i></a></dt
5120: 3e 0a 3c 64 64 3e 3c 70 3e 52 65 74 75 72 6e 73  >.<dd><p>Returns
5130: 20 74 68 65 20 63 75 72 72 65 6e 74 20 73 74 61   the current sta
5140: 74 75 73 20 6f 66 20 61 6e 20 53 53 4c 20 63 68  tus of an SSL ch
5150: 61 6e 6e 65 6c 2e 20 54 68 65 20 72 65 73 75 6c  annel. The resul
5160: 74 20 69 73 20 61 20 6c 69 73 74 20 6f 66 20 6b  t is a list of k
5170: 65 79 2d 76 61 6c 75 65 0a 70 61 69 72 73 20 64  ey-value.pairs d
5180: 65 73 63 72 69 62 69 6e 67 20 74 68 65 20 53 53  escribing the SS
5190: 4c 2c 20 63 65 72 74 69 66 69 63 61 74 65 2c 20  L, certificate, 
51a0: 61 6e 64 20 63 65 72 74 69 66 69 63 61 74 65 20  and certificate 
51b0: 76 65 72 69 66 69 63 61 74 69 6f 6e 20 73 74 61  verification sta
51c0: 74 75 73 2e 20 49 66 0a 74 68 65 20 53 53 4c 20  tus. If.the SSL 
51d0: 68 61 6e 64 73 68 61 6b 65 20 68 61 73 20 6e 6f  handshake has no
51e0: 74 20 79 65 74 20 63 6f 6d 70 6c 65 74 65 64 2c  t yet completed,
51f0: 20 61 6e 20 65 6d 70 74 79 20 6c 69 73 74 20 69   an empty list i
5200: 73 20 72 65 74 75 72 6e 65 64 2e 20 49 66 20 74  s returned. If t
5210: 68 65 0a 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74  he.<b class="opt
5220: 69 6f 6e 22 3e 2d 6c 6f 63 61 6c 3c 2f 62 3e 20  ion">-local</b> 
5230: 6f 70 74 69 6f 6e 20 69 73 20 73 70 65 63 69 66  option is specif
5240: 69 65 64 2c 20 74 68 65 6e 20 74 68 65 20 6c 6f  ied, then the lo
5250: 63 61 6c 20 63 65 72 74 69 66 69 63 61 74 65 20  cal certificate 
5260: 69 73 20 75 73 65 64 2e 20 52 65 74 75 72 6e 65  is used. Returne
5270: 64 0a 76 61 6c 75 65 73 20 69 6e 63 6c 75 64 65  d.values include
5280: 3a 3c 2f 70 3e 0a 3c 70 3e 53 53 4c 20 53 74 61  :</p>.<p>SSL Sta
5290: 74 75 73 3c 2f 70 3e 0a 3c 64 6c 20 63 6c 61 73  tus</p>.<dl clas
52a0: 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 64 65 66 69  s="doctools_defi
52b0: 6e 69 74 69 6f 6e 73 22 3e 0a 3c 64 74 3e 3c 62  nitions">.<dt><b
52c0: 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65   class="variable
52d0: 22 3e 61 6c 70 6e 3c 2f 62 3e 20 3c 69 20 63 6c  ">alpn</b> <i cl
52e0: 61 73 73 3d 22 61 72 67 22 3e 70 72 6f 74 6f 63  ass="arg">protoc
52f0: 6f 6c 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  ol</i></dt>.<dd>
5300: 3c 70 3e 54 68 65 20 70 72 6f 74 6f 63 6f 6c 20  <p>The protocol 
5310: 73 65 6c 65 63 74 65 64 20 61 66 74 65 72 20 41  selected after A
5320: 70 70 6c 69 63 61 74 69 6f 6e 2d 4c 61 79 65 72  pplication-Layer
5330: 20 50 72 6f 74 6f 63 6f 6c 20 4e 65 67 6f 74 69   Protocol Negoti
5340: 61 74 69 6f 6e 20 28 41 4c 50 4e 29 2e 0a 54 68  ation (ALPN)..Th
5350: 69 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77 20  is value is new 
5360: 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c  for TclTLS 1.8.<
5370: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
5380: 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22  class="variable"
5390: 3e 63 69 70 68 65 72 3c 2f 62 3e 20 3c 69 20 63  >cipher</b> <i c
53a0: 6c 61 73 73 3d 22 61 72 67 22 3e 63 69 70 68 65  lass="arg">ciphe
53b0: 72 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c  r</i></dt>.<dd><
53c0: 70 3e 54 68 65 20 63 75 72 72 65 6e 74 20 63 69  p>The current ci
53d0: 70 68 65 72 20 69 6e 20 75 73 65 20 66 6f 72 20  pher in use for 
53e0: 74 68 65 20 73 65 73 73 69 6f 6e 2e 3c 2f 70 3e  the session.</p>
53f0: 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61  </dd>.<dt><b cla
5400: 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e 70 65  ss="variable">pe
5410: 65 72 6e 61 6d 65 3c 2f 62 3e 20 3c 69 20 63 6c  ername</b> <i cl
5420: 61 73 73 3d 22 61 72 67 22 3e 6e 61 6d 65 3c 2f  ass="arg">name</
5430: 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54  i></dt>.<dd><p>T
5440: 68 65 20 70 65 65 72 6e 61 6d 65 20 66 72 6f 6d  he peername from
5450: 20 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65   the certificate
5460: 2e 0a 54 68 69 73 20 76 61 6c 75 65 20 69 73 20  ..This value is 
5470: 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c 53 20 31  new for TclTLS 1
5480: 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  .8.</p></dd>.<dt
5490: 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61  ><b class="varia
54a0: 62 6c 65 22 3e 70 72 6f 74 6f 63 6f 6c 3c 2f 62  ble">protocol</b
54b0: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  > <i class="arg"
54c0: 3e 76 65 72 73 69 6f 6e 3c 2f 69 3e 3c 2f 64 74  >version</i></dt
54d0: 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 70 72 6f  >.<dd><p>The pro
54e0: 74 6f 63 6f 6c 20 76 65 72 73 69 6f 6e 20 75 73  tocol version us
54f0: 65 64 20 66 6f 72 20 74 68 65 20 63 6f 6e 6e 65  ed for the conne
5500: 63 74 69 6f 6e 3a 20 53 53 4c 32 2c 20 53 53 4c  ction: SSL2, SSL
5510: 33 2c 20 54 4c 53 31 2c 20 54 4c 53 31 2e 31 2c  3, TLS1, TLS1.1,
5520: 20 54 4c 53 31 2e 32 2c 0a 54 4c 53 31 2e 33 2c   TLS1.2,.TLS1.3,
5530: 20 6f 72 20 75 6e 6b 6e 6f 77 6e 2e 20 54 68 69   or unknown. Thi
5540: 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77 20 66  s value is new f
5550: 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f  or TclTLS 1.8.</
5560: 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63  p></dd>.<dt><b c
5570: 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e  lass="variable">
5580: 73 62 69 74 73 3c 2f 62 3e 20 3c 69 20 63 6c 61  sbits</b> <i cla
5590: 73 73 3d 22 61 72 67 22 3e 6e 3c 2f 69 3e 3c 2f  ss="arg">n</i></
55a0: 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 6e  dt>.<dd><p>The n
55b0: 75 6d 62 65 72 20 6f 66 20 62 69 74 73 20 75 73  umber of bits us
55c0: 65 64 20 66 6f 72 20 74 68 65 20 73 65 73 73 69  ed for the sessi
55d0: 6f 6e 20 6b 65 79 2e 3c 2f 70 3e 3c 2f 64 64 3e  on key.</p></dd>
55e0: 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 76  .<dt><b class="v
55f0: 61 72 69 61 62 6c 65 22 3e 73 69 67 6e 61 74 75  ariable">signatu
5600: 72 65 48 61 73 68 41 6c 67 6f 72 69 74 68 6d 3c  reHashAlgorithm<
5610: 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72  /b> <i class="ar
5620: 67 22 3e 61 6c 67 6f 72 69 74 68 6d 3c 2f 69 3e  g">algorithm</i>
5630: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65  </dt>.<dd><p>The
5640: 20 73 69 67 6e 61 74 75 72 65 20 68 61 73 68 20   signature hash 
5650: 61 6c 67 6f 72 69 74 68 6d 2e 0a 54 68 69 73 20  algorithm..This 
5660: 76 61 6c 75 65 20 69 73 20 6e 65 77 20 66 6f 72  value is new for
5670: 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e   TclTLS 1.8.</p>
5680: 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61  </dd>.<dt><b cla
5690: 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e 73 69  ss="variable">si
56a0: 67 6e 61 74 75 72 65 54 79 70 65 3c 2f 62 3e 20  gnatureType</b> 
56b0: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 74  <i class="arg">t
56c0: 79 70 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64  ype</i></dt>.<dd
56d0: 3e 3c 70 3e 54 68 65 20 73 69 67 6e 61 74 75 72  ><p>The signatur
56e0: 65 20 74 79 70 65 20 76 61 6c 75 65 2e 0a 54 68  e type value..Th
56f0: 69 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77 20  is value is new 
5700: 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c  for TclTLS 1.8.<
5710: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
5720: 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22  class="variable"
5730: 3e 76 65 72 69 66 79 44 65 70 74 68 3c 2f 62 3e  >verifyDepth</b>
5740: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
5750: 6e 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c  n</i></dt>.<dd><
5760: 70 3e 4d 61 78 69 6d 75 6d 20 64 65 70 74 68 20  p>Maximum depth 
5770: 66 6f 72 20 74 68 65 20 63 65 72 74 69 66 69 63  for the certific
5780: 61 74 65 20 63 68 61 69 6e 20 76 65 72 69 66 69  ate chain verifi
5790: 63 61 74 69 6f 6e 2e 20 44 65 66 61 75 6c 74 20  cation. Default 
57a0: 69 73 20 2d 31 2c 20 74 6f 20 63 68 65 63 6b 20  is -1, to check 
57b0: 61 6c 6c 2e 0a 54 68 69 73 20 76 61 6c 75 65 20  all..This value 
57c0: 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c  is new for TclTL
57d0: 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a  S 1.8.</p></dd>.
57e0: 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61  <dt><b class="va
57f0: 72 69 61 62 6c 65 22 3e 76 65 72 69 66 79 4d 6f  riable">verifyMo
5800: 64 65 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  de</b> <i class=
5810: 22 61 72 67 22 3e 6c 69 73 74 3c 2f 69 3e 3c 2f  "arg">list</i></
5820: 64 74 3e 0a 3c 64 64 3e 3c 70 3e 4c 69 73 74 20  dt>.<dd><p>List 
5830: 6f 66 20 63 65 72 74 69 66 69 63 61 74 65 20 76  of certificate v
5840: 65 72 69 66 69 63 61 74 69 6f 6e 20 6d 6f 64 65  erification mode
5850: 73 2e 0a 54 68 69 73 20 76 61 6c 75 65 20 69 73  s..This value is
5860: 20 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c 53 20   new for TclTLS 
5870: 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64  1.8.</p></dd>.<d
5880: 74 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69  t><b class="vari
5890: 61 62 6c 65 22 3e 76 65 72 69 66 79 52 65 73 75  able">verifyResu
58a0: 6c 74 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  lt</b> <i class=
58b0: 22 61 72 67 22 3e 72 65 73 75 6c 74 3c 2f 69 3e  "arg">result</i>
58c0: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 43 65 72  </dt>.<dd><p>Cer
58d0: 74 69 66 69 63 61 74 65 20 76 65 72 69 66 69 63  tificate verific
58e0: 61 74 69 6f 6e 20 72 65 73 75 6c 74 2e 0a 54 68  ation result..Th
58f0: 69 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77 20  is value is new 
5900: 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c  for TclTLS 1.8.<
5910: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
5920: 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22  class="variable"
5930: 3e 63 61 5f 6e 61 6d 65 73 3c 2f 62 3e 20 3c 69  >ca_names</b> <i
5940: 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 6c 69 73   class="arg">lis
5950: 74 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c  t</i></dt>.<dd><
5960: 70 3e 4c 69 73 74 20 6f 66 20 74 68 65 20 43 65  p>List of the Ce
5970: 72 74 69 66 69 63 61 74 65 20 41 75 74 68 6f 72  rtificate Author
5980: 69 74 69 65 73 20 75 73 65 64 20 74 6f 20 63 72  ities used to cr
5990: 65 61 74 65 20 74 68 65 20 63 65 72 74 69 66 69  eate the certifi
59a0: 63 61 74 65 2e 0a 54 68 69 73 20 76 61 6c 75 65  cate..This value
59b0: 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54   is new for TclT
59c0: 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e  LS 1.8.</p></dd>
59d0: 0a 3c 2f 64 6c 3e 0a 3c 70 3e 43 65 72 74 69 66  .</dl>.<p>Certif
59e0: 69 63 61 74 65 20 53 74 61 74 75 73 3c 2f 70 3e  icate Status</p>
59f0: 0a 3c 64 6c 20 63 6c 61 73 73 3d 22 64 6f 63 74  .<dl class="doct
5a00: 6f 6f 6c 73 5f 64 65 66 69 6e 69 74 69 6f 6e 73  ools_definitions
5a10: 22 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d  ">.<dt><b class=
5a20: 22 76 61 72 69 61 62 6c 65 22 3e 61 6c 6c 3c 2f  "variable">all</
5a30: 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67  b> <i class="arg
5a40: 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 3c 2f 64 74  ">string</i></dt
5a50: 3e 0a 3c 64 64 3e 3c 70 3e 44 75 6d 70 20 6f 66  >.<dd><p>Dump of
5a60: 20 61 6c 6c 20 63 65 72 74 69 66 69 63 61 74 65   all certificate
5a70: 20 69 6e 66 6f 2e 0a 54 68 69 73 20 76 61 6c 75   info..This valu
5a80: 65 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c  e is new for Tcl
5a90: 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64  TLS 1.8.</p></dd
5aa0: 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22  >.<dt><b class="
5ab0: 76 61 72 69 61 62 6c 65 22 3e 76 65 72 73 69 6f  variable">versio
5ac0: 6e 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22  n</b> <i class="
5ad0: 61 72 67 22 3e 76 61 6c 75 65 3c 2f 69 3e 3c 2f  arg">value</i></
5ae0: 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 63  dt>.<dd><p>The c
5af0: 65 72 74 69 66 69 63 61 74 65 20 76 65 72 73 69  ertificate versi
5b00: 6f 6e 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  on.</p></dd>.<dt
5b10: 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61  ><b class="varia
5b20: 62 6c 65 22 3e 73 65 72 69 61 6c 4e 75 6d 62 65  ble">serialNumbe
5b30: 72 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22  r</b> <i class="
5b40: 61 72 67 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 3c  arg">string</i><
5b50: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20  /dt>.<dd><p>The 
5b60: 73 65 72 69 61 6c 20 6e 75 6d 62 65 72 20 6f 66  serial number of
5b70: 20 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65   the certificate
5b80: 20 61 73 20 61 20 68 65 78 20 73 74 72 69 6e 67   as a hex string
5b90: 2e 0a 54 68 69 73 20 76 61 6c 75 65 20 77 61 73  ..This value was
5ba0: 20 63 68 61 6e 67 65 64 20 66 72 6f 6d 20 73 65   changed from se
5bb0: 72 69 61 6c 20 69 6e 20 54 63 6c 54 4c 53 20 31  rial in TclTLS 1
5bc0: 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  .8.</p></dd>.<dt
5bd0: 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61  ><b class="varia
5be0: 62 6c 65 22 3e 73 69 67 6e 61 74 75 72 65 3c 2f  ble">signature</
5bf0: 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67  b> <i class="arg
5c00: 22 3e 61 6c 67 6f 72 69 74 68 6d 3c 2f 69 3e 3c  ">algorithm</i><
5c10: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 43 69 70 68  /dt>.<dd><p>Ciph
5c20: 65 72 20 61 6c 67 6f 72 69 74 68 6d 20 75 73 65  er algorithm use
5c30: 64 20 66 6f 72 20 63 65 72 74 69 66 69 63 61 74  d for certificat
5c40: 65 20 73 69 67 6e 61 74 75 72 65 2e 0a 54 68 69  e signature..Thi
5c50: 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77 20 66  s value is new f
5c60: 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f  or TclTLS 1.8.</
5c70: 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63  p></dd>.<dt><b c
5c80: 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e  lass="variable">
5c90: 69 73 73 75 65 72 3c 2f 62 3e 20 3c 69 20 63 6c  issuer</b> <i cl
5ca0: 61 73 73 3d 22 61 72 67 22 3e 73 74 72 69 6e 67  ass="arg">string
5cb0: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
5cc0: 3e 54 68 65 20 64 69 73 74 69 6e 67 75 69 73 68  >The distinguish
5cd0: 65 64 20 6e 61 6d 65 20 28 44 4e 29 20 6f 66 20  ed name (DN) of 
5ce0: 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65 20  the certificate 
5cf0: 69 73 73 75 65 72 2e 3c 2f 70 3e 3c 2f 64 64 3e  issuer.</p></dd>
5d00: 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 76  .<dt><b class="v
5d10: 61 72 69 61 62 6c 65 22 3e 6e 6f 74 42 65 66 6f  ariable">notBefo
5d20: 72 65 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  re</b> <i class=
5d30: 22 61 72 67 22 3e 64 61 74 65 3c 2f 69 3e 3c 2f  "arg">date</i></
5d40: 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 62  dt>.<dd><p>The b
5d50: 65 67 69 6e 6e 69 6e 67 20 64 61 74 65 20 6f 66  eginning date of
5d60: 20 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65   the certificate
5d70: 20 76 61 6c 69 64 69 74 79 2e 3c 2f 70 3e 3c 2f   validity.</p></
5d80: 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73  dd>.<dt><b class
5d90: 3d 22 76 61 72 69 61 62 6c 65 22 3e 6e 6f 74 41  ="variable">notA
5da0: 66 74 65 72 3c 2f 62 3e 20 3c 69 20 63 6c 61 73  fter</b> <i clas
5db0: 73 3d 22 61 72 67 22 3e 64 61 74 65 3c 2f 69 3e  s="arg">date</i>
5dc0: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65  </dt>.<dd><p>The
5dd0: 20 65 78 70 69 72 61 74 69 6f 6e 20 64 61 74 65   expiration date
5de0: 20 6f 66 20 74 68 65 20 63 65 72 74 69 66 69 63   of the certific
5df0: 61 74 65 20 76 61 6c 69 64 69 74 79 2e 3c 2f 70  ate validity.</p
5e00: 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c  ></dd>.<dt><b cl
5e10: 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e 73  ass="variable">s
5e20: 75 62 6a 65 63 74 3c 2f 62 3e 20 3c 69 20 63 6c  ubject</b> <i cl
5e30: 61 73 73 3d 22 61 72 67 22 3e 73 74 72 69 6e 67  ass="arg">string
5e40: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
5e50: 3e 54 68 65 20 64 69 73 74 69 6e 67 75 69 73 68  >The distinguish
5e60: 65 64 20 6e 61 6d 65 20 28 44 4e 29 20 6f 66 20  ed name (DN) of 
5e70: 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65 20  the certificate 
5e80: 73 75 62 6a 65 63 74 2e 20 46 69 65 6c 64 73 20  subject. Fields 
5e90: 69 6e 63 6c 75 64 65 3a 20 43 6f 6d 6d 6f 6e 0a  include: Common.
5ea0: 4e 61 6d 65 20 28 43 4e 29 2c 20 4f 72 67 61 6e  Name (CN), Organ
5eb0: 69 7a 61 74 69 6f 6e 20 28 4f 29 2c 20 4c 6f 63  ization (O), Loc
5ec0: 61 6c 69 74 79 20 6f 72 20 43 69 74 79 20 28 4c  ality or City (L
5ed0: 29 2c 20 53 74 61 74 65 20 6f 72 20 50 72 6f 76  ), State or Prov
5ee0: 69 6e 63 65 20 28 53 29 2c 20 61 6e 64 0a 43 6f  ince (S), and.Co
5ef0: 75 6e 74 72 79 20 4e 61 6d 65 20 28 43 29 2e 3c  untry Name (C).<
5f00: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
5f10: 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22  class="variable"
5f20: 3e 69 73 73 75 65 72 55 6e 69 71 75 65 49 44 3c  >issuerUniqueID<
5f30: 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72  /b> <i class="ar
5f40: 67 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 3c 2f 64  g">string</i></d
5f50: 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 69 73  t>.<dd><p>The is
5f60: 73 75 65 72 20 75 6e 69 71 75 65 20 69 64 2e 0a  suer unique id..
5f70: 54 68 69 73 20 76 61 6c 75 65 20 69 73 20 6e 65  This value is ne
5f80: 77 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38  w for TclTLS 1.8
5f90: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
5fa0: 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c  b class="variabl
5fb0: 65 22 3e 73 75 62 6a 65 63 74 55 6e 69 71 75 65  e">subjectUnique
5fc0: 49 44 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  ID</b> <i class=
5fd0: 22 61 72 67 22 3e 73 74 72 69 6e 67 3c 2f 69 3e  "arg">string</i>
5fe0: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65  </dt>.<dd><p>The
5ff0: 20 73 75 62 6a 65 63 74 20 75 6e 69 71 75 65 20   subject unique 
6000: 69 64 2e 0a 54 68 69 73 20 76 61 6c 75 65 20 69  id..This value i
6010: 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c 53  s new for TclTLS
6020: 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c   1.8.</p></dd>.<
6030: 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72  dt><b class="var
6040: 69 61 62 6c 65 22 3e 6e 75 6d 5f 65 78 74 65 6e  iable">num_exten
6050: 73 69 6f 6e 73 3c 2f 62 3e 20 3c 69 20 63 6c 61  sions</b> <i cla
6060: 73 73 3d 22 61 72 67 22 3e 6e 3c 2f 69 3e 3c 2f  ss="arg">n</i></
6070: 64 74 3e 0a 3c 64 64 3e 3c 70 3e 4e 75 6d 62 65  dt>.<dd><p>Numbe
6080: 72 20 6f 66 20 63 65 72 74 69 66 69 63 61 74 65  r of certificate
6090: 20 65 78 74 65 6e 73 69 6f 6e 73 2e 0a 54 68 69   extensions..Thi
60a0: 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77 20 66  s value is new f
60b0: 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f  or TclTLS 1.8.</
60c0: 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63  p></dd>.<dt><b c
60d0: 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e  lass="variable">
60e0: 65 78 74 65 6e 73 69 6f 6e 73 3c 2f 62 3e 20 3c  extensions</b> <
60f0: 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 6c 69  i class="arg">li
6100: 73 74 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  st</i></dt>.<dd>
6110: 3c 70 3e 4c 69 73 74 20 6f 66 20 63 65 72 74 69  <p>List of certi
6120: 66 69 63 61 74 65 20 65 78 74 65 6e 73 69 6f 6e  ficate extension
6130: 20 6e 61 6d 65 73 2e 0a 54 68 69 73 20 76 61 6c   names..This val
6140: 75 65 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63  ue is new for Tc
6150: 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64  lTLS 1.8.</p></d
6160: 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d  d>.<dt><b class=
6170: 22 76 61 72 69 61 62 6c 65 22 3e 61 75 74 68 6f  "variable">autho
6180: 72 69 74 79 4b 65 79 49 64 65 6e 74 69 66 69 65  rityKeyIdentifie
6190: 72 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22  r</b> <i class="
61a0: 61 72 67 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 3c  arg">string</i><
61b0: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 41 75 74 68  /dt>.<dd><p>Auth
61c0: 6f 72 69 74 79 20 4b 65 79 20 49 64 65 6e 74 69  ority Key Identi
61d0: 66 69 65 72 20 28 41 4b 49 29 20 6f 66 20 74 68  fier (AKI) of th
61e0: 65 20 49 73 73 75 69 6e 67 20 43 41 20 63 65 72  e Issuing CA cer
61f0: 74 69 66 69 63 61 74 65 20 74 68 61 74 20 73 69  tificate that si
6200: 67 6e 65 64 20 74 68 65 0a 53 53 4c 20 63 65 72  gned the.SSL cer
6210: 74 69 66 69 63 61 74 65 20 61 73 20 61 20 68 65  tificate as a he
6220: 78 20 73 74 72 69 6e 67 2e 20 54 68 69 73 20 76  x string. This v
6230: 61 6c 75 65 20 6d 61 74 63 68 65 73 20 74 68 65  alue matches the
6240: 20 53 4b 49 20 76 61 6c 75 65 20 6f 66 20 74 68   SKI value of th
6250: 65 0a 49 6e 74 65 72 6d 65 64 69 61 74 65 20 43  e.Intermediate C
6260: 41 20 63 65 72 74 69 66 69 63 61 74 65 2e 0a 54  A certificate..T
6270: 68 69 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77  his value is new
6280: 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e   for TclTLS 1.8.
6290: 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62  </p></dd>.<dt><b
62a0: 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65   class="variable
62b0: 22 3e 73 75 62 6a 65 63 74 4b 65 79 49 64 65 6e  ">subjectKeyIden
62c0: 74 69 66 69 65 72 3c 2f 62 3e 20 3c 69 20 63 6c  tifier</b> <i cl
62d0: 61 73 73 3d 22 61 72 67 22 3e 73 74 72 69 6e 67  ass="arg">string
62e0: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
62f0: 3e 53 75 62 6a 65 63 74 20 4b 65 79 20 49 64 65  >Subject Key Ide
6300: 6e 74 69 66 69 65 72 20 28 53 4b 49 29 20 68 61  ntifier (SKI) ha
6310: 73 68 20 6f 66 20 74 68 65 20 70 75 62 6c 69 63  sh of the public
6320: 20 6b 65 79 20 69 6e 73 69 64 65 20 74 68 65 20   key inside the 
6330: 63 65 72 74 69 66 69 63 61 74 65 20 61 73 20 61  certificate as a
6340: 0a 68 65 78 20 73 74 72 69 6e 67 2e 20 55 73 65  .hex string. Use
6350: 64 20 74 6f 20 69 64 65 6e 74 69 66 79 20 63 65  d to identify ce
6360: 72 74 69 66 69 63 61 74 65 73 20 74 68 61 74 20  rtificates that 
6370: 63 6f 6e 74 61 69 6e 20 61 20 70 61 72 74 69 63  contain a partic
6380: 75 6c 61 72 20 70 75 62 6c 69 63 20 6b 65 79 2e  ular public key.
6390: 0a 54 68 69 73 20 76 61 6c 75 65 20 69 73 20 6e  .This value is n
63a0: 65 77 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e  ew for TclTLS 1.
63b0: 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  8.</p></dd>.<dt>
63c0: 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62  <b class="variab
63d0: 6c 65 22 3e 73 75 62 6a 65 63 74 41 6c 74 4e 61  le">subjectAltNa
63e0: 6d 65 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  me</b> <i class=
63f0: 22 61 72 67 22 3e 6c 69 73 74 3c 2f 69 3e 3c 2f  "arg">list</i></
6400: 64 74 3e 0a 3c 64 64 3e 3c 70 3e 4c 69 73 74 20  dt>.<dd><p>List 
6410: 6f 66 20 61 6c 6c 20 6f 66 20 74 68 65 20 53 75  of all of the Su
6420: 62 6a 65 63 74 20 41 6c 74 65 72 6e 61 74 69 76  bject Alternativ
6430: 65 20 4e 61 6d 65 73 20 28 53 41 4e 29 20 69 6e  e Names (SAN) in
6440: 63 6c 75 64 69 6e 67 20 64 6f 6d 61 69 6e 20 6e  cluding domain n
6450: 61 6d 65 73 2c 20 73 75 62 0a 64 6f 6d 61 69 6e  ames, sub.domain
6460: 73 2c 20 61 6e 64 20 49 50 20 61 64 64 72 65 73  s, and IP addres
6470: 73 65 73 20 74 68 61 74 20 61 72 65 20 73 65 63  ses that are sec
6480: 75 72 65 64 20 62 79 20 74 68 65 20 63 65 72 74  ured by the cert
6490: 69 66 69 63 61 74 65 2e 0a 54 68 69 73 20 76 61  ificate..This va
64a0: 6c 75 65 20 69 73 20 6e 65 77 20 66 6f 72 20 54  lue is new for T
64b0: 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f  clTLS 1.8.</p></
64c0: 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73  dd>.<dt><b class
64d0: 3d 22 76 61 72 69 61 62 6c 65 22 3e 6f 63 73 70  ="variable">ocsp
64e0: 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61  </b> <i class="a
64f0: 72 67 22 3e 6c 69 73 74 3c 2f 69 3e 3c 2f 64 74  rg">list</i></dt
6500: 3e 0a 3c 64 64 3e 3c 70 3e 4c 69 73 74 20 6f 66  >.<dd><p>List of
6510: 20 61 6c 6c 20 4f 6e 6c 69 6e 65 20 43 65 72 74   all Online Cert
6520: 69 66 69 63 61 74 65 20 53 74 61 74 75 73 20 50  ificate Status P
6530: 72 6f 74 6f 63 6f 6c 20 28 4f 43 53 50 29 20 55  rotocol (OCSP) U
6540: 52 4c 73 20 74 68 61 74 20 63 61 6e 20 62 65 20  RLs that can be 
6550: 75 73 65 64 20 74 6f 0a 63 68 65 63 6b 20 74 68  used to.check th
6560: 65 20 76 61 6c 69 64 69 74 79 20 6f 66 20 74 68  e validity of th
6570: 69 73 20 63 65 72 74 69 66 69 63 61 74 65 2e 0a  is certificate..
6580: 54 68 69 73 20 76 61 6c 75 65 20 69 73 20 6e 65  This value is ne
6590: 77 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38  w for TclTLS 1.8
65a0: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
65b0: 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c  b class="variabl
65c0: 65 22 3e 63 65 72 74 69 66 69 63 61 74 65 3c 2f  e">certificate</
65d0: 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67  b> <i class="arg
65e0: 22 3e 63 65 72 74 3c 2f 69 3e 3c 2f 64 74 3e 0a  ">cert</i></dt>.
65f0: 3c 64 64 3e 3c 70 3e 54 68 65 20 50 45 4d 20 65  <dd><p>The PEM e
6600: 6e 63 6f 64 65 64 20 63 65 72 74 69 66 69 63 61  ncoded certifica
6610: 74 65 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  te.</p></dd>.<dt
6620: 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61  ><b class="varia
6630: 62 6c 65 22 3e 73 69 67 6e 61 74 75 72 65 41 6c  ble">signatureAl
6640: 67 6f 72 69 74 68 6d 3c 2f 62 3e 20 3c 69 20 63  gorithm</b> <i c
6650: 6c 61 73 73 3d 22 61 72 67 22 3e 61 6c 67 6f 72  lass="arg">algor
6660: 69 74 68 6d 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64  ithm</i></dt>.<d
6670: 64 3e 3c 70 3e 43 69 70 68 65 72 20 61 6c 67 6f  d><p>Cipher algo
6680: 72 69 74 68 6d 20 75 73 65 64 20 66 6f 72 20 74  rithm used for t
6690: 68 65 20 63 65 72 74 69 66 69 63 61 74 65 20 73  he certificate s
66a0: 69 67 6e 61 74 75 72 65 2e 0a 54 68 69 73 20 76  ignature..This v
66b0: 61 6c 75 65 20 69 73 20 6e 65 77 20 66 6f 72 20  alue is new for 
66c0: 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c  TclTLS 1.8.</p><
66d0: 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73  /dd>.<dt><b clas
66e0: 73 3d 22 76 61 72 69 61 62 6c 65 22 3e 73 69 67  s="variable">sig
66f0: 6e 61 74 75 72 65 56 61 6c 75 65 3c 2f 62 3e 20  natureValue</b> 
6700: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 73  <i class="arg">s
6710: 74 72 69 6e 67 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c  tring</i></dt>.<
6720: 64 64 3e 3c 70 3e 43 65 72 74 69 66 69 63 61 74  dd><p>Certificat
6730: 65 20 73 69 67 6e 61 74 75 72 65 20 61 73 20 61  e signature as a
6740: 20 68 65 78 20 73 74 72 69 6e 67 2e 0a 54 68 69   hex string..Thi
6750: 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77 20 66  s value is new f
6760: 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f  or TclTLS 1.8.</
6770: 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63  p></dd>.<dt><b c
6780: 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e  lass="variable">
6790: 73 69 67 6e 61 74 75 72 65 44 69 67 65 73 74 3c  signatureDigest<
67a0: 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72  /b> <i class="ar
67b0: 67 22 3e 76 65 72 73 69 6f 6e 3c 2f 69 3e 3c 2f  g">version</i></
67c0: 64 74 3e 0a 3c 64 64 3e 3c 70 3e 43 65 72 74 69  dt>.<dd><p>Certi
67d0: 66 69 63 61 74 65 20 73 69 67 6e 69 6e 67 20 64  ficate signing d
67e0: 69 67 65 73 74 20 61 73 20 61 20 68 65 78 20 73  igest as a hex s
67f0: 74 72 69 6e 67 2e 0a 54 68 69 73 20 76 61 6c 75  tring..This valu
6800: 65 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c  e is new for Tcl
6810: 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64  TLS 1.8.</p></dd
6820: 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22  >.<dt><b class="
6830: 76 61 72 69 61 62 6c 65 22 3e 70 75 62 6c 69 63  variable">public
6840: 4b 65 79 41 6c 67 6f 72 69 74 68 6d 3c 2f 62 3e  KeyAlgorithm</b>
6850: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
6860: 61 6c 67 6f 72 69 74 68 6d 3c 2f 69 3e 3c 2f 64  algorithm</i></d
6870: 74 3e 0a 3c 64 64 3e 3c 70 3e 43 65 72 74 69 66  t>.<dd><p>Certif
6880: 69 63 61 74 65 20 73 69 67 6e 61 74 75 72 65 20  icate signature 
6890: 70 75 62 6c 69 63 20 6b 65 79 20 61 6c 67 6f 72  public key algor
68a0: 69 74 68 6d 2e 0a 54 68 69 73 20 76 61 6c 75 65  ithm..This value
68b0: 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54   is new for TclT
68c0: 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e  LS 1.8.</p></dd>
68d0: 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 76  .<dt><b class="v
68e0: 61 72 69 61 62 6c 65 22 3e 70 75 62 6c 69 63 4b  ariable">publicK
68f0: 65 79 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  ey</b> <i class=
6900: 22 61 72 67 22 3e 73 74 72 69 6e 67 3c 2f 69 3e  "arg">string</i>
6910: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 43 65 72  </dt>.<dd><p>Cer
6920: 74 69 66 69 63 61 74 65 20 73 69 67 6e 61 74 75  tificate signatu
6930: 72 65 20 70 75 62 6c 69 63 20 6b 65 79 20 61 73  re public key as
6940: 20 61 20 68 65 78 20 73 74 72 69 6e 67 2e 0a 54   a hex string..T
6950: 68 69 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77  his value is new
6960: 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e   for TclTLS 1.8.
6970: 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62  </p></dd>.<dt><b
6980: 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65   class="variable
6990: 22 3e 62 69 74 73 3c 2f 62 3e 20 3c 69 20 63 6c  ">bits</b> <i cl
69a0: 61 73 73 3d 22 61 72 67 22 3e 6e 3c 2f 69 3e 3c  ass="arg">n</i><
69b0: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 4e 75 6d 62  /dt>.<dd><p>Numb
69c0: 65 72 20 6f 66 20 62 69 74 73 20 75 73 65 64 20  er of bits used 
69d0: 66 6f 72 20 63 65 72 74 69 66 69 63 61 74 65 20  for certificate 
69e0: 73 69 67 6e 61 74 75 72 65 20 6b 65 79 2e 0a 54  signature key..T
69f0: 68 69 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77  his value is new
6a00: 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e   for TclTLS 1.8.
6a10: 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62  </p></dd>.<dt><b
6a20: 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65   class="variable
6a30: 22 3e 73 65 6c 66 5f 73 69 67 6e 65 64 3c 2f 62  ">self_signed</b
6a40: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  > <i class="arg"
6a50: 3e 62 6f 6f 6c 65 61 6e 3c 2f 69 3e 3c 2f 64 74  >boolean</i></dt
6a60: 3e 0a 3c 64 64 3e 3c 70 3e 57 68 65 74 68 65 72  >.<dd><p>Whether
6a70: 20 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65   the certificate
6a80: 20 73 69 67 6e 61 74 75 72 65 20 69 73 20 73 65   signature is se
6a90: 6c 66 20 73 69 67 6e 65 64 2e 0a 54 68 69 73 20  lf signed..This 
6aa0: 76 61 6c 75 65 20 69 73 20 6e 65 77 20 66 6f 72  value is new for
6ab0: 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e   TclTLS 1.8.</p>
6ac0: 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61  </dd>.<dt><b cla
6ad0: 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e 73 68  ss="variable">sh
6ae0: 61 31 5f 68 61 73 68 3c 2f 62 3e 20 3c 69 20 63  a1_hash</b> <i c
6af0: 6c 61 73 73 3d 22 61 72 67 22 3e 68 61 73 68 3c  lass="arg">hash<
6b00: 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e  /i></dt>.<dd><p>
6b10: 54 68 65 20 53 48 41 31 20 68 61 73 68 20 6f 66  The SHA1 hash of
6b20: 20 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65   the certificate
6b30: 20 61 73 20 61 20 68 65 78 20 73 74 72 69 6e 67   as a hex string
6b40: 2e 0a 54 68 69 73 20 76 61 6c 75 65 20 69 73 20  ..This value is 
6b50: 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c 53 20 31  new for TclTLS 1
6b60: 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  .8.</p></dd>.<dt
6b70: 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61  ><b class="varia
6b80: 62 6c 65 22 3e 73 68 61 32 35 36 5f 68 61 73 68  ble">sha256_hash
6b90: 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61  </b> <i class="a
6ba0: 72 67 22 3e 68 61 73 68 3c 2f 69 3e 3c 2f 64 74  rg">hash</i></dt
6bb0: 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 53 48 41  >.<dd><p>The SHA
6bc0: 32 35 36 20 68 61 73 68 20 6f 66 20 74 68 65 20  256 hash of the 
6bd0: 63 65 72 74 69 66 69 63 61 74 65 20 61 73 20 61  certificate as a
6be0: 20 68 65 78 20 73 74 72 69 6e 67 2e 0a 54 68 69   hex string..Thi
6bf0: 73 20 76 61 6c 75 65 20 69 73 20 6e 65 77 20 66  s value is new f
6c00: 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f  or TclTLS 1.8.</
6c10: 70 3e 3c 2f 64 64 3e 0a 3c 2f 64 6c 3e 3c 2f 64  p></dd>.</dl></d
6c20: 64 3e 0a 3c 64 74 3e 3c 61 20 6e 61 6d 65 3d 22  d>.<dt><a name="
6c30: 38 22 3e 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64  8"><b class="cmd
6c40: 22 3e 74 6c 73 3a 3a 63 6f 6e 6e 65 63 74 69 6f  ">tls::connectio
6c50: 6e 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22  n</b> <i class="
6c60: 61 72 67 22 3e 63 68 61 6e 6e 65 6c 3c 2f 69 3e  arg">channel</i>
6c70: 3c 2f 61 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </a></dt>.<dd><p
6c80: 3e 52 65 74 75 72 6e 73 20 74 68 65 20 63 75 72  >Returns the cur
6c90: 72 65 6e 74 20 63 6f 6e 6e 65 63 74 69 6f 6e 20  rent connection 
6ca0: 73 74 61 74 75 73 20 6f 66 20 61 6e 20 53 53 4c  status of an SSL
6cb0: 20 63 68 61 6e 6e 65 6c 2e 20 54 68 65 20 72 65   channel. The re
6cc0: 73 75 6c 74 20 69 73 20 61 20 6c 69 73 74 0a 6f  sult is a list.o
6cd0: 66 20 6b 65 79 2d 76 61 6c 75 65 20 70 61 69 72  f key-value pair
6ce0: 73 20 64 65 73 63 72 69 62 69 6e 67 20 74 68 65  s describing the
6cf0: 20 63 6f 6e 6e 65 63 74 69 6f 6e 2e 0a 54 68 69   connection..Thi
6d00: 73 20 63 6f 6d 6d 61 6e 64 20 69 73 20 6e 65 77  s command is new
6d10: 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e   for TclTLS 1.8.
6d20: 20 52 65 74 75 72 6e 65 64 20 76 61 6c 75 65 73   Returned values
6d30: 20 69 6e 63 6c 75 64 65 3a 3c 2f 70 3e 0a 3c 70   include:</p>.<p
6d40: 3e 53 53 4c 20 53 74 61 74 75 73 3c 2f 70 3e 0a  >SSL Status</p>.
6d50: 3c 64 6c 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f  <dl class="docto
6d60: 6f 6c 73 5f 64 65 66 69 6e 69 74 69 6f 6e 73 22  ols_definitions"
6d70: 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22  >.<dt><b class="
6d80: 76 61 72 69 61 62 6c 65 22 3e 73 74 61 74 65 3c  variable">state<
6d90: 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72  /b> <i class="ar
6da0: 67 22 3e 73 74 61 74 65 3c 2f 69 3e 3c 2f 64 74  g">state</i></dt
6db0: 3e 0a 3c 64 64 3e 3c 70 3e 53 74 61 74 65 20 6f  >.<dd><p>State o
6dc0: 66 20 74 68 65 20 63 6f 6e 6e 65 63 74 69 6f 6e  f the connection
6dd0: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
6de0: 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c  b class="variabl
6df0: 65 22 3e 73 65 72 76 65 72 6e 61 6d 65 3c 2f 62  e">servername</b
6e00: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  > <i class="arg"
6e10: 3e 6e 61 6d 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c  >name</i></dt>.<
6e20: 64 64 3e 3c 70 3e 54 68 65 20 6e 61 6d 65 20 6f  dd><p>The name o
6e30: 66 20 74 68 65 20 63 6f 6e 6e 65 63 74 65 64 20  f the connected 
6e40: 74 6f 20 73 65 72 76 65 72 2e 3c 2f 70 3e 3c 2f  to server.</p></
6e50: 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73  dd>.<dt><b class
6e60: 3d 22 76 61 72 69 61 62 6c 65 22 3e 70 72 6f 74  ="variable">prot
6e70: 6f 63 6f 6c 3c 2f 62 3e 20 3c 69 20 63 6c 61 73  ocol</b> <i clas
6e80: 73 3d 22 61 72 67 22 3e 76 65 72 73 69 6f 6e 3c  s="arg">version<
6e90: 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e  /i></dt>.<dd><p>
6ea0: 54 68 65 20 70 72 6f 74 6f 63 6f 6c 20 76 65 72  The protocol ver
6eb0: 73 69 6f 6e 20 75 73 65 64 20 66 6f 72 20 74 68  sion used for th
6ec0: 65 20 63 6f 6e 6e 65 63 74 69 6f 6e 3a 20 53 53  e connection: SS
6ed0: 4c 32 2c 20 53 53 4c 33 2c 20 54 4c 53 31 2c 20  L2, SSL3, TLS1, 
6ee0: 54 4c 53 31 2e 31 2c 20 54 4c 53 31 2e 32 2c 20  TLS1.1, TLS1.2, 
6ef0: 54 4c 53 31 2e 33 2c 20 6f 72 20 75 6e 6b 6e 6f  TLS1.3, or unkno
6f00: 77 6e 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  wn.</p></dd>.<dt
6f10: 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61  ><b class="varia
6f20: 62 6c 65 22 3e 72 65 6e 65 67 6f 74 69 61 74 69  ble">renegotiati
6f30: 6f 6e 5f 61 6c 6c 6f 77 65 64 3c 2f 62 3e 20 3c  on_allowed</b> <
6f40: 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 62 6f  i class="arg">bo
6f50: 6f 6c 65 61 6e 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c  olean</i></dt>.<
6f60: 64 64 3e 3c 70 3e 57 68 65 74 68 65 72 20 70 72  dd><p>Whether pr
6f70: 6f 74 6f 63 6f 6c 20 72 65 6e 65 67 6f 74 69 61  otocol renegotia
6f80: 74 69 6f 6e 20 69 73 20 73 75 70 70 6f 72 74 65  tion is supporte
6f90: 64 20 6f 72 20 6e 6f 74 2e 3c 2f 70 3e 3c 2f 64  d or not.</p></d
6fa0: 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d  d>.<dt><b class=
6fb0: 22 76 61 72 69 61 62 6c 65 22 3e 73 65 63 75 72  "variable">secur
6fc0: 69 74 79 5f 6c 65 76 65 6c 3c 2f 62 3e 20 3c 69  ity_level</b> <i
6fd0: 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 6c 65 76   class="arg">lev
6fe0: 65 6c 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  el</i></dt>.<dd>
6ff0: 3c 70 3e 54 68 65 20 73 65 63 75 72 69 74 79 20  <p>The security 
7000: 6c 65 76 65 6c 20 75 73 65 64 20 66 6f 72 20 73  level used for s
7010: 65 6c 65 63 74 69 6f 6e 20 6f 66 20 63 69 70 68  election of ciph
7020: 65 72 73 2c 20 6b 65 79 20 73 69 7a 65 2c 20 65  ers, key size, e
7030: 74 63 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  tc.</p></dd>.<dt
7040: 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61  ><b class="varia
7050: 62 6c 65 22 3e 73 65 73 73 69 6f 6e 5f 72 65 75  ble">session_reu
7060: 73 65 64 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73  sed</b> <i class
7070: 3d 22 61 72 67 22 3e 62 6f 6f 6c 65 61 6e 3c 2f  ="arg">boolean</
7080: 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 57  i></dt>.<dd><p>W
7090: 68 65 74 68 65 72 20 74 68 65 20 73 65 73 73 69  hether the sessi
70a0: 6f 6e 20 68 61 73 20 62 65 65 6e 20 72 65 75 73  on has been reus
70b0: 65 64 20 6f 72 20 6e 6f 74 2e 3c 2f 70 3e 3c 2f  ed or not.</p></
70c0: 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73  dd>.<dt><b class
70d0: 3d 22 76 61 72 69 61 62 6c 65 22 3e 69 73 5f 73  ="variable">is_s
70e0: 65 72 76 65 72 3c 2f 62 3e 20 3c 69 20 63 6c 61  erver</b> <i cla
70f0: 73 73 3d 22 61 72 67 22 3e 62 6f 6f 6c 65 61 6e  ss="arg">boolean
7100: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
7110: 3e 57 68 65 74 68 65 72 20 74 68 65 20 63 6f 6e  >Whether the con
7120: 6e 65 63 74 69 6f 6e 20 69 73 20 63 6f 6e 66 69  nection is confi
7130: 67 75 72 65 64 20 61 73 20 61 20 73 65 72 76 65  gured as a serve
7140: 72 20 28 31 29 20 6f 72 20 63 6c 69 65 6e 74 20  r (1) or client 
7150: 28 30 29 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64  (0).</p></dd>.<d
7160: 74 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69  t><b class="vari
7170: 61 62 6c 65 22 3e 63 6f 6d 70 72 65 73 73 69 6f  able">compressio
7180: 6e 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22  n</b> <i class="
7190: 61 72 67 22 3e 6d 6f 64 65 3c 2f 69 3e 3c 2f 64  arg">mode</i></d
71a0: 74 3e 0a 3c 64 64 3e 3c 70 3e 43 6f 6d 70 72 65  t>.<dd><p>Compre
71b0: 73 73 69 6f 6e 20 6d 65 74 68 6f 64 2e 3c 2f 70  ssion method.</p
71c0: 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c  ></dd>.<dt><b cl
71d0: 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e 65  ass="variable">e
71e0: 78 70 61 6e 73 69 6f 6e 3c 2f 62 3e 20 3c 69 20  xpansion</b> <i 
71f0: 63 6c 61 73 73 3d 22 61 72 67 22 3e 6d 6f 64 65  class="arg">mode
7200: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
7210: 3e 45 78 70 61 6e 73 69 6f 6e 20 6d 65 74 68 6f  >Expansion metho
7220: 64 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  d.</p></dd>.<dt>
7230: 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62  <b class="variab
7240: 6c 65 22 3e 63 61 4c 69 73 74 3c 2f 62 3e 20 3c  le">caList</b> <
7250: 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 6c 69  i class="arg">li
7260: 73 74 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  st</i></dt>.<dd>
7270: 3c 70 3e 4c 69 73 74 20 6f 66 20 43 65 72 74 69  <p>List of Certi
7280: 66 69 63 61 74 65 20 41 75 74 68 6f 72 69 74 69  ficate Authoriti
7290: 65 73 20 28 43 41 29 20 66 6f 72 20 58 2e 35 30  es (CA) for X.50
72a0: 39 20 63 65 72 74 69 66 69 63 61 74 65 2e 3c 2f  9 certificate.</
72b0: 70 3e 3c 2f 64 64 3e 0a 3c 2f 64 6c 3e 0a 3c 70  p></dd>.</dl>.<p
72c0: 3e 43 69 70 68 65 72 20 49 6e 66 6f 3c 2f 70 3e  >Cipher Info</p>
72d0: 0a 3c 64 6c 20 63 6c 61 73 73 3d 22 64 6f 63 74  .<dl class="doct
72e0: 6f 6f 6c 73 5f 64 65 66 69 6e 69 74 69 6f 6e 73  ools_definitions
72f0: 22 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d  ">.<dt><b class=
7300: 22 76 61 72 69 61 62 6c 65 22 3e 63 69 70 68 65  "variable">ciphe
7310: 72 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22  r</b> <i class="
7320: 61 72 67 22 3e 63 69 70 68 65 72 3c 2f 69 3e 3c  arg">cipher</i><
7330: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20  /dt>.<dd><p>The 
7340: 63 75 72 72 65 6e 74 20 63 69 70 68 65 72 20 69  current cipher i
7350: 6e 20 75 73 65 20 66 6f 72 20 74 68 65 20 63 6f  n use for the co
7360: 6e 6e 65 63 74 69 6f 6e 2e 3c 2f 70 3e 3c 2f 64  nnection.</p></d
7370: 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d  d>.<dt><b class=
7380: 22 76 61 72 69 61 62 6c 65 22 3e 73 74 61 6e 64  "variable">stand
7390: 61 72 64 5f 6e 61 6d 65 3c 2f 62 3e 20 3c 69 20  ard_name</b> <i 
73a0: 63 6c 61 73 73 3d 22 61 72 67 22 3e 6e 61 6d 65  class="arg">name
73b0: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
73c0: 3e 54 68 65 20 73 74 61 6e 64 61 72 64 20 52 46  >The standard RF
73d0: 43 20 6e 61 6d 65 20 6f 66 20 63 69 70 68 65 72  C name of cipher
73e0: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
73f0: 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c  b class="variabl
7400: 65 22 3e 61 6c 67 6f 72 69 74 68 6d 5f 62 69 74  e">algorithm_bit
7410: 73 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22  s</b> <i class="
7420: 61 72 67 22 3e 6e 3c 2f 69 3e 3c 2f 64 74 3e 0a  arg">n</i></dt>.
7430: 3c 64 64 3e 3c 70 3e 54 68 65 20 6e 75 6d 62 65  <dd><p>The numbe
7440: 72 20 6f 66 20 70 72 6f 63 65 73 73 65 64 20 62  r of processed b
7450: 69 74 73 20 75 73 65 64 20 66 6f 72 20 63 69 70  its used for cip
7460: 68 65 72 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64  her.</p></dd>.<d
7470: 74 3e 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69  t><b class="vari
7480: 61 62 6c 65 22 3e 73 65 63 72 65 74 5f 62 69 74  able">secret_bit
7490: 73 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22  s</b> <i class="
74a0: 61 72 67 22 3e 6e 3c 2f 69 3e 3c 2f 64 74 3e 0a  arg">n</i></dt>.
74b0: 3c 64 64 3e 3c 70 3e 54 68 65 20 6e 75 6d 62 65  <dd><p>The numbe
74c0: 72 20 6f 66 20 73 65 63 72 65 74 20 62 69 74 73  r of secret bits
74d0: 20 75 73 65 64 20 66 6f 72 20 63 69 70 68 65 72   used for cipher
74e0: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
74f0: 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c  b class="variabl
7500: 65 22 3e 6d 69 6e 5f 76 65 72 73 69 6f 6e 3c 2f  e">min_version</
7510: 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67  b> <i class="arg
7520: 22 3e 76 65 72 73 69 6f 6e 3c 2f 69 3e 3c 2f 64  ">version</i></d
7530: 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 6d 69  t>.<dd><p>The mi
7540: 6e 69 6d 75 6d 20 70 72 6f 74 6f 63 6f 6c 20 76  nimum protocol v
7550: 65 72 73 69 6f 6e 20 66 6f 72 20 63 69 70 68 65  ersion for ciphe
7560: 72 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  r.</p></dd>.<dt>
7570: 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62  <b class="variab
7580: 6c 65 22 3e 63 69 70 68 65 72 5f 69 73 5f 61 65  le">cipher_is_ae
7590: 61 64 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  ad</b> <i class=
75a0: 22 61 72 67 22 3e 62 6f 6f 6c 65 61 6e 3c 2f 69  "arg">boolean</i
75b0: 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 57 68  ></dt>.<dd><p>Wh
75c0: 65 74 68 65 72 20 74 68 65 20 63 69 70 68 65 72  ether the cipher
75d0: 20 69 73 20 41 75 74 68 65 6e 74 69 63 61 74 65   is Authenticate
75e0: 64 20 45 6e 63 72 79 70 74 69 6f 6e 20 77 69 74  d Encryption wit
75f0: 68 20 41 73 73 6f 63 69 61 74 65 64 20 44 61 74  h Associated Dat
7600: 61 20 28 41 45 41 44 29 2e 3c 2f 70 3e 3c 2f 64  a (AEAD).</p></d
7610: 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d  d>.<dt><b class=
7620: 22 76 61 72 69 61 62 6c 65 22 3e 63 69 70 68 65  "variable">ciphe
7630: 72 5f 69 64 3c 2f 62 3e 20 3c 69 20 63 6c 61 73  r_id</b> <i clas
7640: 73 3d 22 61 72 67 22 3e 69 64 3c 2f 69 3e 3c 2f  s="arg">id</i></
7650: 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 4f  dt>.<dd><p>The O
7660: 70 65 6e 53 53 4c 20 63 69 70 68 65 72 20 69 64  penSSL cipher id
7670: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
7680: 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c  b class="variabl
7690: 65 22 3e 64 65 73 63 72 69 70 74 69 6f 6e 3c 2f  e">description</
76a0: 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67  b> <i class="arg
76b0: 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 3c 2f 64 74  ">string</i></dt
76c0: 3e 0a 3c 64 64 3e 3c 70 3e 41 20 74 65 78 74 20  >.<dd><p>A text 
76d0: 64 65 73 63 72 69 70 74 69 6f 6e 20 6f 66 20 74  description of t
76e0: 68 65 20 63 69 70 68 65 72 2e 3c 2f 70 3e 3c 2f  he cipher.</p></
76f0: 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73  dd>.<dt><b class
7700: 3d 22 76 61 72 69 61 62 6c 65 22 3e 68 61 6e 64  ="variable">hand
7710: 73 68 61 6b 65 5f 64 69 67 65 73 74 3c 2f 62 3e  shake_digest</b>
7720: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
7730: 62 6f 6f 6c 65 61 6e 3c 2f 69 3e 3c 2f 64 74 3e  boolean</i></dt>
7740: 0a 3c 64 64 3e 3c 70 3e 44 69 67 65 73 74 20 75  .<dd><p>Digest u
7750: 73 65 64 20 64 75 72 69 6e 67 20 68 61 6e 64 73  sed during hands
7760: 68 61 6b 65 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c  hake.</p></dd>.<
7770: 2f 64 6c 3e 0a 3c 70 3e 53 65 73 73 69 6f 6e 20  /dl>.<p>Session 
7780: 49 6e 66 6f 3c 2f 70 3e 0a 3c 64 6c 20 63 6c 61  Info</p>.<dl cla
7790: 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 64 65 66  ss="doctools_def
77a0: 69 6e 69 74 69 6f 6e 73 22 3e 0a 3c 64 74 3e 3c  initions">.<dt><
77b0: 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c  b class="variabl
77c0: 65 22 3e 61 6c 70 6e 3c 2f 62 3e 20 3c 69 20 63  e">alpn</b> <i c
77d0: 6c 61 73 73 3d 22 61 72 67 22 3e 70 72 6f 74 6f  lass="arg">proto
77e0: 63 6f 6c 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64  col</i></dt>.<dd
77f0: 3e 3c 70 3e 54 68 65 20 70 72 6f 74 6f 63 6f 6c  ><p>The protocol
7800: 20 73 65 6c 65 63 74 65 64 20 61 66 74 65 72 20   selected after 
7810: 41 70 70 6c 69 63 61 74 69 6f 6e 2d 4c 61 79 65  Application-Laye
7820: 72 20 50 72 6f 74 6f 63 6f 6c 20 4e 65 67 6f 74  r Protocol Negot
7830: 69 61 74 69 6f 6e 20 28 41 4c 50 4e 29 2e 3c 2f  iation (ALPN).</
7840: 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63  p></dd>.<dt><b c
7850: 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e  lass="variable">
7860: 72 65 73 75 6d 61 62 6c 65 3c 2f 62 3e 20 3c 69  resumable</b> <i
7870: 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 62 6f 6f   class="arg">boo
7880: 6c 65 61 6e 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64  lean</i></dt>.<d
7890: 64 3e 3c 70 3e 57 68 65 74 68 65 72 20 74 68 65  d><p>Whether the
78a0: 20 73 65 73 73 69 6f 6e 20 63 61 6e 20 62 65 20   session can be 
78b0: 72 65 73 75 6d 65 64 20 6f 72 20 6e 6f 74 2e 3c  resumed or not.<
78c0: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
78d0: 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22  class="variable"
78e0: 3e 73 74 61 72 74 5f 74 69 6d 65 3c 2f 62 3e 20  >start_time</b> 
78f0: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 73  <i class="arg">s
7900: 65 63 6f 6e 64 73 3c 2f 69 3e 3c 2f 64 74 3e 0a  econds</i></dt>.
7910: 3c 64 64 3e 3c 70 3e 54 69 6d 65 20 73 69 6e 63  <dd><p>Time sinc
7920: 65 20 73 65 73 73 69 6f 6e 20 73 74 61 72 74 65  e session starte
7930: 64 20 69 6e 20 73 65 63 6f 6e 64 73 20 73 69 6e  d in seconds sin
7940: 63 65 20 65 70 6f 63 68 2e 3c 2f 70 3e 3c 2f 64  ce epoch.</p></d
7950: 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d  d>.<dt><b class=
7960: 22 76 61 72 69 61 62 6c 65 22 3e 74 69 6d 65 6f  "variable">timeo
7970: 75 74 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  ut</b> <i class=
7980: 22 61 72 67 22 3e 73 65 63 6f 6e 64 73 3c 2f 69  "arg">seconds</i
7990: 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 4d 61  ></dt>.<dd><p>Ma
79a0: 78 20 64 75 72 61 74 69 6f 6e 20 6f 66 20 73 65  x duration of se
79b0: 73 73 69 6f 6e 20 69 6e 20 73 65 63 6f 6e 64 73  ssion in seconds
79c0: 20 62 65 66 6f 72 65 20 74 69 6d 65 2d 6f 75 74   before time-out
79d0: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
79e0: 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c  b class="variabl
79f0: 65 22 3e 6c 69 66 65 74 69 6d 65 3c 2f 62 3e 20  e">lifetime</b> 
7a00: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 73  <i class="arg">s
7a10: 65 63 6f 6e 64 73 3c 2f 69 3e 3c 2f 64 74 3e 0a  econds</i></dt>.
7a20: 3c 64 64 3e 3c 70 3e 53 65 73 73 69 6f 6e 20 74  <dd><p>Session t
7a30: 69 63 6b 65 74 20 6c 69 66 65 74 69 6d 65 20 68  icket lifetime h
7a40: 69 6e 74 20 69 6e 20 73 65 63 6f 6e 64 73 2e 3c  int in seconds.<
7a50: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
7a60: 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22  class="variable"
7a70: 3e 73 65 73 73 69 6f 6e 5f 69 64 3c 2f 62 3e 20  >session_id</b> 
7a80: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 62  <i class="arg">b
7a90: 69 6e 61 72 79 5f 73 74 72 69 6e 67 3c 2f 69 3e  inary_string</i>
7aa0: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 55 6e 69  </dt>.<dd><p>Uni
7ab0: 71 75 65 20 73 65 73 73 69 6f 6e 20 69 64 20 66  que session id f
7ac0: 6f 72 20 75 73 65 20 69 6e 20 72 65 73 75 6d 69  or use in resumi
7ad0: 6e 67 20 74 68 65 20 73 65 73 73 69 6f 6e 2e 3c  ng the session.<
7ae0: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
7af0: 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22  class="variable"
7b00: 3e 73 65 73 73 69 6f 6e 5f 74 69 63 6b 65 74 3c  >session_ticket<
7b10: 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72  /b> <i class="ar
7b20: 67 22 3e 62 69 6e 61 72 79 5f 73 74 72 69 6e 67  g">binary_string
7b30: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
7b40: 3e 55 6e 69 71 75 65 20 73 65 73 73 69 6f 6e 20  >Unique session 
7b50: 74 69 63 6b 65 74 20 66 6f 72 20 75 73 65 20 69  ticket for use i
7b60: 6e 20 72 65 73 75 6d 69 6e 67 20 74 68 65 20 73  n resuming the s
7b70: 65 73 73 69 6f 6e 2e 3c 2f 70 3e 3c 2f 64 64 3e  ession.</p></dd>
7b80: 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 76  .<dt><b class="v
7b90: 61 72 69 61 62 6c 65 22 3e 74 69 63 6b 65 74 5f  ariable">ticket_
7ba0: 61 70 70 5f 64 61 74 61 3c 2f 62 3e 20 3c 69 20  app_data</b> <i 
7bb0: 63 6c 61 73 73 3d 22 61 72 67 22 3e 62 69 6e 61  class="arg">bina
7bc0: 72 79 5f 73 74 72 69 6e 67 3c 2f 69 3e 3c 2f 64  ry_string</i></d
7bd0: 74 3e 0a 3c 64 64 3e 3c 70 3e 55 6e 69 71 75 65  t>.<dd><p>Unique
7be0: 20 73 65 73 73 69 6f 6e 20 74 69 63 6b 65 74 20   session ticket 
7bf0: 61 70 70 6c 69 63 61 74 69 6f 6e 20 64 61 74 61  application data
7c00: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
7c10: 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c  b class="variabl
7c20: 65 22 3e 6d 61 73 74 65 72 5f 6b 65 79 3c 2f 62  e">master_key</b
7c30: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  > <i class="arg"
7c40: 3e 62 69 6e 61 72 79 5f 73 74 72 69 6e 67 3c 2f  >binary_string</
7c50: 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 55  i></dt>.<dd><p>U
7c60: 6e 69 71 75 65 20 73 65 73 73 69 6f 6e 20 6d 61  nique session ma
7c70: 73 74 65 72 20 6b 65 79 2e 3c 2f 70 3e 3c 2f 64  ster key.</p></d
7c80: 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d  d>.<dt><b class=
7c90: 22 76 61 72 69 61 62 6c 65 22 3e 73 65 73 73 69  "variable">sessi
7ca0: 6f 6e 5f 63 61 63 68 65 5f 6d 6f 64 65 3c 2f 62  on_cache_mode</b
7cb0: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  > <i class="arg"
7cc0: 3e 6d 6f 64 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c  >mode</i></dt>.<
7cd0: 64 64 3e 3c 70 3e 53 65 72 76 65 72 20 63 61 63  dd><p>Server cac
7ce0: 68 65 20 6d 6f 64 65 20 28 63 6c 69 65 6e 74 2c  he mode (client,
7cf0: 20 73 65 72 76 65 72 2c 20 6f 72 20 62 6f 74 68   server, or both
7d00: 29 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 2f 64 6c  ).</p></dd>.</dl
7d10: 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 61 20 6e 61  ></dd>.<dt><a na
7d20: 6d 65 3d 22 39 22 3e 3c 62 20 63 6c 61 73 73 3d  me="9"><b class=
7d30: 22 63 6d 64 22 3e 74 6c 73 3a 3a 63 69 70 68 65  "cmd">tls::ciphe
7d40: 72 73 3c 2f 62 3e 20 3c 73 70 61 6e 20 63 6c 61  rs</b> <span cla
7d50: 73 73 3d 22 6f 70 74 22 3e 3f 3c 69 20 63 6c 61  ss="opt">?<i cla
7d60: 73 73 3d 22 61 72 67 22 3e 70 72 6f 74 6f 63 6f  ss="arg">protoco
7d70: 6c 3c 2f 69 3e 3f 3c 2f 73 70 61 6e 3e 20 3c 73  l</i>?</span> <s
7d80: 70 61 6e 20 63 6c 61 73 73 3d 22 6f 70 74 22 3e  pan class="opt">
7d90: 3f 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e  ?<i class="arg">
7da0: 76 65 72 62 6f 73 65 3c 2f 69 3e 3f 3c 2f 73 70  verbose</i>?</sp
7db0: 61 6e 3e 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d  an> <span class=
7dc0: 22 6f 70 74 22 3e 3f 3c 69 20 63 6c 61 73 73 3d  "opt">?<i class=
7dd0: 22 61 72 67 22 3e 73 75 70 70 6f 72 74 65 64 3c  "arg">supported<
7de0: 2f 69 3e 3f 3c 2f 73 70 61 6e 3e 3c 2f 61 3e 3c  /i>?</span></a><
7df0: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 57 69 74 68  /dt>.<dd><p>With
7e00: 6f 75 74 20 61 6e 79 20 6f 70 74 69 6f 6e 73 2c  out any options,
7e10: 20 69 74 20 72 65 74 75 72 6e 73 20 61 20 6c 69   it returns a li
7e20: 73 74 20 6f 66 20 61 6c 6c 20 73 79 6d 6d 65 74  st of all symmet
7e30: 72 69 63 20 63 69 70 68 65 72 73 20 66 6f 72 20  ric ciphers for 
7e40: 75 73 65 20 77 69 74 68 20 74 68 65 0a 3c 69 20  use with the.<i 
7e50: 63 6c 61 73 73 3d 22 61 72 67 22 3e 2d 63 69 70  class="arg">-cip
7e60: 68 65 72 3c 2f 69 3e 20 6f 70 74 69 6f 6e 2e 20  her</i> option. 
7e70: 57 69 74 68 20 3c 69 20 63 6c 61 73 73 3d 22 61  With <i class="a
7e80: 72 67 22 3e 70 72 6f 74 6f 63 6f 6c 3c 2f 69 3e  rg">protocol</i>
7e90: 2c 20 6f 6e 6c 79 20 74 68 65 20 63 69 70 68 65  , only the ciphe
7ea0: 72 73 20 73 75 70 70 6f 72 74 65 64 20 66 6f 72  rs supported for
7eb0: 20 74 68 61 74 0a 70 72 6f 74 6f 63 6f 6c 20 61   that.protocol a
7ec0: 72 65 20 72 65 74 75 72 6e 65 64 2e 20 53 65 65  re returned. See
7ed0: 20 74 68 65 20 3c 62 20 63 6c 61 73 73 3d 22 63   the <b class="c
7ee0: 6d 64 22 3e 74 6c 73 3a 3a 70 72 6f 74 6f 63 6f  md">tls::protoco
7ef0: 6c 73 3c 2f 62 3e 20 63 6f 6d 6d 61 6e 64 20 66  ls</b> command f
7f00: 6f 72 20 74 68 65 20 73 75 70 70 6f 72 74 65 64  or the supported
7f10: 0a 70 72 6f 74 6f 63 6f 6c 73 2e 20 49 66 20 3c  .protocols. If <
7f20: 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 76 65  i class="arg">ve
7f30: 72 62 6f 73 65 3c 2f 69 3e 20 69 73 20 73 70 65  rbose</i> is spe
7f40: 63 69 66 69 65 64 20 61 73 20 74 72 75 65 20 74  cified as true t
7f50: 68 65 6e 20 61 20 76 65 72 62 6f 73 65 2c 20 68  hen a verbose, h
7f60: 75 6d 61 6e 20 72 65 61 64 61 62 6c 65 0a 6c 69  uman readable.li
7f70: 73 74 20 69 73 20 72 65 74 75 72 6e 65 64 20 77  st is returned w
7f80: 69 74 68 20 61 64 64 69 74 69 6f 6e 61 6c 20 69  ith additional i
7f90: 6e 66 6f 72 6d 61 74 69 6f 6e 20 6f 6e 20 74 68  nformation on th
7fa0: 65 20 63 69 70 68 65 72 2e 20 49 66 20 3c 69 20  e cipher. If <i 
7fb0: 63 6c 61 73 73 3d 22 61 72 67 22 3e 73 75 70 70  class="arg">supp
7fc0: 6f 72 74 65 64 3c 2f 69 3e 0a 69 73 20 73 70 65  orted</i>.is spe
7fd0: 63 69 66 69 65 64 20 61 73 20 74 72 75 65 2c 20  cified as true, 
7fe0: 74 68 65 6e 20 6f 6e 6c 79 20 74 68 65 20 63 69  then only the ci
7ff0: 70 68 65 72 73 20 73 75 70 70 6f 72 74 65 64 20  phers supported 
8000: 66 6f 72 20 70 72 6f 74 6f 63 6f 6c 20 77 69 6c  for protocol wil
8010: 6c 20 62 65 20 6c 69 73 74 65 64 2e 0a 54 68 65  l be listed..The
8020: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
8030: 73 75 70 70 6f 72 74 65 64 3c 2f 69 3e 20 61 72  supported</i> ar
8040: 67 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c  g is new for Tcl
8050: 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64  TLS 1.8.</p></dd
8060: 3e 0a 3c 64 74 3e 3c 61 20 6e 61 6d 65 3d 22 31  >.<dt><a name="1
8070: 30 22 3e 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64  0"><b class="cmd
8080: 22 3e 74 6c 73 3a 3a 70 72 6f 74 6f 63 6f 6c 73  ">tls::protocols
8090: 3c 2f 62 3e 3c 2f 61 3e 3c 2f 64 74 3e 0a 3c 64  </b></a></dt>.<d
80a0: 64 3e 3c 70 3e 52 65 74 75 72 6e 73 20 61 20 6c  d><p>Returns a l
80b0: 69 73 74 20 6f 66 20 74 68 65 20 73 75 70 70 6f  ist of the suppo
80c0: 72 74 65 64 20 53 53 4c 2f 54 4c 53 20 70 72 6f  rted SSL/TLS pro
80d0: 74 6f 63 6f 6c 73 2e 20 56 61 6c 69 64 20 76 61  tocols. Valid va
80e0: 6c 75 65 73 20 61 72 65 3a 0a 3c 62 20 63 6c 61  lues are:.<b cla
80f0: 73 73 3d 22 63 6f 6e 73 74 22 3e 73 73 6c 32 3c  ss="const">ssl2<
8100: 2f 62 3e 2c 20 3c 62 20 63 6c 61 73 73 3d 22 63  /b>, <b class="c
8110: 6f 6e 73 74 22 3e 73 73 6c 33 3c 2f 62 3e 2c 20  onst">ssl3</b>, 
8120: 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22  <b class="const"
8130: 3e 74 6c 73 31 3c 2f 62 3e 2c 20 3c 62 20 63 6c  >tls1</b>, <b cl
8140: 61 73 73 3d 22 63 6f 6e 73 74 22 3e 74 6c 73 31  ass="const">tls1
8150: 2e 31 3c 2f 62 3e 2c 20 3c 62 20 63 6c 61 73 73  .1</b>, <b class
8160: 3d 22 63 6f 6e 73 74 22 3e 74 6c 73 31 2e 32 3c  ="const">tls1.2<
8170: 2f 62 3e 2c 20 61 6e 64 0a 3c 62 20 63 6c 61 73  /b>, and.<b clas
8180: 73 3d 22 63 6f 6e 73 74 22 3e 74 6c 73 31 2e 33  s="const">tls1.3
8190: 3c 2f 62 3e 2e 20 45 78 61 63 74 20 6c 69 73 74  </b>. Exact list
81a0: 20 64 65 70 65 6e 64 73 20 6f 6e 20 4f 70 65 6e   depends on Open
81b0: 53 53 4c 20 76 65 72 73 69 6f 6e 20 61 6e 64 20  SSL version and 
81c0: 63 6f 6d 70 69 6c 65 20 74 69 6d 65 20 66 6c 61  compile time fla
81d0: 67 73 2e 0a 54 68 69 73 20 63 6f 6d 6d 61 6e 64  gs..This command
81e0: 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54   is new for TclT
81f0: 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e  LS 1.8.</p></dd>
8200: 0a 3c 64 74 3e 3c 61 20 6e 61 6d 65 3d 22 31 31  .<dt><a name="11
8210: 22 3e 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22  "><b class="cmd"
8220: 3e 74 6c 73 3a 3a 76 65 72 73 69 6f 6e 3c 2f 62  >tls::version</b
8230: 3e 3c 2f 61 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c  ></a></dt>.<dd><
8240: 70 3e 52 65 74 75 72 6e 73 20 74 68 65 20 4f 70  p>Returns the Op
8250: 65 6e 53 53 4c 20 76 65 72 73 69 6f 6e 20 73 74  enSSL version st
8260: 72 69 6e 67 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c  ring.</p></dd>.<
8270: 2f 64 6c 3e 0a 3c 2f 64 69 76 3e 0a 3c 64 69 76  /dl>.</div>.<div
8280: 20 69 64 3d 22 73 65 63 74 69 6f 6e 34 22 20 63   id="section4" c
8290: 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73  lass="doctools_s
82a0: 65 63 74 69 6f 6e 22 3e 3c 68 32 3e 3c 61 20 6e  ection"><h2><a n
82b0: 61 6d 65 3d 22 73 65 63 74 69 6f 6e 34 22 3e 43  ame="section4">C
82c0: 65 72 74 69 66 69 63 61 74 65 20 56 61 6c 69 64  ertificate Valid
82d0: 61 74 69 6f 6e 3c 2f 61 3e 3c 2f 68 32 3e 0a 3c  ation</a></h2>.<
82e0: 64 69 76 20 69 64 3d 22 73 75 62 73 65 63 74 69  div id="subsecti
82f0: 6f 6e 31 22 20 63 6c 61 73 73 3d 22 64 6f 63 74  on1" class="doct
8300: 6f 6f 6c 73 5f 73 75 62 73 65 63 74 69 6f 6e 22  ools_subsection"
8310: 3e 3c 68 33 3e 3c 61 20 6e 61 6d 65 3d 22 73 75  ><h3><a name="su
8320: 62 73 65 63 74 69 6f 6e 31 22 3e 50 4b 49 20 61  bsection1">PKI a
8330: 6e 64 20 43 65 72 74 69 66 69 63 61 74 65 73 3c  nd Certificates<
8340: 2f 61 3e 3c 2f 68 33 3e 0a 3c 70 3e 55 73 69 6e  /a></h3>.<p>Usin
8350: 67 20 74 68 65 20 50 75 62 6c 69 63 20 4b 65 79  g the Public Key
8360: 20 49 6e 66 72 61 73 74 72 75 63 74 75 72 65 20   Infrastructure 
8370: 28 50 4b 49 29 2c 20 65 61 63 68 20 75 73 65 72  (PKI), each user
8380: 20 63 72 65 61 74 65 73 20 61 20 70 72 69 76 61   creates a priva
8390: 74 65 20 6b 65 79 20 74 68 61 74 0a 6f 6e 6c 79  te key that.only
83a0: 20 74 68 65 79 20 6b 6e 6f 77 20 61 62 6f 75 74   they know about
83b0: 20 61 6e 64 20 61 20 70 75 62 6c 69 63 20 6b 65   and a public ke
83c0: 79 20 74 68 65 79 20 63 61 6e 20 65 78 63 68 61  y they can excha
83d0: 6e 67 65 20 77 69 74 68 20 6f 74 68 65 72 73 20  nge with others 
83e0: 66 6f 72 20 75 73 65 20 69 6e 0a 65 6e 63 72 79  for use in.encry
83f0: 70 74 69 6e 67 20 61 6e 64 20 64 65 63 72 79 70  pting and decryp
8400: 74 69 6e 67 20 64 61 74 61 2e 20 54 68 65 20 70  ting data. The p
8410: 72 6f 63 65 73 73 20 69 73 20 74 68 65 20 73 65  rocess is the se
8420: 6e 64 65 72 20 65 6e 63 72 79 70 74 73 20 74 68  nder encrypts th
8430: 65 69 72 20 64 61 74 61 0a 75 73 69 6e 67 20 74  eir data.using t
8440: 68 65 69 72 20 70 72 69 76 61 74 65 20 6b 65 79  heir private key
8450: 20 61 6e 64 20 74 68 65 20 72 65 63 65 69 76 65   and the receive
8460: 72 27 73 20 70 75 62 6c 69 63 20 6b 65 79 2e 20  r's public key. 
8470: 54 68 65 20 64 61 74 61 20 69 73 20 74 68 65 6e  The data is then
8480: 20 73 65 6e 74 0a 74 6f 20 74 68 65 20 72 65 63   sent.to the rec
8490: 65 69 76 65 72 2e 20 49 6e 20 61 20 73 69 6d 69  eiver. In a simi
84a0: 6c 61 72 20 6d 61 6e 6e 65 72 2c 20 74 68 65 20  lar manner, the 
84b0: 72 65 63 65 69 76 65 72 20 75 73 65 73 20 74 68  receiver uses th
84c0: 65 69 72 20 70 72 69 76 61 74 65 20 6b 65 79 20  eir private key 
84d0: 61 6e 64 0a 74 68 65 20 73 65 6e 64 65 72 27 73  and.the sender's
84e0: 20 70 75 62 6c 69 63 20 6b 65 79 20 74 6f 20 64   public key to d
84f0: 65 63 72 79 70 74 20 74 68 65 20 64 61 74 61 2e  ecrypt the data.
8500: 20 54 68 69 73 20 70 72 6f 76 69 64 65 73 20 64   This provides d
8510: 61 74 61 20 69 6e 74 65 67 72 69 74 79 2c 20 74  ata integrity, t
8520: 6f 0a 65 6e 73 75 72 65 20 74 68 65 20 64 61 74  o.ensure the dat
8530: 61 20 63 61 6e 27 74 20 62 65 20 76 69 65 77 65  a can't be viewe
8540: 64 20 6f 72 20 61 6c 74 65 72 65 64 20 64 75 72  d or altered dur
8550: 69 6e 67 20 74 72 61 6e 73 70 6f 72 74 2e 20 53  ing transport. S
8560: 65 65 20 74 68 65 0a 3c 62 20 63 6c 61 73 73 3d  ee the.<b class=
8570: 22 6f 70 74 69 6f 6e 22 3e 2d 6b 65 79 3c 2f 62  "option">-key</b
8580: 3e 20 61 6e 64 20 3c 62 20 63 6c 61 73 73 3d 22  > and <b class="
8590: 6f 70 74 69 6f 6e 22 3e 2d 6b 65 79 66 69 6c 65  option">-keyfile
85a0: 3c 2f 62 3e 20 6f 70 74 69 6f 6e 73 20 66 6f 72  </b> options for
85b0: 20 68 6f 77 20 74 6f 20 73 70 65 63 69 66 79 20   how to specify 
85c0: 74 68 65 20 70 72 69 76 61 74 65 20 6b 65 79 2e  the private key.
85d0: 0a 41 6c 73 6f 20 73 65 65 20 74 68 65 20 3c 62  .Also see the <b
85e0: 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e   class="option">
85f0: 2d 70 61 73 73 77 6f 72 64 3c 2f 62 3e 20 6f 70  -password</b> op
8600: 74 69 6f 6e 20 66 6f 72 20 68 6f 77 20 74 6f 20  tion for how to 
8610: 70 72 6f 76 69 64 65 20 74 68 65 20 70 61 73 73  provide the pass
8620: 77 6f 72 64 2e 3c 2f 70 3e 0a 3c 70 3e 49 6e 20  word.</p>.<p>In 
8630: 6f 72 64 65 72 20 74 6f 20 70 72 6f 76 69 64 65  order to provide
8640: 20 61 75 74 68 65 6e 74 69 63 61 74 69 6f 6e 2c   authentication,
8650: 20 69 2e 65 2e 20 65 6e 73 75 72 69 6e 67 20 73   i.e. ensuring s
8660: 6f 6d 65 6f 6e 65 20 69 73 20 77 68 6f 20 74 68  omeone is who th
8670: 65 79 20 73 61 79 20 74 68 65 79 0a 61 72 65 2c  ey say they.are,
8680: 20 74 68 65 20 70 75 62 6c 69 63 20 6b 65 79 20   the public key 
8690: 61 6e 64 20 75 73 65 72 20 69 64 65 6e 74 69 66  and user identif
86a0: 69 63 61 74 69 6f 6e 20 69 6e 66 6f 20 69 73 20  ication info is 
86b0: 73 74 6f 72 65 64 20 69 6e 20 61 20 58 2e 35 30  stored in a X.50
86c0: 39 0a 63 65 72 74 69 66 69 63 61 74 65 20 61 6e  9.certificate an
86d0: 64 20 74 68 61 74 20 63 65 72 74 69 66 69 63 61  d that certifica
86e0: 74 65 20 69 73 20 61 75 74 68 65 6e 74 69 63 61  te is authentica
86f0: 74 65 64 20 28 69 2e 65 2e 20 73 69 67 6e 65 64  ted (i.e. signed
8700: 29 20 62 79 20 61 20 43 65 72 74 69 66 69 63 61  ) by a Certifica
8710: 74 65 0a 41 75 74 68 6f 72 69 74 79 20 28 43 41  te.Authority (CA
8720: 29 2e 20 55 73 65 72 73 20 63 61 6e 20 74 68 65  ). Users can the
8730: 6e 20 65 78 63 68 61 6e 67 65 20 74 68 65 73 65  n exchange these
8740: 20 63 65 72 74 69 66 69 63 61 74 65 73 20 64 75   certificates du
8750: 72 69 6e 67 20 74 68 65 20 54 4c 53 0a 69 6e 69  ring the TLS.ini
8760: 74 69 61 6c 69 7a 61 74 69 6f 6e 20 70 72 6f 63  tialization proc
8770: 65 73 73 20 61 6e 64 20 63 68 65 63 6b 20 74 68  ess and check th
8780: 65 6d 20 61 67 61 69 6e 73 74 20 74 68 65 20 72  em against the r
8790: 6f 6f 74 20 43 41 20 63 65 72 74 69 66 69 63 61  oot CA certifica
87a0: 74 65 73 20 74 6f 20 65 6e 73 75 72 65 0a 74 68  tes to ensure.th
87b0: 65 79 20 61 72 65 20 76 61 6c 69 64 2e 20 54 68  ey are valid. Th
87c0: 69 73 20 69 73 20 68 61 6e 64 6c 65 64 20 62 79  is is handled by
87d0: 20 4f 70 65 6e 53 53 4c 20 76 69 61 20 74 68 65   OpenSSL via the
87e0: 20 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f   <b class="optio
87f0: 6e 22 3e 2d 72 65 71 75 65 73 74 3c 2f 62 3e 20  n">-request</b> 
8800: 61 6e 64 0a 3c 62 20 63 6c 61 73 73 3d 22 6f 70  and.<b class="op
8810: 74 69 6f 6e 22 3e 2d 72 65 71 75 69 72 65 3c 2f  tion">-require</
8820: 62 3e 20 6f 70 74 69 6f 6e 73 2e 20 53 65 65 20  b> options. See 
8830: 74 68 65 20 3c 62 20 63 6c 61 73 73 3d 22 6f 70  the <b class="op
8840: 74 69 6f 6e 22 3e 2d 63 61 64 69 72 3c 2f 62 3e  tion">-cadir</b>
8850: 2c 20 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  , <b class="opti
8860: 6f 6e 22 3e 2d 63 61 64 69 72 3c 2f 62 3e 2c 20  on">-cadir</b>, 
8870: 61 6e 64 0a 3c 62 20 63 6c 61 73 73 3d 22 6f 70  and.<b class="op
8880: 74 69 6f 6e 22 3e 2d 63 61 73 74 6f 72 65 3c 2f  tion">-castore</
8890: 62 3e 20 6f 70 74 69 6f 6e 73 20 66 6f 72 20 68  b> options for h
88a0: 6f 77 20 74 70 20 73 70 65 63 69 66 79 20 77 68  ow tp specify wh
88b0: 65 72 65 20 74 6f 20 66 69 6e 64 20 74 68 65 20  ere to find the 
88c0: 43 41 20 63 65 72 74 69 66 69 63 61 74 65 73 2e  CA certificates.
88d0: 0a 4f 70 74 69 6f 6e 61 6c 6c 79 2c 20 69 6e 20  .Optionally, in 
88e0: 61 20 66 75 74 75 72 65 20 72 65 6c 65 61 73 65  a future release
88f0: 2c 20 74 68 65 79 20 63 61 6e 20 61 6c 73 6f 20  , they can also 
8900: 62 65 20 63 68 65 63 6b 65 64 20 61 67 61 69 6e  be checked again
8910: 73 74 20 74 68 65 20 43 65 72 74 69 66 69 63 61  st the Certifica
8920: 74 65 0a 52 65 76 6f 63 61 74 69 6f 6e 20 4c 69  te.Revocation Li
8930: 73 74 20 28 43 52 4c 29 20 6f 66 20 72 65 76 6f  st (CRL) of revo
8940: 6b 65 64 20 63 65 72 74 69 66 69 63 61 74 65 73  ked certificates
8950: 2e 20 43 65 72 74 69 66 69 63 61 74 65 73 20 63  . Certificates c
8960: 61 6e 20 61 6c 73 6f 20 62 65 0a 73 65 6c 66 2d  an also be.self-
8970: 73 69 67 6e 65 64 2c 20 62 75 74 20 74 68 65 79  signed, but they
8980: 20 61 72 65 20 62 79 20 64 65 66 61 75 6c 74 20   are by default 
8990: 6e 6f 74 20 74 72 75 73 74 65 64 20 75 6e 6c 65  not trusted unle
89a0: 73 73 20 79 6f 75 20 61 64 64 20 74 68 65 6d 20  ss you add them 
89b0: 74 6f 20 79 6f 75 72 0a 63 65 72 74 69 66 69 63  to your.certific
89c0: 61 74 65 20 73 74 6f 72 65 2e 3c 2f 70 3e 0a 3c  ate store.</p>.<
89d0: 70 3e 54 79 70 69 63 61 6c 6c 79 20 77 68 65 6e  p>Typically when
89e0: 20 76 69 73 69 74 69 6e 67 20 77 65 62 20 73 69   visiting web si
89f0: 74 65 73 2c 20 6f 6e 6c 79 20 74 68 65 20 63 6c  tes, only the cl
8a00: 69 65 6e 74 20 6e 65 65 64 73 20 74 6f 20 63 68  ient needs to ch
8a10: 65 63 6b 20 74 68 65 20 73 65 72 76 65 72 27 73  eck the server's
8a20: 0a 63 65 72 74 69 66 69 63 61 74 65 20 74 6f 20  .certificate to 
8a30: 65 6e 73 75 72 65 20 69 74 20 69 73 20 76 61 6c  ensure it is val
8a40: 69 64 2e 20 54 68 65 20 73 65 72 76 65 72 20 64  id. The server d
8a50: 6f 65 73 6e 27 74 20 6e 65 65 64 20 74 6f 20 63  oesn't need to c
8a60: 68 65 63 6b 20 74 68 65 20 63 6c 69 65 6e 74 0a  heck the client.
8a70: 63 65 72 74 69 66 69 63 61 74 65 20 75 6e 6c 65  certificate unle
8a80: 73 73 20 79 6f 75 20 6e 65 65 64 20 74 6f 20 61  ss you need to a
8a90: 75 74 68 65 6e 74 69 63 61 74 65 20 77 69 74 68  uthenticate with
8aa0: 20 74 68 65 6d 20 74 6f 20 6c 6f 67 69 6e 2c 20   them to login, 
8ab0: 65 74 63 2e 20 53 65 65 20 74 68 65 0a 3c 62 20  etc. See the.<b 
8ac0: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
8ad0: 63 65 72 74 3c 2f 62 3e 20 61 6e 64 20 3c 62 20  cert</b> and <b 
8ae0: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
8af0: 63 65 72 74 66 69 6c 65 3c 2f 62 3e 20 6f 70 74  certfile</b> opt
8b00: 69 6f 6e 73 20 69 66 20 79 6f 75 20 6e 65 65 64  ions if you need
8b10: 20 74 6f 20 70 72 6f 76 69 64 65 20 61 20 63 65   to provide a ce
8b20: 72 74 69 66 69 63 61 74 65 2e 3c 2f 70 3e 0a 3c  rtificate.</p>.<
8b30: 2f 64 69 76 3e 0a 3c 64 69 76 20 69 64 3d 22 73  /div>.<div id="s
8b40: 75 62 73 65 63 74 69 6f 6e 32 22 20 63 6c 61 73  ubsection2" clas
8b50: 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73 75 62 73  s="doctools_subs
8b60: 65 63 74 69 6f 6e 22 3e 3c 68 33 3e 3c 61 20 6e  ection"><h3><a n
8b70: 61 6d 65 3d 22 73 75 62 73 65 63 74 69 6f 6e 32  ame="subsection2
8b80: 22 3e 53 75 6d 6d 61 72 79 20 6f 66 20 63 6f 6d  ">Summary of com
8b90: 6d 61 6e 64 20 6c 69 6e 65 20 6f 70 74 69 6f 6e  mand line option
8ba0: 73 3c 2f 61 3e 3c 2f 68 33 3e 0a 3c 70 3e 54 68  s</a></h3>.<p>Th
8bb0: 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 6f 70 74 69  e following opti
8bc0: 6f 6e 73 20 61 72 65 20 75 73 65 64 20 66 6f 72  ons are used for
8bd0: 20 70 65 65 72 20 63 65 72 74 69 66 69 63 61 74   peer certificat
8be0: 65 20 76 61 6c 69 64 61 74 69 6f 6e 3a 3c 2f 70  e validation:</p
8bf0: 3e 0a 3c 64 6c 20 63 6c 61 73 73 3d 22 64 6f 63  >.<dl class="doc
8c00: 74 6f 6f 6c 73 5f 6f 70 74 69 6f 6e 73 22 3e 0a  tools_options">.
8c10: 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70  <dt><b class="op
8c20: 74 69 6f 6e 22 3e 2d 63 61 64 69 72 3c 2f 62 3e  tion">-cadir</b>
8c30: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
8c40: 64 69 72 65 63 74 6f 72 79 3c 2f 69 3e 3c 2f 64  directory</i></d
8c50: 74 3e 0a 3c 64 64 3e 3c 70 3e 53 70 65 63 69 66  t>.<dd><p>Specif
8c60: 69 65 73 20 74 68 65 20 64 69 72 65 63 74 6f 72  ies the director
8c70: 79 20 77 68 65 72 65 20 74 68 65 20 43 65 72 74  y where the Cert
8c80: 69 66 69 63 61 74 65 20 41 75 74 68 6f 72 69 74  ificate Authorit
8c90: 79 20 28 43 41 29 20 63 65 72 74 69 66 69 63 61  y (CA) certifica
8ca0: 74 65 73 20 61 72 65 0a 73 74 6f 72 65 64 2e 20  tes are.stored. 
8cb0: 54 68 65 20 64 65 66 61 75 6c 74 20 69 73 20 70  The default is p
8cc0: 6c 61 74 66 6f 72 6d 20 73 70 65 63 69 66 69 63  latform specific
8cd0: 2c 20 62 75 74 20 69 73 20 75 73 75 61 6c 6c 79  , but is usually
8ce0: 20 26 71 75 6f 74 3b 3c 62 20 63 6c 61 73 73 3d   &quot;<b class=
8cf0: 22 66 69 6c 65 22 3e 2f 65 74 63 2f 73 73 6c 2f  "file">/etc/ssl/
8d00: 63 65 72 74 73 3c 2f 62 3e 26 71 75 6f 74 3b 20  certs</b>&quot; 
8d10: 6f 6e 0a 4c 69 6e 75 78 2f 55 6e 69 78 20 73 79  on.Linux/Unix sy
8d20: 73 74 65 6d 73 2e 20 54 68 65 20 64 65 66 61 75  stems. The defau
8d30: 6c 74 20 6c 6f 63 61 74 69 6f 6e 20 63 61 6e 20  lt location can 
8d40: 62 65 20 6f 76 65 72 72 69 64 64 65 6e 20 62 79  be overridden by
8d50: 20 74 68 65 0a 3c 62 20 63 6c 61 73 73 3d 22 76   the.<b class="v
8d60: 61 72 69 61 62 6c 65 22 3e 53 53 4c 5f 43 45 52  ariable">SSL_CER
8d70: 54 5f 44 49 52 3c 2f 62 3e 20 65 6e 76 69 72 6f  T_DIR</b> enviro
8d80: 6e 6d 65 6e 74 20 76 61 72 69 61 62 6c 65 2e 3c  nment variable.<
8d90: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20  /p></dd>.<dt><b 
8da0: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
8db0: 63 61 66 69 6c 65 3c 2f 62 3e 20 3c 69 20 63 6c  cafile</b> <i cl
8dc0: 61 73 73 3d 22 61 72 67 22 3e 66 69 6c 65 6e 61  ass="arg">filena
8dd0: 6d 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  me</i></dt>.<dd>
8de0: 3c 70 3e 53 70 65 63 69 66 69 65 73 20 74 68 65  <p>Specifies the
8df0: 20 66 69 6c 65 20 77 69 74 68 20 74 68 65 20 43   file with the C
8e00: 65 72 74 69 66 69 63 61 74 65 20 41 75 74 68 6f  ertificate Autho
8e10: 72 69 74 79 20 28 43 41 29 20 63 65 72 74 69 66  rity (CA) certif
8e20: 69 63 61 74 65 73 20 74 6f 20 75 73 65 20 69 6e  icates to use in
8e30: 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74  .<b class="const
8e40: 22 3e 50 45 4d 3c 2f 62 3e 20 66 69 6c 65 20 66  ">PEM</b> file f
8e50: 6f 72 6d 61 74 2e 20 54 68 65 20 64 65 66 61 75  ormat. The defau
8e60: 6c 74 20 69 73 20 26 71 75 6f 74 3b 3c 62 20 63  lt is &quot;<b c
8e70: 6c 61 73 73 3d 22 66 69 6c 65 22 3e 63 65 72 74  lass="file">cert
8e80: 2e 70 65 6d 3c 2f 62 3e 26 71 75 6f 74 3b 2c 20  .pem</b>&quot;, 
8e90: 69 6e 20 74 68 65 20 4f 70 65 6e 53 53 4c 0a 64  in the OpenSSL.d
8ea0: 69 72 65 63 74 6f 72 79 2e 20 4f 6e 20 4c 69 6e  irectory. On Lin
8eb0: 75 78 2f 55 6e 69 78 20 73 79 73 74 65 6d 73 2c  ux/Unix systems,
8ec0: 20 74 68 69 73 20 69 73 20 75 73 75 61 6c 6c 79   this is usually
8ed0: 20 26 71 75 6f 74 3b 3c 62 20 63 6c 61 73 73 3d   &quot;<b class=
8ee0: 22 66 69 6c 65 22 3e 2f 65 74 63 2f 73 73 6c 2f  "file">/etc/ssl/
8ef0: 63 61 2d 62 75 6e 64 6c 65 2e 70 65 6d 3c 2f 62  ca-bundle.pem</b
8f00: 3e 26 71 75 6f 74 3b 2e 0a 54 68 65 20 64 65 66  >&quot;..The def
8f10: 61 75 6c 74 20 66 69 6c 65 20 63 61 6e 20 62 65  ault file can be
8f20: 20 6f 76 65 72 72 69 64 64 65 6e 20 62 79 20 74   overridden by t
8f30: 68 65 20 3c 62 20 63 6c 61 73 73 3d 22 76 61 72  he <b class="var
8f40: 69 61 62 6c 65 22 3e 53 53 4c 5f 43 45 52 54 5f  iable">SSL_CERT_
8f50: 46 49 4c 45 3c 2f 62 3e 20 65 6e 76 69 72 6f 6e  FILE</b> environ
8f60: 6d 65 6e 74 0a 76 61 72 69 61 62 6c 65 2e 3c 2f  ment.variable.</
8f70: 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63  p></dd>.<dt><b c
8f80: 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63  lass="option">-c
8f90: 61 73 74 6f 72 65 3c 2f 62 3e 20 3c 69 20 63 6c  astore</b> <i cl
8fa0: 61 73 73 3d 22 61 72 67 22 3e 55 52 49 3c 2f 69  ass="arg">URI</i
8fb0: 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 53 70  ></dt>.<dd><p>Sp
8fc0: 65 63 69 66 69 65 73 20 74 68 65 20 55 6e 69 66  ecifies the Unif
8fd0: 6f 72 6d 20 52 65 73 6f 75 72 63 65 20 49 64 65  orm Resource Ide
8fe0: 6e 74 69 66 69 65 72 20 28 55 52 49 29 20 66 6f  ntifier (URI) fo
8ff0: 72 20 74 68 65 20 43 65 72 74 69 66 69 63 61 74  r the Certificat
9000: 65 20 41 75 74 68 6f 72 69 74 79 0a 28 43 41 29  e Authority.(CA)
9010: 20 73 74 6f 72 65 2c 20 77 68 69 63 68 20 6d 61   store, which ma
9020: 79 20 62 65 20 61 20 73 69 6e 67 6c 65 20 63 6f  y be a single co
9030: 6e 74 61 69 6e 65 72 20 6f 72 20 61 20 63 61 74  ntainer or a cat
9040: 61 6c 6f 67 20 6f 66 20 63 6f 6e 74 61 69 6e 65  alog of containe
9050: 72 73 2e 0a 53 74 61 72 74 69 6e 67 20 77 69 74  rs..Starting wit
9060: 68 20 4f 70 65 6e 53 53 4c 20 33 2e 32 20 6f 6e  h OpenSSL 3.2 on
9070: 20 4d 53 20 57 69 6e 64 6f 77 73 2c 20 73 65 74   MS Windows, set
9080: 20 74 6f 20 26 71 75 6f 74 3b 3c 62 20 63 6c 61   to &quot;<b cla
9090: 73 73 3d 22 63 6f 6e 73 74 22 3e 6f 72 67 2e 6f  ss="const">org.o
90a0: 70 65 6e 73 73 6c 2e 77 69 6e 73 74 6f 72 65 3a  penssl.winstore:
90b0: 2f 2f 3c 2f 62 3e 26 71 75 6f 74 3b 0a 74 6f 20  //</b>&quot;.to 
90c0: 75 73 65 20 74 68 65 20 62 75 69 6c 74 2d 69 6e  use the built-in
90d0: 20 4d 53 20 57 69 6e 64 6f 77 73 20 43 65 72 74   MS Windows Cert
90e0: 69 66 69 63 61 74 65 20 53 74 6f 72 65 2e 20 53  ificate Store. S
90f0: 74 61 72 74 69 6e 67 20 69 6e 20 54 63 6c 54 4c  tarting in TclTL
9100: 53 20 32 2e 30 2c 20 74 68 69 73 0a 69 73 20 74  S 2.0, this.is t
9110: 68 65 20 64 65 66 61 75 6c 74 20 69 66 20 3c 62  he default if <b
9120: 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e   class="option">
9130: 2d 63 61 64 69 72 3c 2f 62 3e 2c 20 3c 62 20 63  -cadir</b>, <b c
9140: 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63  lass="option">-c
9150: 61 64 69 72 3c 2f 62 3e 2c 20 61 6e 64 20 3c 62  adir</b>, and <b
9160: 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e   class="option">
9170: 2d 63 61 73 74 6f 72 65 3c 2f 62 3e 20 61 72 65  -castore</b> are
9180: 0a 6e 6f 74 20 73 70 65 63 69 66 69 65 64 2e 20  .not specified. 
9190: 54 68 69 73 20 73 74 6f 72 65 20 6f 6e 6c 79 20  This store only 
91a0: 73 75 70 70 6f 72 74 73 20 72 6f 6f 74 20 63 65  supports root ce
91b0: 72 74 69 66 69 63 61 74 65 20 73 74 6f 72 65 73  rtificate stores
91c0: 2e 20 53 65 65 0a 3c 73 70 61 6e 20 63 6c 61 73  . See.<span clas
91d0: 73 3d 22 73 65 63 74 72 65 66 22 3e 3c 61 20 68  s="sectref"><a h
91e0: 72 65 66 3d 22 23 73 65 63 74 69 6f 6e 34 22 3e  ref="#section4">
91f0: 43 65 72 74 69 66 69 63 61 74 65 20 56 61 6c 69  Certificate Vali
9200: 64 61 74 69 6f 6e 3c 2f 61 3e 3c 2f 73 70 61 6e  dation</a></span
9210: 3e 20 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 69  > for more detai
9220: 6c 73 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74  ls.</p></dd>.<dt
9230: 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f  ><b class="optio
9240: 6e 22 3e 2d 72 65 71 75 65 73 74 3c 2f 62 3e 20  n">-request</b> 
9250: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 62  <i class="arg">b
9260: 6f 6f 6c 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64  ool</i></dt>.<dd
9270: 3e 3c 70 3e 52 65 71 75 65 73 74 20 61 20 63 65  ><p>Request a ce
9280: 72 74 69 66 69 63 61 74 65 20 66 72 6f 6d 20 74  rtificate from t
9290: 68 65 20 70 65 65 72 20 64 75 72 69 6e 67 20 74  he peer during t
92a0: 68 65 20 53 53 4c 20 68 61 6e 64 73 68 61 6b 65  he SSL handshake
92b0: 2e 20 54 68 69 73 20 69 73 20 6e 65 65 64 65 64  . This is needed
92c0: 0a 74 6f 20 64 6f 20 43 65 72 74 69 66 69 63 61  .to do Certifica
92d0: 74 65 20 56 61 6c 69 64 61 74 69 6f 6e 2e 20 53  te Validation. S
92e0: 74 61 72 74 69 6e 67 20 69 6e 20 54 63 6c 54 4c  tarting in TclTL
92f0: 53 20 31 2e 38 2c 20 74 68 65 20 64 65 66 61 75  S 1.8, the defau
9300: 6c 74 20 69 73 0a 3c 62 20 63 6c 61 73 73 3d 22  lt is.<b class="
9310: 63 6f 6e 73 74 22 3e 74 72 75 65 3c 2f 62 3e 2e  const">true</b>.
9320: 20 53 74 61 72 74 69 6e 67 20 69 6e 20 54 63 6c   Starting in Tcl
9330: 54 4c 53 20 32 2e 30 2c 20 49 66 20 73 65 74 20  TLS 2.0, If set 
9340: 74 6f 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e  to <b class="con
9350: 73 74 22 3e 66 61 6c 73 65 3c 2f 62 3e 20 61 6e  st">false</b> an
9360: 64 0a 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  d.<b class="opti
9370: 6f 6e 22 3e 2d 72 65 71 75 69 72 65 3c 2f 62 3e  on">-require</b>
9380: 20 69 73 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f   is <b class="co
9390: 6e 73 74 22 3e 74 72 75 65 3c 2f 62 3e 2c 20 74  nst">true</b>, t
93a0: 68 65 6e 20 74 68 69 73 20 77 69 6c 6c 20 62 65  hen this will be
93b0: 20 6f 76 65 72 72 69 64 64 65 6e 20 74 6f 20 3c   overridden to <
93c0: 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e  b class="const">
93d0: 74 72 75 65 3c 2f 62 3e 2e 0a 49 6e 20 61 64 64  true</b>..In add
93e0: 69 74 69 6f 6e 2c 20 74 68 65 20 63 6c 69 65 6e  ition, the clien
93f0: 74 20 63 61 6e 20 6d 61 6e 75 61 6c 6c 79 20 69  t can manually i
9400: 6e 73 70 65 63 74 20 61 6e 64 20 61 63 63 65 70  nspect and accep
9410: 74 20 6f 72 20 72 65 6a 65 63 74 0a 65 61 63 68  t or reject.each
9420: 20 63 65 72 74 69 66 69 63 61 74 65 20 75 73 69   certificate usi
9430: 6e 67 20 74 68 65 20 3c 69 20 63 6c 61 73 73 3d  ng the <i class=
9440: 22 61 72 67 22 3e 2d 76 61 6c 69 64 61 74 65 63  "arg">-validatec
9450: 6f 6d 6d 61 6e 64 3c 2f 69 3e 20 6f 70 74 69 6f  ommand</i> optio
9460: 6e 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  n.</p></dd>.<dt>
9470: 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e  <b class="option
9480: 22 3e 2d 72 65 71 75 69 72 65 3c 2f 62 3e 20 3c  ">-require</b> <
9490: 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 62 6f  i class="arg">bo
94a0: 6f 6c 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  ol</i></dt>.<dd>
94b0: 3c 70 3e 52 65 71 75 69 72 65 20 61 20 76 61 6c  <p>Require a val
94c0: 69 64 20 63 65 72 74 69 66 69 63 61 74 65 20 66  id certificate f
94d0: 72 6f 6d 20 74 68 65 20 70 65 65 72 20 64 75 72  rom the peer dur
94e0: 69 6e 67 20 74 68 65 20 53 53 4c 20 68 61 6e 64  ing the SSL hand
94f0: 73 68 61 6b 65 2e 20 49 66 20 74 68 69 73 20 69  shake. If this i
9500: 73 0a 73 65 74 20 74 6f 20 74 72 75 65 2c 20 74  s.set to true, t
9510: 68 65 6e 20 3c 62 20 63 6c 61 73 73 3d 22 6f 70  hen <b class="op
9520: 74 69 6f 6e 22 3e 2d 72 65 71 75 65 73 74 3c 2f  tion">-request</
9530: 62 3e 20 6d 75 73 74 20 61 6c 73 6f 20 62 65 20  b> must also be 
9540: 73 65 74 20 74 6f 20 74 72 75 65 20 61 6e 64 20  set to true and 
9550: 61 20 65 69 74 68 65 72 0a 3c 62 20 63 6c 61 73  a either.<b clas
9560: 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 64 69  s="option">-cadi
9570: 72 3c 2f 62 3e 2c 20 3c 62 20 63 6c 61 73 73 3d  r</b>, <b class=
9580: 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 66 69 6c 65  "option">-cafile
9590: 3c 2f 62 3e 2c 20 3c 62 20 63 6c 61 73 73 3d 22  </b>, <b class="
95a0: 6f 70 74 69 6f 6e 22 3e 2d 63 61 73 74 6f 72 65  option">-castore
95b0: 3c 2f 62 3e 2c 20 6f 72 20 61 20 70 6c 61 74 66  </b>, or a platf
95c0: 6f 72 6d 20 64 65 66 61 75 6c 74 0a 6d 75 73 74  orm default.must
95d0: 20 62 65 20 70 72 6f 76 69 64 65 64 20 69 6e 20   be provided in 
95e0: 6f 72 64 65 72 20 74 6f 20 76 61 6c 69 64 61 74  order to validat
95f0: 65 20 61 67 61 69 6e 73 74 2e 20 54 68 65 20 64  e against. The d
9600: 65 66 61 75 6c 74 20 69 6e 20 54 63 6c 54 4c 53  efault in TclTLS
9610: 20 31 2e 38 20 61 6e 64 0a 65 61 72 6c 69 65 72   1.8 and.earlier
9620: 20 76 65 72 73 69 6f 6e 73 20 69 73 20 3c 62 20   versions is <b 
9630: 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 66 61  class="const">fa
9640: 6c 73 65 3c 2f 62 3e 20 73 69 6e 63 65 20 6e 6f  lse</b> since no
9650: 74 20 61 6c 6c 20 70 6c 61 74 66 6f 72 6d 73 20  t all platforms 
9660: 68 61 76 65 20 63 65 72 74 69 66 69 63 61 74 65  have certificate
9670: 73 20 74 6f 0a 76 61 6c 69 64 61 74 65 20 61 67  s to.validate ag
9680: 61 69 6e 73 74 20 69 6e 20 61 20 66 6f 72 6d 20  ainst in a form 
9690: 63 6f 6d 70 61 74 69 62 6c 65 20 77 69 74 68 20  compatible with 
96a0: 4f 70 65 6e 53 53 4c 2e 20 53 74 61 72 74 69 6e  OpenSSL. Startin
96b0: 67 20 69 6e 20 54 63 6c 54 4c 53 20 32 2e 30 2c  g in TclTLS 2.0,
96c0: 0a 74 68 65 20 64 65 66 61 75 6c 74 20 69 73 20  .the default is 
96d0: 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22  <b class="const"
96e0: 3e 74 72 75 65 3c 2f 62 3e 2e 3c 2f 70 3e 3c 2f  >true</b>.</p></
96f0: 64 64 3e 0a 3c 2f 64 6c 3e 0a 3c 2f 64 69 76 3e  dd>.</dl>.</div>
9700: 0a 3c 64 69 76 20 69 64 3d 22 73 75 62 73 65 63  .<div id="subsec
9710: 74 69 6f 6e 33 22 20 63 6c 61 73 73 3d 22 64 6f  tion3" class="do
9720: 63 74 6f 6f 6c 73 5f 73 75 62 73 65 63 74 69 6f  ctools_subsectio
9730: 6e 22 3e 3c 68 33 3e 3c 61 20 6e 61 6d 65 3d 22  n"><h3><a name="
9740: 73 75 62 73 65 63 74 69 6f 6e 33 22 3e 57 68 65  subsection3">Whe
9750: 6e 20 61 72 65 20 63 6f 6d 6d 61 6e 64 20 6c 69  n are command li
9760: 6e 65 20 6f 70 74 69 6f 6e 73 20 6e 65 65 64 65  ne options neede
9770: 64 3f 3c 2f 61 3e 3c 2f 68 33 3e 0a 3c 70 3e 49  d?</a></h3>.<p>I
9780: 6e 20 54 63 6c 54 4c 53 20 31 2e 38 20 61 6e 64  n TclTLS 1.8 and
9790: 20 65 61 72 6c 69 65 72 20 76 65 72 73 69 6f 6e   earlier version
97a0: 73 2c 20 63 65 72 74 69 66 69 63 61 74 65 20 76  s, certificate v
97b0: 61 6c 69 64 61 74 69 6f 6e 20 69 73 0a 3c 65 6d  alidation is.<em
97c0: 3e 4e 4f 54 3c 2f 65 6d 3e 20 65 6e 61 62 6c 65  >NOT</em> enable
97d0: 64 20 62 79 20 64 65 66 61 75 6c 74 2e 20 54 68  d by default. Th
97e0: 69 73 20 6c 69 6d 69 74 61 74 69 6f 6e 20 69 73  is limitation is
97f0: 20 64 75 65 20 74 6f 20 74 68 65 20 6c 61 63 6b   due to the lack
9800: 20 6f 66 20 61 20 63 6f 6d 6d 6f 6e 0a 63 72 6f   of a common.cro
9810: 73 73 20 70 6c 61 74 66 6f 72 6d 20 64 61 74 61  ss platform data
9820: 62 61 73 65 20 6f 66 20 43 65 72 74 69 66 69 63  base of Certific
9830: 61 74 65 20 41 75 74 68 6f 72 69 74 79 20 28 43  ate Authority (C
9840: 41 29 20 70 72 6f 76 69 64 65 64 20 63 65 72 74  A) provided cert
9850: 69 66 69 63 61 74 65 73 20 74 6f 0a 76 61 6c 69  ificates to.vali
9860: 64 61 74 65 20 61 67 61 69 6e 73 74 2e 20 4d 61  date against. Ma
9870: 6e 79 20 4c 69 6e 75 78 20 73 79 73 74 65 6d 73  ny Linux systems
9880: 20 6e 61 74 69 76 65 6c 79 20 73 75 70 70 6f 72   natively suppor
9890: 74 20 4f 70 65 6e 53 53 4c 20 61 6e 64 20 74 68  t OpenSSL and th
98a0: 75 73 20 68 61 76 65 0a 74 68 65 73 65 20 63 65  us have.these ce
98b0: 72 74 69 66 69 63 61 74 65 73 20 69 6e 73 74 61  rtificates insta
98c0: 6c 6c 65 64 20 61 73 20 70 61 72 74 20 6f 66 20  lled as part of 
98d0: 74 68 65 20 4f 53 2c 20 62 75 74 20 4d 61 63 4f  the OS, but MacO
98e0: 53 20 61 6e 64 20 4d 53 20 57 69 6e 64 6f 77 73  S and MS Windows
98f0: 20 64 6f 20 6e 6f 74 2e 0a 53 74 61 72 69 6e 67   do not..Staring
9900: 20 69 6e 20 54 63 6c 54 4c 53 20 32 2e 30 2c 20   in TclTLS 2.0, 
9910: 74 68 69 73 20 68 61 73 20 62 65 65 6e 20 63 68  this has been ch
9920: 61 6e 67 65 64 20 74 6f 20 72 65 71 75 69 72 65  anged to require
9930: 20 63 65 72 74 69 66 69 63 61 74 65 20 76 61 6c   certificate val
9940: 69 64 61 74 69 6f 6e 0a 62 79 20 64 65 66 61 75  idation.by defau
9950: 6c 74 2e 20 49 6e 20 6f 72 64 65 72 20 74 6f 20  lt. In order to 
9960: 75 73 65 20 74 68 65 20 3c 62 20 63 6c 61 73 73  use the <b class
9970: 3d 22 6f 70 74 69 6f 6e 22 3e 2d 72 65 71 75 69  ="option">-requi
9980: 72 65 3c 2f 62 3e 20 6f 70 74 69 6f 6e 2c 20 6f  re</b> option, o
9990: 6e 65 20 6f 66 20 74 68 65 20 66 6f 6c 6c 6f 77  ne of the follow
99a0: 69 6e 67 0a 6d 75 73 74 20 62 65 20 74 72 75 65  ing.must be true
99b0: 3a 3c 2f 70 3e 0a 3c 75 6c 20 63 6c 61 73 73 3d  :</p>.<ul class=
99c0: 22 64 6f 63 74 6f 6f 6c 73 5f 69 74 65 6d 69 7a  "doctools_itemiz
99d0: 65 64 22 3e 0a 3c 6c 69 3e 3c 70 3e 4f 6e 20 4c  ed">.<li><p>On L
99e0: 69 6e 75 78 20 61 6e 64 20 55 6e 69 78 20 73 79  inux and Unix sy
99f0: 73 74 65 6d 73 20 77 69 74 68 20 4f 70 65 6e 53  stems with OpenS
9a00: 53 4c 20 61 6c 72 65 61 64 79 20 69 6e 73 74 61  SL already insta
9a10: 6c 6c 65 64 20 6f 72 20 69 66 20 74 68 65 20 43  lled or if the C
9a20: 41 0a 63 65 72 74 69 66 69 63 61 74 65 73 20 61  A.certificates a
9a30: 72 65 20 61 76 61 69 6c 61 62 6c 65 20 69 6e 20  re available in 
9a40: 50 45 4d 20 66 6f 72 6d 61 74 2c 20 61 6e 64 20  PEM format, and 
9a50: 69 66 20 74 68 65 79 20 61 72 65 20 73 74 6f 72  if they are stor
9a60: 65 64 20 69 6e 20 74 68 65 0a 73 74 61 6e 64 61  ed in the.standa
9a70: 72 64 20 6c 6f 63 61 74 69 6f 6e 73 2c 20 6f 72  rd locations, or
9a80: 20 69 66 20 74 68 65 20 3c 62 20 63 6c 61 73 73   if the <b class
9a90: 3d 22 76 61 72 69 61 62 6c 65 22 3e 53 53 4c 5f  ="variable">SSL_
9aa0: 43 45 52 54 5f 44 49 52 3c 2f 62 3e 20 6f 72 20  CERT_DIR</b> or 
9ab0: 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62  <b class="variab
9ac0: 6c 65 22 3e 53 53 4c 5f 43 45 52 54 5f 46 49 4c  le">SSL_CERT_FIL
9ad0: 45 3c 2f 62 3e 0a 65 6e 76 69 72 6f 6e 6d 65 6e  E</b>.environmen
9ae0: 74 20 76 61 72 69 61 62 6c 65 73 20 61 72 65 20  t variables are 
9af0: 73 65 74 2c 20 74 68 65 6e 20 3c 62 20 63 6c 61  set, then <b cla
9b00: 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 64  ss="option">-cad
9b10: 69 72 3c 2f 62 3e 2c 20 3c 62 20 63 6c 61 73 73  ir</b>, <b class
9b20: 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 64 69 72  ="option">-cadir
9b30: 3c 2f 62 3e 2c 0a 61 6e 64 20 3c 62 20 63 6c 61  </b>,.and <b cla
9b40: 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 73  ss="option">-cas
9b50: 74 6f 72 65 3c 2f 62 3e 20 61 72 65 6e 27 74 20  tore</b> aren't 
9b60: 6e 65 65 64 65 64 2e 3c 2f 70 3e 3c 2f 6c 69 3e  needed.</p></li>
9b70: 0a 3c 6c 69 3e 3c 70 3e 49 66 20 4f 70 65 6e 53  .<li><p>If OpenS
9b80: 53 4c 20 69 73 20 6e 6f 74 20 69 6e 73 74 61 6c  SL is not instal
9b90: 6c 65 64 20 69 6e 20 74 68 65 20 64 65 66 61 75  led in the defau
9ba0: 6c 74 20 6c 6f 63 61 74 69 6f 6e 2c 20 6f 72 20  lt location, or 
9bb0: 77 68 65 6e 20 75 73 69 6e 67 20 4d 61 63 20 4f  when using Mac O
9bc0: 53 0a 6f 72 20 4d 53 20 57 69 6e 64 6f 77 73 20  S.or MS Windows 
9bd0: 61 6e 64 20 4f 70 65 6e 53 53 4c 20 69 73 20 69  and OpenSSL is i
9be0: 6e 73 74 61 6c 6c 65 64 2c 20 74 68 65 20 3c 62  nstalled, the <b
9bf0: 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65   class="variable
9c00: 22 3e 53 53 4c 5f 43 45 52 54 5f 44 49 52 3c 2f  ">SSL_CERT_DIR</
9c10: 62 3e 20 61 6e 64 2f 6f 72 0a 3c 62 20 63 6c 61  b> and/or.<b cla
9c20: 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e 53 53  ss="variable">SS
9c30: 4c 5f 43 45 52 54 5f 46 49 4c 45 3c 2f 62 3e 20  L_CERT_FILE</b> 
9c40: 65 6e 76 69 72 6f 6e 6d 65 6e 74 20 76 61 72 69  environment vari
9c50: 61 62 6c 65 73 20 6f 72 20 74 68 65 20 6f 6e 65  ables or the one
9c60: 20 6f 66 20 74 68 65 20 3c 62 20 63 6c 61 73 73   of the <b class
9c70: 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 64 69 72  ="option">-cadir
9c80: 3c 2f 62 3e 2c 0a 3c 62 20 63 6c 61 73 73 3d 22  </b>,.<b class="
9c90: 6f 70 74 69 6f 6e 22 3e 2d 63 61 64 69 72 3c 2f  option">-cadir</
9ca0: 62 3e 2c 20 6f 72 20 3c 62 20 63 6c 61 73 73 3d  b>, or <b class=
9cb0: 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 73 74 6f 72  "option">-castor
9cc0: 65 3c 2f 62 3e 20 6f 70 74 69 6f 6e 73 20 6d 75  e</b> options mu
9cd0: 73 74 20 62 65 20 64 65 66 69 6e 65 64 2e 3c 2f  st be defined.</
9ce0: 70 3e 3c 2f 6c 69 3e 0a 3c 6c 69 3e 3c 70 3e 4f  p></li>.<li><p>O
9cf0: 6e 20 4d 53 20 57 69 6e 64 6f 77 73 2c 20 73 74  n MS Windows, st
9d00: 61 72 74 69 6e 67 20 69 6e 20 4f 70 65 6e 53 53  arting in OpenSS
9d10: 4c 20 33 2e 32 2c 20 69 74 20 69 73 20 6e 6f 77  L 3.2, it is now
9d20: 20 70 6f 73 73 69 62 6c 65 20 74 6f 20 61 63 63   possible to acc
9d30: 65 73 73 20 74 68 65 0a 62 75 69 6c 74 2d 69 6e  ess the.built-in
9d40: 20 57 69 6e 64 6f 77 73 20 43 65 72 74 69 66 69   Windows Certifi
9d50: 63 61 74 65 20 53 74 6f 72 65 20 66 72 6f 6d 20  cate Store from 
9d60: 4f 70 65 6e 53 53 4c 2e 20 54 68 69 73 20 63 61  OpenSSL. This ca
9d70: 6e 20 75 74 69 6c 69 7a 65 64 20 62 79 0a 73 65  n utilized by.se
9d80: 74 74 69 6e 67 20 74 68 65 20 3c 62 20 63 6c 61  tting the <b cla
9d90: 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 73  ss="option">-cas
9da0: 74 6f 72 65 3c 2f 62 3e 20 6f 70 74 69 6f 6e 20  tore</b> option 
9db0: 74 6f 20 26 71 75 6f 74 3b 3c 62 20 63 6c 61 73  to &quot;<b clas
9dc0: 73 3d 22 63 6f 6e 73 74 22 3e 6f 72 67 2e 6f 70  s="const">org.op
9dd0: 65 6e 73 73 6c 2e 77 69 6e 73 74 6f 72 65 3a 2f  enssl.winstore:/
9de0: 2f 3c 2f 62 3e 26 71 75 6f 74 3b 2e 0a 49 6e 20  /</b>&quot;..In 
9df0: 54 63 6c 54 4c 53 20 32 2e 30 2c 20 74 68 69 73  TclTLS 2.0, this
9e00: 20 69 73 20 74 68 65 20 64 65 66 61 75 6c 74 20   is the default 
9e10: 76 61 6c 75 65 20 69 66 20 3c 62 20 63 6c 61 73  value if <b clas
9e20: 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 64 69  s="option">-cadi
9e30: 72 3c 2f 62 3e 2c 0a 3c 62 20 63 6c 61 73 73 3d  r</b>,.<b class=
9e40: 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 64 69 72 3c  "option">-cadir<
9e50: 2f 62 3e 2c 20 61 6e 64 20 3c 62 20 63 6c 61 73  /b>, and <b clas
9e60: 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 73 74  s="option">-cast
9e70: 6f 72 65 3c 2f 62 3e 20 61 72 65 20 6e 6f 74 20  ore</b> are not 
9e80: 73 70 65 63 69 66 69 65 64 2e 3c 2f 70 3e 3c 2f  specified.</p></
9e90: 6c 69 3e 0a 3c 6c 69 3e 3c 70 3e 49 66 20 4f 70  li>.<li><p>If Op
9ea0: 65 6e 53 53 4c 20 69 73 20 6e 6f 74 20 69 6e 73  enSSL is not ins
9eb0: 74 61 6c 6c 65 64 20 6f 72 20 74 68 65 20 43 41  talled or the CA
9ec0: 20 63 65 72 74 69 66 69 63 61 74 65 73 20 61 72   certificates ar
9ed0: 65 20 6e 6f 74 20 61 76 61 69 6c 61 62 6c 65 20  e not available 
9ee0: 69 6e 20 50 45 4d 0a 66 6f 72 6d 61 74 2c 20 74  in PEM.format, t
9ef0: 68 65 20 43 41 20 63 65 72 74 69 66 69 63 61 74  he CA certificat
9f00: 65 73 20 6d 75 73 74 20 62 65 20 64 6f 77 6e 6c  es must be downl
9f10: 6f 61 64 65 64 20 61 6e 64 20 69 6e 73 74 61 6c  oaded and instal
9f20: 6c 65 64 20 77 69 74 68 20 74 68 65 20 75 73 65  led with the use
9f30: 72 0a 73 6f 66 74 77 61 72 65 2e 20 54 68 65 20  r.software. The 
9f40: 43 55 52 4c 20 74 65 61 6d 20 6d 61 6b 65 73 20  CURL team makes 
9f50: 74 68 65 6d 20 61 76 61 69 6c 61 62 6c 65 20 61  them available a
9f60: 74 0a 3c 61 20 68 72 65 66 3d 22 68 74 74 70 73  t.<a href="https
9f70: 3a 2f 2f 63 75 72 6c 2e 73 65 2f 64 6f 63 73 2f  ://curl.se/docs/
9f80: 63 61 65 78 74 72 61 63 74 2e 68 74 6d 6c 22 3e  caextract.html">
9f90: 43 41 20 63 65 72 74 69 66 69 63 61 74 65 73 20  CA certificates 
9fa0: 65 78 74 72 61 63 74 65 64 0a 66 72 6f 6d 20 4d  extracted.from M
9fb0: 6f 7a 69 6c 6c 61 3c 2f 61 3e 20 69 6e 20 74 68  ozilla</a> in th
9fc0: 65 20 26 71 75 6f 74 3b 3c 62 20 63 6c 61 73 73  e &quot;<b class
9fd0: 3d 22 66 69 6c 65 22 3e 63 61 63 65 72 74 2e 70  ="file">cacert.p
9fe0: 65 6d 3c 2f 62 3e 26 71 75 6f 74 3b 20 66 69 6c  em</b>&quot; fil
9ff0: 65 2e 20 59 6f 75 20 6d 75 73 74 20 74 68 65 6e  e. You must then
a000: 20 65 69 74 68 65 72 20 73 65 74 20 74 68 65 0a   either set the.
a010: 3c 62 20 63 6c 61 73 73 3d 22 76 61 72 69 61 62  <b class="variab
a020: 6c 65 22 3e 53 53 4c 5f 43 45 52 54 5f 44 49 52  le">SSL_CERT_DIR
a030: 3c 2f 62 3e 20 61 6e 64 2f 6f 72 20 3c 62 20 63  </b> and/or <b c
a040: 6c 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e  lass="variable">
a050: 53 53 4c 5f 43 45 52 54 5f 46 49 4c 45 3c 2f 62  SSL_CERT_FILE</b
a060: 3e 20 65 6e 76 69 72 6f 6e 6d 65 6e 74 20 76 61  > environment va
a070: 72 69 61 62 6c 65 73 20 6f 72 20 74 68 65 0a 3c  riables or the.<
a080: 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22  b class="option"
a090: 3e 2d 63 61 64 69 72 3c 2f 62 3e 20 6f 72 20 3c  >-cadir</b> or <
a0a0: 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22  b class="option"
a0b0: 3e 2d 63 61 66 69 6c 65 3c 2f 62 3e 20 6f 70 74  >-cafile</b> opt
a0c0: 69 6f 6e 73 20 74 6f 20 74 68 65 20 43 41 20 63  ions to the CA c
a0d0: 65 72 74 20 66 69 6c 65 27 73 20 69 6e 73 74 61  ert file's insta
a0e0: 6c 6c 0a 6c 6f 63 61 74 69 6f 6e 2e 20 49 74 20  ll.location. It 
a0f0: 69 73 20 79 6f 75 72 20 72 65 73 70 6f 6e 73 69  is your responsi
a100: 62 69 6c 69 74 79 20 74 6f 20 6b 65 65 70 20 74  bility to keep t
a110: 68 69 73 20 66 69 6c 65 20 75 70 20 74 6f 20 64  his file up to d
a120: 61 74 65 2e 3c 2f 70 3e 3c 2f 6c 69 3e 0a 3c 2f  ate.</p></li>.</
a130: 75 6c 3e 0a 3c 2f 64 69 76 3e 0a 3c 2f 64 69 76  ul>.</div>.</div
a140: 3e 0a 3c 64 69 76 20 69 64 3d 22 73 65 63 74 69  >.<div id="secti
a150: 6f 6e 35 22 20 63 6c 61 73 73 3d 22 64 6f 63 74  on5" class="doct
a160: 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c 68  ools_section"><h
a170: 32 3e 3c 61 20 6e 61 6d 65 3d 22 73 65 63 74 69  2><a name="secti
a180: 6f 6e 35 22 3e 43 61 6c 6c 62 61 63 6b 20 4f 70  on5">Callback Op
a190: 74 69 6f 6e 73 3c 2f 61 3e 3c 2f 68 32 3e 0a 3c  tions</a></h2>.<
a1a0: 70 3e 41 73 20 70 72 65 76 69 6f 75 73 6c 79 20  p>As previously 
a1b0: 64 65 73 63 72 69 62 65 64 2c 20 65 61 63 68 20  described, each 
a1c0: 63 68 61 6e 6e 65 6c 20 63 61 6e 20 62 65 20 67  channel can be g
a1d0: 69 76 65 6e 20 74 68 65 69 72 20 6f 77 6e 20 63  iven their own c
a1e0: 61 6c 6c 62 61 63 6b 73 0a 74 6f 20 68 61 6e 64  allbacks.to hand
a1f0: 6c 65 20 69 6e 74 65 72 6d 65 64 69 61 74 65 20  le intermediate 
a200: 70 72 6f 63 65 73 73 69 6e 67 20 62 79 20 74 68  processing by th
a210: 65 20 4f 70 65 6e 53 53 4c 20 6c 69 62 72 61 72  e OpenSSL librar
a220: 79 2c 20 75 73 69 6e 67 20 74 68 65 0a 3c 62 20  y, using the.<b 
a230: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
a240: 63 6f 6d 6d 61 6e 64 3c 2f 62 3e 2c 20 3c 62 20  command</b>, <b 
a250: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
a260: 70 61 73 73 77 6f 72 64 3c 2f 62 3e 2c 20 61 6e  password</b>, an
a270: 64 20 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  d <b class="opti
a280: 6f 6e 22 3e 2d 76 61 6c 69 64 61 74 65 5f 63 6f  on">-validate_co
a290: 6d 6d 61 6e 64 3c 2f 62 3e 20 6f 70 74 69 6f 6e  mmand</b> option
a2a0: 73 0a 70 61 73 73 65 64 20 74 6f 20 65 69 74 68  s.passed to eith
a2b0: 65 72 20 6f 66 20 3c 62 20 63 6c 61 73 73 3d 22  er of <b class="
a2c0: 63 6d 64 22 3e 74 6c 73 3a 3a 73 6f 63 6b 65 74  cmd">tls::socket
a2d0: 3c 2f 62 3e 20 6f 72 20 3c 62 20 63 6c 61 73 73  </b> or <b class
a2e0: 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 69 6d 70 6f  ="cmd">tls::impo
a2f0: 72 74 3c 2f 62 3e 2e 0a 55 6e 6c 69 6b 65 20 70  rt</b>..Unlike p
a300: 72 65 76 69 6f 75 73 20 76 65 72 73 69 6f 6e 73  revious versions
a310: 20 6f 66 20 54 63 6c 54 4c 53 2c 20 6f 6e 6c 79   of TclTLS, only
a320: 20 69 66 20 74 68 65 20 63 61 6c 6c 62 61 63 6b   if the callback
a330: 20 67 65 6e 65 72 61 74 65 73 20 61 6e 20 65 72   generates an er
a340: 72 6f 72 2c 0a 77 69 6c 6c 20 74 68 65 20 3c 62  ror,.will the <b
a350: 20 63 6c 61 73 73 3d 22 73 79 73 63 6d 64 22 3e   class="syscmd">
a360: 62 67 65 72 72 6f 72 3c 2f 62 3e 20 63 6f 6d 6d  bgerror</b> comm
a370: 61 6e 64 20 62 65 20 69 6e 76 6f 6b 65 64 20 77  and be invoked w
a380: 69 74 68 20 74 68 65 20 65 72 72 6f 72 20 69 6e  ith the error in
a390: 66 6f 72 6d 61 74 69 6f 6e 2e 3c 2f 70 3e 0a 3c  formation.</p>.<
a3a0: 64 69 76 20 69 64 3d 22 73 75 62 73 65 63 74 69  div id="subsecti
a3b0: 6f 6e 34 22 20 63 6c 61 73 73 3d 22 64 6f 63 74  on4" class="doct
a3c0: 6f 6f 6c 73 5f 73 75 62 73 65 63 74 69 6f 6e 22  ools_subsection"
a3d0: 3e 3c 68 33 3e 3c 61 20 6e 61 6d 65 3d 22 73 75  ><h3><a name="su
a3e0: 62 73 65 63 74 69 6f 6e 34 22 3e 56 61 6c 75 65  bsection4">Value
a3f0: 73 20 66 6f 72 20 43 6f 6d 6d 61 6e 64 20 43 61  s for Command Ca
a400: 6c 6c 62 61 63 6b 3c 2f 61 3e 3c 2f 68 33 3e 0a  llback</a></h3>.
a410: 3c 70 3e 54 68 65 20 63 61 6c 6c 62 61 63 6b 20  <p>The callback 
a420: 66 6f 72 20 74 68 65 20 3c 62 20 63 6c 61 73 73  for the <b class
a430: 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 6f 6d 6d 61  ="option">-comma
a440: 6e 64 3c 2f 62 3e 20 6f 70 74 69 6f 6e 20 69 73  nd</b> option is
a450: 20 69 6e 76 6f 6b 65 64 20 61 74 20 73 65 76 65   invoked at seve
a460: 72 61 6c 20 70 6f 69 6e 74 73 20 64 75 72 69 6e  ral points durin
a470: 67 20 74 68 65 0a 4f 70 65 6e 53 53 4c 20 68 61  g the.OpenSSL ha
a480: 6e 64 73 68 61 6b 65 20 61 6e 64 20 64 75 72 69  ndshake and duri
a490: 6e 67 20 72 6f 75 74 69 6e 65 20 6f 70 65 72 61  ng routine opera
a4a0: 74 69 6f 6e 73 2e 20 53 65 65 20 62 65 6c 6f 77  tions. See below
a4b0: 20 66 6f 72 20 74 68 65 20 70 6f 73 73 69 62 6c   for the possibl
a4c0: 65 0a 61 72 67 75 6d 65 6e 74 73 20 70 61 73 73  e.arguments pass
a4d0: 65 64 20 74 6f 20 74 68 65 20 63 61 6c 6c 62 61  ed to the callba
a4e0: 63 6b 20 73 63 72 69 70 74 2e 20 56 61 6c 75 65  ck script. Value
a4f0: 73 20 72 65 74 75 72 6e 65 64 20 66 72 6f 6d 20  s returned from 
a500: 74 68 65 20 63 61 6c 6c 62 61 63 6b 20 61 72 65  the callback are
a510: 0a 69 67 6e 6f 72 65 64 2e 3c 2f 70 3e 0a 3c 64  .ignored.</p>.<d
a520: 6c 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c  l class="doctool
a530: 73 5f 6f 70 74 69 6f 6e 73 22 3e 0a 3c 64 74 3e  s_options">.<dt>
a540: 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e  <b class="option
a550: 22 3e 65 72 72 6f 72 3c 2f 62 3e 20 3c 69 20 63  ">error</b> <i c
a560: 6c 61 73 73 3d 22 61 72 67 22 3e 63 68 61 6e 6e  lass="arg">chann
a570: 65 6c 49 64 20 6d 65 73 73 61 67 65 3c 2f 69 3e  elId message</i>
a580: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 69  </dt>.<dd><p>Thi
a590: 73 20 66 6f 72 6d 20 6f 66 20 63 61 6c 6c 62 61  s form of callba
a5a0: 63 6b 20 69 73 20 69 6e 76 6f 6b 65 64 20 77 68  ck is invoked wh
a5b0: 65 6e 65 76 65 72 20 61 6e 20 65 72 72 6f 72 20  enever an error 
a5c0: 6f 63 63 75 72 73 20 64 75 72 69 6e 67 20 74 68  occurs during th
a5d0: 65 20 69 6e 69 74 69 61 6c 0a 63 6f 6e 6e 65 63  e initial.connec
a5e0: 74 69 6f 6e 2c 20 68 61 6e 64 73 68 61 6b 65 2c  tion, handshake,
a5f0: 20 6f 72 20 49 2f 4f 20 6f 70 65 72 61 74 69 6f   or I/O operatio
a600: 6e 73 2e 20 54 68 65 20 3c 69 20 63 6c 61 73 73  ns. The <i class
a610: 3d 22 61 72 67 22 3e 6d 65 73 73 61 67 65 3c 2f  ="arg">message</
a620: 69 3e 20 61 72 67 75 6d 65 6e 74 20 63 61 6e 20  i> argument can 
a630: 62 65 0a 66 72 6f 6d 20 74 68 65 20 54 63 6c 5f  be.from the Tcl_
a640: 45 72 72 6e 6f 4d 73 67 2c 20 4f 70 65 6e 53 53  ErrnoMsg, OpenSS
a650: 4c 20 66 75 6e 63 74 69 6f 6e 20 3c 62 20 63 6c  L function <b cl
a660: 61 73 73 3d 22 66 75 6e 63 74 69 6f 6e 22 3e 45  ass="function">E
a670: 52 52 5f 72 65 61 73 6f 6e 5f 65 72 72 6f 72 5f  RR_reason_error_
a680: 73 74 72 69 6e 67 28 29 3c 2f 62 3e 2c 0a 6f 72  string()</b>,.or
a690: 20 61 20 63 75 73 74 6f 6d 20 6d 65 73 73 61 67   a custom messag
a6a0: 65 2e 20 54 68 69 73 20 63 61 6c 6c 62 61 63 6b  e. This callback
a6b0: 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54   is new for TclT
a6c0: 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e  LS 1.8.</p></dd>
a6d0: 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f  .<dt><b class="o
a6e0: 70 74 69 6f 6e 22 3e 69 6e 66 6f 3c 2f 62 3e 20  ption">info</b> 
a6f0: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 63  <i class="arg">c
a700: 68 61 6e 6e 65 6c 49 64 20 6d 61 6a 6f 72 20 6d  hannelId major m
a710: 69 6e 6f 72 20 6d 65 73 73 61 67 65 20 74 79 70  inor message typ
a720: 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c  e</i></dt>.<dd><
a730: 70 3e 54 68 69 73 20 66 6f 72 6d 20 6f 66 20 63  p>This form of c
a740: 61 6c 6c 62 61 63 6b 20 69 73 20 69 6e 76 6f 6b  allback is invok
a750: 65 64 20 62 79 20 74 68 65 20 4f 70 65 6e 53 53  ed by the OpenSS
a760: 4c 20 66 75 6e 63 74 69 6f 6e 0a 3c 62 20 63 6c  L function.<b cl
a770: 61 73 73 3d 22 66 75 6e 63 74 69 6f 6e 22 3e 53  ass="function">S
a780: 53 4c 5f 73 65 74 5f 69 6e 66 6f 5f 63 61 6c 6c  SL_set_info_call
a790: 62 61 63 6b 28 29 3c 2f 62 3e 20 64 75 72 69 6e  back()</b> durin
a7a0: 67 20 74 68 65 20 69 6e 69 74 69 61 6c 20 63 6f  g the initial co
a7b0: 6e 6e 65 63 74 69 6f 6e 20 61 6e 64 20 68 61 6e  nnection and han
a7c0: 64 73 68 61 6b 65 0a 6f 70 65 72 61 74 69 6f 6e  dshake.operation
a7d0: 73 2e 20 54 68 65 20 61 72 67 75 6d 65 6e 74 73  s. The arguments
a7e0: 20 61 72 65 3a 3c 2f 70 3e 0a 3c 64 6c 20 63 6c   are:</p>.<dl cl
a7f0: 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 64 65  ass="doctools_de
a800: 66 69 6e 69 74 69 6f 6e 73 22 3e 0a 3c 64 74 3e  finitions">.<dt>
a810: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 6d  <i class="arg">m
a820: 61 6a 6f 72 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64  ajor</i></dt>.<d
a830: 64 3e 3c 70 3e 4d 61 6a 6f 72 20 63 61 74 65 67  d><p>Major categ
a840: 6f 72 79 20 66 6f 72 20 65 72 72 6f 72 2e 20 56  ory for error. V
a850: 61 6c 69 64 20 65 6e 75 6d 73 20 61 72 65 3a 20  alid enums are: 
a860: 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22  <b class="const"
a870: 3e 68 61 6e 64 73 68 61 6b 65 3c 2f 62 3e 2c 20  >handshake</b>, 
a880: 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22  <b class="const"
a890: 3e 61 6c 65 72 74 3c 2f 62 3e 2c 0a 3c 62 20 63  >alert</b>,.<b c
a8a0: 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 63 6f 6e  lass="const">con
a8b0: 6e 65 63 74 3c 2f 62 3e 2c 20 3c 62 20 63 6c 61  nect</b>, <b cla
a8c0: 73 73 3d 22 63 6f 6e 73 74 22 3e 61 63 63 65 70  ss="const">accep
a8d0: 74 3c 2f 62 3e 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a  t</b>.</p></dd>.
a8e0: 3c 64 74 3e 3c 69 20 63 6c 61 73 73 3d 22 61 72  <dt><i class="ar
a8f0: 67 22 3e 6d 69 6e 6f 72 3c 2f 69 3e 3c 2f 64 74  g">minor</i></dt
a900: 3e 0a 3c 64 64 3e 3c 70 3e 4d 69 6e 6f 72 20 63  >.<dd><p>Minor c
a910: 61 74 65 67 6f 72 79 20 66 6f 72 20 65 72 72 6f  ategory for erro
a920: 72 2e 20 56 61 6c 69 64 20 65 6e 75 6d 73 20 61  r. Valid enums a
a930: 72 65 3a 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f  re: <b class="co
a940: 6e 73 74 22 3e 73 74 61 72 74 3c 2f 62 3e 2c 20  nst">start</b>, 
a950: 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22  <b class="const"
a960: 3e 64 6f 6e 65 3c 2f 62 3e 2c 20 3c 62 20 63 6c  >done</b>, <b cl
a970: 61 73 73 3d 22 63 6f 6e 73 74 22 3e 72 65 61 64  ass="const">read
a980: 3c 2f 62 3e 2c 0a 3c 62 20 63 6c 61 73 73 3d 22  </b>,.<b class="
a990: 63 6f 6e 73 74 22 3e 77 72 69 74 65 3c 2f 62 3e  const">write</b>
a9a0: 2c 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73  , <b class="cons
a9b0: 74 22 3e 6c 6f 6f 70 3c 2f 62 3e 2c 20 3c 62 20  t">loop</b>, <b 
a9c0: 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 65 78  class="const">ex
a9d0: 69 74 3c 2f 62 3e 2e 3c 2f 70 3e 3c 2f 64 64 3e  it</b>.</p></dd>
a9e0: 0a 3c 64 74 3e 3c 69 20 63 6c 61 73 73 3d 22 61  .<dt><i class="a
a9f0: 72 67 22 3e 6d 65 73 73 61 67 65 3c 2f 69 3e 3c  rg">message</i><
aa00: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 44 65 73 63  /dt>.<dd><p>Desc
aa10: 72 69 70 74 69 76 65 20 6d 65 73 73 61 67 65 20  riptive message 
aa20: 73 74 72 69 6e 67 20 77 68 69 63 68 20 6d 61 79  string which may
aa30: 20 62 65 20 67 65 6e 65 72 61 74 65 64 20 65 69   be generated ei
aa40: 74 68 65 72 20 62 79 0a 3c 62 20 63 6c 61 73 73  ther by.<b class
aa50: 3d 22 66 75 6e 63 74 69 6f 6e 22 3e 53 53 4c 5f  ="function">SSL_
aa60: 73 74 61 74 65 5f 73 74 72 69 6e 67 5f 6c 6f 6e  state_string_lon
aa70: 67 28 29 3c 2f 62 3e 20 6f 72 20 3c 62 20 63 6c  g()</b> or <b cl
aa80: 61 73 73 3d 22 66 75 6e 63 74 69 6f 6e 22 3e 53  ass="function">S
aa90: 53 4c 5f 61 6c 65 72 74 5f 64 65 73 63 5f 73 74  SL_alert_desc_st
aaa0: 72 69 6e 67 5f 6c 6f 6e 67 28 29 3c 2f 62 3e 2c  ring_long()</b>,
aab0: 0a 64 65 70 65 6e 64 69 6e 67 20 6f 6e 20 74 68  .depending on th
aac0: 65 20 63 6f 6e 74 65 78 74 2e 3c 2f 70 3e 3c 2f  e context.</p></
aad0: 64 64 3e 0a 3c 64 74 3e 3c 69 20 63 6c 61 73 73  dd>.<dt><i class
aae0: 3d 22 61 72 67 22 3e 74 79 70 65 3c 2f 69 3e 3c  ="arg">type</i><
aaf0: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 46 6f 72 20  /dt>.<dd><p>For 
ab00: 61 6c 65 72 74 73 2c 20 74 68 65 20 70 6f 73 73  alerts, the poss
ab10: 69 62 6c 65 20 76 61 6c 75 65 73 20 61 72 65 3a  ible values are:
ab20: 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74   <b class="const
ab30: 22 3e 77 61 72 6e 69 6e 67 3c 2f 62 3e 2c 0a 3c  ">warning</b>,.<
ab40: 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e  b class="const">
ab50: 66 61 74 61 6c 3c 2f 62 3e 2c 20 61 6e 64 20 3c  fatal</b>, and <
ab60: 62 20 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e  b class="const">
ab70: 75 6e 6b 6e 6f 77 6e 3c 2f 62 3e 2e 20 46 6f 72  unknown</b>. For
ab80: 20 6f 74 68 65 72 73 2c 20 3c 62 20 63 6c 61 73   others, <b clas
ab90: 73 3d 22 63 6f 6e 73 74 22 3e 69 6e 66 6f 3c 2f  s="const">info</
aba0: 62 3e 20 69 73 20 75 73 65 64 2e 0a 54 68 69 73  b> is used..This
abb0: 20 61 72 67 75 6d 65 6e 74 20 69 73 20 6e 65 77   argument is new
abc0: 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 2e 38 2e   for TclTLS 1.8.
abd0: 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 2f 64 6c 3e 3c  </p></dd>.</dl><
abe0: 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73  /dd>.<dt><b clas
abf0: 73 3d 22 6f 70 74 69 6f 6e 22 3e 6d 65 73 73 61  s="option">messa
ac00: 67 65 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  ge</b> <i class=
ac10: 22 61 72 67 22 3e 63 68 61 6e 6e 65 6c 49 64 20  "arg">channelId 
ac20: 64 69 72 65 63 74 69 6f 6e 20 76 65 72 73 69 6f  direction versio
ac30: 6e 20 63 6f 6e 74 65 6e 74 5f 74 79 70 65 20 6d  n content_type m
ac40: 65 73 73 61 67 65 3c 2f 69 3e 3c 2f 64 74 3e 0a  essage</i></dt>.
ac50: 3c 64 64 3e 3c 70 3e 54 68 69 73 20 66 6f 72 6d  <dd><p>This form
ac60: 20 6f 66 20 63 61 6c 6c 62 61 63 6b 20 69 73 20   of callback is 
ac70: 69 6e 76 6f 6b 65 64 20 62 79 20 74 68 65 20 4f  invoked by the O
ac80: 70 65 6e 53 53 4c 20 66 75 6e 63 74 69 6f 6e 0a  penSSL function.
ac90: 3c 62 20 63 6c 61 73 73 3d 22 66 75 6e 63 74 69  <b class="functi
aca0: 6f 6e 22 3e 53 53 4c 5f 73 65 74 5f 6d 73 67 5f  on">SSL_set_msg_
acb0: 63 61 6c 6c 62 61 63 6b 28 29 3c 2f 62 3e 20 77  callback()</b> w
acc0: 68 65 6e 65 76 65 72 20 61 20 6d 65 73 73 61 67  henever a messag
acd0: 65 20 69 73 20 73 65 6e 74 20 6f 72 20 72 65 63  e is sent or rec
ace0: 65 69 76 65 64 20 64 75 72 69 6e 67 20 74 68 65  eived during the
acf0: 0a 69 6e 69 74 69 61 6c 20 63 6f 6e 6e 65 63 74  .initial connect
ad00: 69 6f 6e 2c 20 68 61 6e 64 73 68 61 6b 65 2c 20  ion, handshake, 
ad10: 6f 72 20 49 2f 4f 20 6f 70 65 72 61 74 69 6f 6e  or I/O operation
ad20: 73 2e 20 49 74 20 69 73 20 6f 6e 6c 79 20 61 76  s. It is only av
ad30: 61 69 6c 61 62 6c 65 20 77 68 65 6e 0a 4f 70 65  ailable when.Ope
ad40: 6e 53 53 4c 20 69 73 20 63 6f 6d 70 6c 69 65 64  nSSL is complied
ad50: 20 77 69 74 68 20 74 68 65 20 3c 62 20 63 6c 61   with the <b cla
ad60: 73 73 3d 22 63 6f 6e 73 74 22 3e 65 6e 61 62 6c  ss="const">enabl
ad70: 65 2d 73 73 6c 2d 74 72 61 63 65 3c 2f 62 3e 20  e-ssl-trace</b> 
ad80: 6f 70 74 69 6f 6e 2e 20 54 68 69 73 20 63 61 6c  option. This cal
ad90: 6c 62 61 63 6b 20 69 73 0a 6e 65 77 20 66 6f 72  lback is.new for
ada0: 20 54 63 6c 54 4c 53 20 31 2e 38 2e 20 54 68 65   TclTLS 1.8. The
adb0: 20 61 72 67 75 6d 65 6e 74 73 20 61 72 65 3a 3c   arguments are:<
adc0: 2f 70 3e 0a 3c 64 6c 20 63 6c 61 73 73 3d 22 64  /p>.<dl class="d
add0: 6f 63 74 6f 6f 6c 73 5f 64 65 66 69 6e 69 74 69  octools_definiti
ade0: 6f 6e 73 22 3e 0a 3c 64 74 3e 3c 69 20 63 6c 61  ons">.<dt><i cla
adf0: 73 73 3d 22 61 72 67 22 3e 64 69 72 65 63 74 69  ss="arg">directi
ae00: 6f 6e 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  on</i></dt>.<dd>
ae10: 3c 70 3e 44 69 72 65 63 74 69 6f 6e 20 69 73 20  <p>Direction is 
ae20: 65 69 74 68 65 72 20 3c 62 20 63 6c 61 73 73 3d  either <b class=
ae30: 22 63 6f 6e 73 74 22 3e 53 65 6e 74 3c 2f 62 3e  "const">Sent</b>
ae40: 20 6f 72 20 3c 62 20 63 6c 61 73 73 3d 22 63 6f   or <b class="co
ae50: 6e 73 74 22 3e 52 65 63 65 69 76 65 64 3c 2f 62  nst">Received</b
ae60: 3e 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  >.</p></dd>.<dt>
ae70: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 76  <i class="arg">v
ae80: 65 72 73 69 6f 6e 3c 2f 69 3e 3c 2f 64 74 3e 0a  ersion</i></dt>.
ae90: 3c 64 64 3e 3c 70 3e 56 65 72 73 69 6f 6e 20 69  <dd><p>Version i
aea0: 73 20 74 68 65 20 70 72 6f 74 6f 63 6f 6c 20 76  s the protocol v
aeb0: 65 72 73 69 6f 6e 2e 3c 2f 70 3e 3c 2f 64 64 3e  ersion.</p></dd>
aec0: 0a 3c 64 74 3e 3c 69 20 63 6c 61 73 73 3d 22 61  .<dt><i class="a
aed0: 72 67 22 3e 63 6f 6e 74 65 6e 74 5f 74 79 70 65  rg">content_type
aee0: 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70  </i></dt>.<dd><p
aef0: 3e 43 6f 6e 74 65 6e 74 20 74 79 70 65 20 69 73  >Content type is
af00: 20 74 68 65 20 6d 65 73 73 61 67 65 20 63 6f 6e   the message con
af10: 74 65 6e 74 20 74 79 70 65 2e 3c 2f 70 3e 3c 2f  tent type.</p></
af20: 64 64 3e 0a 3c 64 74 3e 3c 69 20 63 6c 61 73 73  dd>.<dt><i class
af30: 3d 22 61 72 67 22 3e 6d 65 73 73 61 67 65 3c 2f  ="arg">message</
af40: 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 4d  i></dt>.<dd><p>M
af50: 65 73 73 61 67 65 20 69 73 20 6d 6f 72 65 20 69  essage is more i
af60: 6e 66 6f 20 66 72 6f 6d 20 74 68 65 20 3c 62 20  nfo from the <b 
af70: 63 6c 61 73 73 3d 22 63 6f 6e 73 74 22 3e 53 53  class="const">SS
af80: 4c 5f 74 72 61 63 65 3c 2f 62 3e 20 41 50 49 2e  L_trace</b> API.
af90: 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 2f 64 6c 3e 3c  </p></dd>.</dl><
afa0: 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73  /dd>.<dt><b clas
afb0: 73 3d 22 6f 70 74 69 6f 6e 22 3e 73 65 73 73 69  s="option">sessi
afc0: 6f 6e 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d  on</b> <i class=
afd0: 22 61 72 67 22 3e 63 68 61 6e 6e 65 6c 49 64 20  "arg">channelId 
afe0: 73 65 73 73 69 6f 6e 5f 69 64 20 73 65 73 73 69  session_id sessi
aff0: 6f 6e 5f 74 69 63 6b 65 74 20 6c 69 66 65 74 69  on_ticket lifeti
b000: 6d 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64 3e  me</i></dt>.<dd>
b010: 3c 70 3e 54 68 69 73 20 66 6f 72 6d 20 6f 66 20  <p>This form of 
b020: 63 61 6c 6c 62 61 63 6b 20 69 73 20 69 6e 76 6f  callback is invo
b030: 6b 65 64 20 62 79 20 74 68 65 20 4f 70 65 6e 53  ked by the OpenS
b040: 53 4c 20 66 75 6e 63 74 69 6f 6e 0a 3c 62 20 63  SL function.<b c
b050: 6c 61 73 73 3d 22 66 75 6e 63 74 69 6f 6e 22 3e  lass="function">
b060: 53 53 4c 5f 43 54 58 5f 73 65 73 73 5f 73 65 74  SSL_CTX_sess_set
b070: 5f 6e 65 77 5f 63 62 28 29 3c 2f 62 3e 20 77 68  _new_cb()</b> wh
b080: 65 6e 65 76 65 72 20 61 20 6e 65 77 20 73 65 73  enever a new ses
b090: 73 69 6f 6e 20 69 64 20 69 73 20 73 65 6e 74 20  sion id is sent 
b0a0: 62 79 20 74 68 65 0a 73 65 72 76 65 72 20 64 75  by the.server du
b0b0: 72 69 6e 67 20 74 68 65 20 69 6e 69 74 69 61 6c  ring the initial
b0c0: 20 63 6f 6e 6e 65 63 74 69 6f 6e 20 61 6e 64 20   connection and 
b0d0: 68 61 6e 64 73 68 61 6b 65 20 61 6e 64 20 61 6c  handshake and al
b0e0: 73 6f 20 64 75 72 69 6e 67 20 74 68 65 20 73 65  so during the se
b0f0: 73 73 69 6f 6e 0a 69 66 20 74 68 65 20 3c 62 20  ssion.if the <b 
b100: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
b110: 70 6f 73 74 5f 68 61 6e 64 73 68 61 6b 65 3c 2f  post_handshake</
b120: 62 3e 20 6f 70 74 69 6f 6e 20 69 73 20 73 65 74  b> option is set
b130: 20 74 6f 20 74 72 75 65 2e 20 54 68 69 73 20 63   to true. This c
b140: 61 6c 6c 62 61 63 6b 20 69 73 20 6e 65 77 20 66  allback is new f
b150: 6f 72 0a 54 63 6c 54 4c 53 20 31 2e 38 2e 20 54  or.TclTLS 1.8. T
b160: 68 65 20 61 72 67 75 6d 65 6e 74 73 20 61 72 65  he arguments are
b170: 3a 3c 2f 70 3e 0a 3c 64 6c 20 63 6c 61 73 73 3d  :</p>.<dl class=
b180: 22 64 6f 63 74 6f 6f 6c 73 5f 64 65 66 69 6e 69  "doctools_defini
b190: 74 69 6f 6e 73 22 3e 0a 3c 64 74 3e 3c 69 20 63  tions">.<dt><i c
b1a0: 6c 61 73 73 3d 22 61 72 67 22 3e 73 65 73 73 69  lass="arg">sessi
b1b0: 6f 6e 5f 69 64 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c  on_id</i></dt>.<
b1c0: 64 64 3e 3c 70 3e 53 65 73 73 69 6f 6e 20 49 64  dd><p>Session Id
b1d0: 20 69 73 20 74 68 65 20 63 75 72 72 65 6e 74 20   is the current 
b1e0: 73 65 73 73 69 6f 6e 20 69 64 65 6e 74 69 66 69  session identifi
b1f0: 65 72 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e  er</p></dd>.<dt>
b200: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 73  <i class="arg">s
b210: 65 73 73 69 6f 6e 5f 74 69 63 6b 65 74 3c 2f 69  ession_ticket</i
b220: 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 69  ></dt>.<dd><p>Ti
b230: 63 6b 65 74 20 69 73 20 74 68 65 20 73 65 73 73  cket is the sess
b240: 69 6f 6e 20 74 69 63 6b 65 74 20 69 6e 66 6f 3c  ion ticket info<
b250: 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c 69 20  /p></dd>.<dt><i 
b260: 63 6c 61 73 73 3d 22 61 72 67 22 3e 6c 69 66 65  class="arg">life
b270: 74 69 6d 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64  time</i></dt>.<d
b280: 64 3e 3c 70 3e 4c 69 66 65 74 69 6d 65 20 69 73  d><p>Lifetime is
b290: 20 74 68 65 20 74 69 63 6b 65 74 20 6c 69 66 65   the ticket life
b2a0: 74 69 6d 65 20 69 6e 20 73 65 63 6f 6e 64 73 2e  time in seconds.
b2b0: 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 2f 64 6c 3e 3c  </p></dd>.</dl><
b2c0: 2f 64 64 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73  /dd>.<dt><b clas
b2d0: 73 3d 22 6f 70 74 69 6f 6e 22 3e 76 65 72 69 66  s="option">verif
b2e0: 79 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22  y</b> <i class="
b2f0: 61 72 67 22 3e 63 68 61 6e 6e 65 6c 49 64 20 64  arg">channelId d
b300: 65 70 74 68 20 63 65 72 74 20 73 74 61 74 75 73  epth cert status
b310: 20 65 72 72 6f 72 3c 2f 69 3e 3c 2f 64 74 3e 0a   error</i></dt>.
b320: 3c 64 64 3e 3c 70 3e 54 68 69 73 20 63 61 6c 6c  <dd><p>This call
b330: 62 61 63 6b 20 77 61 73 20 6d 6f 76 65 64 20 74  back was moved t
b340: 6f 20 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  o <b class="opti
b350: 6f 6e 22 3e 2d 76 61 6c 69 64 61 74 65 63 6f 6d  on">-validatecom
b360: 6d 61 6e 64 3c 2f 62 3e 20 69 6e 20 54 63 6c 54  mand</b> in TclT
b370: 4c 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e  LS 1.8.</p></dd>
b380: 0a 3c 2f 64 6c 3e 0a 3c 2f 64 69 76 3e 0a 3c 64  .</dl>.</div>.<d
b390: 69 76 20 69 64 3d 22 73 75 62 73 65 63 74 69 6f  iv id="subsectio
b3a0: 6e 35 22 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f  n5" class="docto
b3b0: 6f 6c 73 5f 73 75 62 73 65 63 74 69 6f 6e 22 3e  ols_subsection">
b3c0: 3c 68 33 3e 3c 61 20 6e 61 6d 65 3d 22 73 75 62  <h3><a name="sub
b3d0: 73 65 63 74 69 6f 6e 35 22 3e 56 61 6c 75 65 73  section5">Values
b3e0: 20 66 6f 72 20 50 61 73 73 77 6f 72 64 20 43 61   for Password Ca
b3f0: 6c 6c 62 61 63 6b 3c 2f 61 3e 3c 2f 68 33 3e 0a  llback</a></h3>.
b400: 3c 70 3e 54 68 65 20 63 61 6c 6c 62 61 63 6b 20  <p>The callback 
b410: 66 6f 72 20 74 68 65 20 3c 62 20 63 6c 61 73 73  for the <b class
b420: 3d 22 6f 70 74 69 6f 6e 22 3e 2d 70 61 73 73 77  ="option">-passw
b430: 6f 72 64 3c 2f 62 3e 20 6f 70 74 69 6f 6e 20 69  ord</b> option i
b440: 73 20 69 6e 76 6f 6b 65 64 20 62 79 20 54 63 6c  s invoked by Tcl
b450: 54 4c 53 20 77 68 65 6e 65 76 65 72 20 4f 70 65  TLS whenever Ope
b460: 6e 53 53 4c 20 6e 65 65 64 73 0a 74 6f 20 6f 62  nSSL needs.to ob
b470: 74 61 69 6e 20 61 20 70 61 73 73 77 6f 72 64 2e  tain a password.
b480: 20 53 65 65 20 62 65 6c 6f 77 20 66 6f 72 20 74   See below for t
b490: 68 65 20 70 6f 73 73 69 62 6c 65 20 61 72 67 75  he possible argu
b4a0: 6d 65 6e 74 73 20 70 61 73 73 65 64 20 74 6f 20  ments passed to 
b4b0: 74 68 65 0a 63 61 6c 6c 62 61 63 6b 20 73 63 72  the.callback scr
b4c0: 69 70 74 2e 20 54 68 65 20 75 73 65 72 20 70 72  ipt. The user pr
b4d0: 6f 76 69 64 65 64 20 70 61 73 73 77 6f 72 64 20  ovided password 
b4e0: 69 73 20 65 78 70 65 63 74 65 64 20 74 6f 20 62  is expected to b
b4f0: 65 20 72 65 74 75 72 6e 65 64 20 62 79 20 74 68  e returned by th
b500: 65 0a 63 61 6c 6c 62 61 63 6b 2e 3c 2f 70 3e 0a  e.callback.</p>.
b510: 3c 64 6c 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f  <dl class="docto
b520: 6f 6c 73 5f 6f 70 74 69 6f 6e 73 22 3e 0a 3c 64  ols_options">.<d
b530: 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  t><b class="opti
b540: 6f 6e 22 3e 70 61 73 73 77 6f 72 64 3c 2f 62 3e  on">password</b>
b550: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
b560: 72 77 66 6c 61 67 20 73 69 7a 65 3c 2f 69 3e 3c  rwflag size</i><
b570: 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 49 6e 76 6f  /dt>.<dd><p>Invo
b580: 6b 65 64 20 77 68 65 6e 20 6c 6f 61 64 69 6e 67  ked when loading
b590: 20 6f 72 20 73 74 6f 72 69 6e 67 20 61 6e 20 65   or storing an e
b5a0: 6e 63 72 79 70 74 65 64 20 50 45 4d 20 63 65 72  ncrypted PEM cer
b5b0: 74 69 66 69 63 61 74 65 2e 20 54 68 65 20 61 72  tificate. The ar
b5c0: 67 75 6d 65 6e 74 73 20 61 72 65 3a 3c 2f 70 3e  guments are:</p>
b5d0: 0a 3c 64 6c 20 63 6c 61 73 73 3d 22 64 6f 63 74  .<dl class="doct
b5e0: 6f 6f 6c 73 5f 64 65 66 69 6e 69 74 69 6f 6e 73  ools_definitions
b5f0: 22 3e 0a 3c 64 74 3e 3c 69 20 63 6c 61 73 73 3d  ">.<dt><i class=
b600: 22 61 72 67 22 3e 72 77 66 6c 61 67 3c 2f 69 3e  "arg">rwflag</i>
b610: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65  </dt>.<dd><p>The
b620: 20 72 65 61 64 2f 77 72 69 74 65 20 66 6c 61 67   read/write flag
b630: 20 69 73 20 30 20 66 6f 72 20 72 65 61 64 69 6e   is 0 for readin
b640: 67 2f 64 65 63 72 79 70 74 69 6f 6e 20 6f 72 20  g/decryption or 
b650: 31 20 66 6f 72 20 77 72 69 74 69 6e 67 2f 65 6e  1 for writing/en
b660: 63 72 79 70 74 69 6f 6e 2e 0a 54 68 65 20 6c 61  cryption..The la
b670: 74 74 65 72 20 63 61 6e 20 62 65 20 75 73 65 64  tter can be used
b680: 20 74 6f 20 64 65 74 65 72 6d 69 6e 65 20 77 68   to determine wh
b690: 65 6e 20 74 6f 20 70 72 6f 6d 70 74 20 74 68 65  en to prompt the
b6a0: 20 75 73 65 72 20 74 6f 20 63 6f 6e 66 69 72 6d   user to confirm
b6b0: 2e 0a 54 68 69 73 20 61 72 67 75 6d 65 6e 74 20  ..This argument 
b6c0: 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c  is new for TclTL
b6d0: 53 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a  S 1.8.</p></dd>.
b6e0: 3c 64 74 3e 3c 69 20 63 6c 61 73 73 3d 22 61 72  <dt><i class="ar
b6f0: 67 22 3e 73 69 7a 65 3c 2f 69 3e 3c 2f 64 74 3e  g">size</i></dt>
b700: 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 73 69 7a 65  .<dd><p>The size
b710: 20 69 73 20 74 68 65 20 6d 61 78 69 6d 75 6d 20   is the maximum 
b720: 6c 65 6e 67 74 68 20 6f 66 20 74 68 65 20 70 61  length of the pa
b730: 73 73 77 6f 72 64 20 69 6e 20 62 79 74 65 73 2e  ssword in bytes.
b740: 0a 54 68 69 73 20 61 72 67 75 6d 65 6e 74 20 69  .This argument i
b750: 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c 53  s new for TclTLS
b760: 20 31 2e 38 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c   1.8.</p></dd>.<
b770: 2f 64 6c 3e 3c 2f 64 64 3e 0a 3c 2f 64 6c 3e 0a  /dl></dd>.</dl>.
b780: 3c 2f 64 69 76 3e 0a 3c 64 69 76 20 69 64 3d 22  </div>.<div id="
b790: 73 75 62 73 65 63 74 69 6f 6e 36 22 20 63 6c 61  subsection6" cla
b7a0: 73 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73 75 62  ss="doctools_sub
b7b0: 73 65 63 74 69 6f 6e 22 3e 3c 68 33 3e 3c 61 20  section"><h3><a 
b7c0: 6e 61 6d 65 3d 22 73 75 62 73 65 63 74 69 6f 6e  name="subsection
b7d0: 36 22 3e 56 61 6c 75 65 73 20 66 6f 72 20 56 61  6">Values for Va
b7e0: 6c 69 64 61 74 65 20 43 6f 6d 6d 61 6e 64 20 43  lidate Command C
b7f0: 61 6c 6c 62 61 63 6b 3c 2f 61 3e 3c 2f 68 33 3e  allback</a></h3>
b800: 0a 3c 70 3e 54 68 65 20 63 61 6c 6c 62 61 63 6b  .<p>The callback
b810: 20 66 6f 72 20 74 68 65 20 3c 62 20 63 6c 61 73   for the <b clas
b820: 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 76 61 6c 69  s="option">-vali
b830: 64 61 74 65 63 6f 6d 6d 61 6e 64 3c 2f 62 3e 20  datecommand</b> 
b840: 6f 70 74 69 6f 6e 20 69 73 20 69 6e 76 6f 6b 65  option is invoke
b850: 64 20 64 75 72 69 6e 67 20 74 68 65 20 68 61 6e  d during the han
b860: 64 73 68 61 6b 65 0a 70 72 6f 63 65 73 73 20 69  dshake.process i
b870: 6e 20 6f 72 64 65 72 20 66 6f 72 20 74 68 65 20  n order for the 
b880: 61 70 70 6c 69 63 61 74 69 6f 6e 20 74 6f 20 76  application to v
b890: 61 6c 69 64 61 74 65 20 74 68 65 20 70 72 6f 76  alidate the prov
b8a0: 69 64 65 64 20 76 61 6c 75 65 28 73 29 2e 20 53  ided value(s). S
b8b0: 65 65 0a 62 65 6c 6f 77 20 66 6f 72 20 74 68 65  ee.below for the
b8c0: 20 70 6f 73 73 69 62 6c 65 20 61 72 67 75 6d 65   possible argume
b8d0: 6e 74 73 20 70 61 73 73 65 64 20 74 6f 20 74 68  nts passed to th
b8e0: 65 20 63 61 6c 6c 62 61 63 6b 20 73 63 72 69 70  e callback scrip
b8f0: 74 2e 20 49 66 20 6e 6f 74 0a 73 70 65 63 69 66  t. If not.specif
b900: 69 65 64 2c 20 4f 70 65 6e 53 53 4c 20 77 69 6c  ied, OpenSSL wil
b910: 6c 20 61 63 63 65 70 74 20 61 6c 6c 20 76 61 6c  l accept all val
b920: 69 64 20 63 65 72 74 69 66 69 63 61 74 65 73 20  id certificates 
b930: 61 6e 64 20 65 78 74 65 6e 73 69 6f 6e 73 2e 20  and extensions. 
b940: 54 6f 20 72 65 6a 65 63 74 0a 74 68 65 20 76 61  To reject.the va
b950: 6c 75 65 20 61 6e 64 20 61 62 6f 72 74 20 74 68  lue and abort th
b960: 65 20 63 6f 6e 6e 65 63 74 69 6f 6e 2c 20 74 68  e connection, th
b970: 65 20 63 61 6c 6c 62 61 63 6b 20 73 68 6f 75 6c  e callback shoul
b980: 64 20 72 65 74 75 72 6e 20 30 2e 20 54 6f 20 61  d return 0. To a
b990: 63 63 65 70 74 20 74 68 65 0a 76 61 6c 75 65 20  ccept the.value 
b9a0: 61 6e 64 20 63 6f 6e 74 69 6e 75 65 20 74 68 65  and continue the
b9b0: 20 63 6f 6e 6e 65 63 74 69 6f 6e 2c 20 69 74 20   connection, it 
b9c0: 73 68 6f 75 6c 64 20 72 65 74 75 72 6e 20 31 2e  should return 1.
b9d0: 20 54 6f 20 72 65 6a 65 63 74 20 74 68 65 20 76   To reject the v
b9e0: 61 6c 75 65 2c 20 62 75 74 0a 63 6f 6e 74 69 6e  alue, but.contin
b9f0: 75 65 20 74 68 65 20 63 6f 6e 6e 65 63 74 69 6f  ue the connectio
ba00: 6e 2c 20 69 74 20 73 68 6f 75 6c 64 20 72 65 74  n, it should ret
ba10: 75 72 6e 20 32 2e 20 54 68 69 73 20 63 61 6c 6c  urn 2. This call
ba20: 62 61 63 6b 20 69 73 20 6e 65 77 20 66 6f 72 20  back is new for 
ba30: 54 63 6c 54 4c 53 20 31 2e 38 2e 3c 2f 70 3e 0a  TclTLS 1.8.</p>.
ba40: 3c 64 6c 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f  <dl class="docto
ba50: 6f 6c 73 5f 6f 70 74 69 6f 6e 73 22 3e 0a 3c 64  ols_options">.<d
ba60: 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  t><b class="opti
ba70: 6f 6e 22 3e 61 6c 70 6e 3c 2f 62 3e 20 3c 69 20  on">alpn</b> <i 
ba80: 63 6c 61 73 73 3d 22 61 72 67 22 3e 63 68 61 6e  class="arg">chan
ba90: 6e 65 6c 49 64 20 70 72 6f 74 6f 63 6f 6c 20 6d  nelId protocol m
baa0: 61 74 63 68 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64  atch</i></dt>.<d
bab0: 64 3e 3c 70 3e 46 6f 72 20 73 65 72 76 65 72 73  d><p>For servers
bac0: 2c 20 74 68 69 73 20 66 6f 72 6d 20 6f 66 20 63  , this form of c
bad0: 61 6c 6c 62 61 63 6b 20 69 73 20 69 6e 76 6f 6b  allback is invok
bae0: 65 64 20 77 68 65 6e 20 74 68 65 20 63 6c 69 65  ed when the clie
baf0: 6e 74 20 41 4c 50 4e 20 65 78 74 65 6e 73 69 6f  nt ALPN extensio
bb00: 6e 20 69 73 0a 72 65 63 65 69 76 65 64 2e 20 49  n is.received. I
bb10: 66 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  f <i class="arg"
bb20: 3e 6d 61 74 63 68 3c 2f 69 3e 20 69 73 20 74 72  >match</i> is tr
bb30: 75 65 2c 20 74 68 65 6e 20 3c 69 20 63 6c 61 73  ue, then <i clas
bb40: 73 3d 22 61 72 67 22 3e 70 72 6f 74 6f 63 6f 6c  s="arg">protocol
bb50: 3c 2f 69 3e 20 69 73 20 74 68 65 20 66 69 72 73  </i> is the firs
bb60: 74 0a 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  t.<b class="opti
bb70: 6f 6e 22 3e 2d 61 6c 70 6e 3c 2f 62 3e 20 70 72  on">-alpn</b> pr
bb80: 6f 74 6f 63 6f 6c 20 6f 70 74 69 6f 6e 20 69 6e  otocol option in
bb90: 20 63 6f 6d 6d 6f 6e 20 74 6f 20 62 6f 74 68 20   common to both 
bba0: 74 68 65 20 63 6c 69 65 6e 74 20 61 6e 64 20 73  the client and s
bbb0: 65 72 76 65 72 2e 0a 49 66 20 6e 6f 74 2c 20 74  erver..If not, t
bbc0: 68 65 20 66 69 72 73 74 20 63 6c 69 65 6e 74 20  he first client 
bbd0: 73 70 65 63 69 66 69 65 64 20 70 72 6f 74 6f 63  specified protoc
bbe0: 6f 6c 20 69 73 20 75 73 65 64 2e 20 54 68 69 73  ol is used. This
bbf0: 20 63 61 6c 6c 62 61 63 6b 20 69 73 20 63 61 6c   callback is cal
bc00: 6c 65 64 0a 61 66 74 65 72 20 74 68 65 20 48 65  led.after the He
bc10: 6c 6c 6f 20 61 6e 64 20 41 4c 50 4e 20 63 61 6c  llo and ALPN cal
bc20: 6c 62 61 63 6b 73 2e 3c 2f 70 3e 3c 2f 64 64 3e  lbacks.</p></dd>
bc30: 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22 6f  .<dt><b class="o
bc40: 70 74 69 6f 6e 22 3e 68 65 6c 6c 6f 3c 2f 62 3e  ption">hello</b>
bc50: 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e   <i class="arg">
bc60: 63 68 61 6e 6e 65 6c 49 64 20 73 65 72 76 65 72  channelId server
bc70: 6e 61 6d 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64  name</i></dt>.<d
bc80: 64 3e 3c 70 3e 46 6f 72 20 73 65 72 76 65 72 73  d><p>For servers
bc90: 2c 20 74 68 69 73 20 66 6f 72 6d 20 6f 66 20 63  , this form of c
bca0: 61 6c 6c 62 61 63 6b 20 69 73 20 69 6e 76 6f 6b  allback is invok
bcb0: 65 64 20 64 75 72 69 6e 67 20 63 6c 69 65 6e 74  ed during client
bcc0: 20 68 65 6c 6c 6f 20 6d 65 73 73 61 67 65 0a 70   hello message.p
bcd0: 72 6f 63 65 73 73 69 6e 67 2e 20 54 68 65 20 70  rocessing. The p
bce0: 75 72 70 6f 73 65 20 69 73 20 73 6f 20 74 68 65  urpose is so the
bcf0: 20 73 65 72 76 65 72 20 63 61 6e 20 73 65 6c 65   server can sele
bd00: 63 74 20 74 68 65 20 61 70 70 72 6f 70 72 69 61  ct the appropria
bd10: 74 65 20 63 65 72 74 69 66 69 63 61 74 65 0a 74  te certificate.t
bd20: 6f 20 70 72 65 73 65 6e 74 20 74 6f 20 74 68 65  o present to the
bd30: 20 63 6c 69 65 6e 74 2c 20 61 6e 64 20 74 6f 20   client, and to 
bd40: 6d 61 6b 65 20 6f 74 68 65 72 20 63 6f 6e 66 69  make other confi
bd50: 67 75 72 61 74 69 6f 6e 20 61 64 6a 75 73 74 6d  guration adjustm
bd60: 65 6e 74 73 20 72 65 6c 65 76 61 6e 74 0a 74 6f  ents relevant.to
bd70: 20 74 68 61 74 20 73 65 72 76 65 72 20 6e 61 6d   that server nam
bd80: 65 20 61 6e 64 20 69 74 73 20 63 6f 6e 66 69 67  e and its config
bd90: 75 72 61 74 69 6f 6e 2e 20 49 74 20 69 73 20 63  uration. It is c
bda0: 61 6c 6c 65 64 20 62 65 66 6f 72 65 20 74 68 65  alled before the
bdb0: 20 53 4e 49 20 61 6e 64 20 41 4c 50 4e 0a 63 61   SNI and ALPN.ca
bdc0: 6c 6c 62 61 63 6b 73 2e 3c 2f 70 3e 3c 2f 64 64  llbacks.</p></dd
bdd0: 3e 0a 3c 64 74 3e 3c 62 20 63 6c 61 73 73 3d 22  >.<dt><b class="
bde0: 6f 70 74 69 6f 6e 22 3e 73 6e 69 3c 2f 62 3e 20  option">sni</b> 
bdf0: 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 63  <i class="arg">c
be00: 68 61 6e 6e 65 6c 49 64 20 73 65 72 76 65 72 6e  hannelId servern
be10: 61 6d 65 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64  ame</i></dt>.<dd
be20: 3e 3c 70 3e 46 6f 72 20 73 65 72 76 65 72 73 2c  ><p>For servers,
be30: 20 74 68 69 73 20 66 6f 72 6d 20 6f 66 20 63 61   this form of ca
be40: 6c 6c 62 61 63 6b 20 69 73 20 69 6e 76 6f 6b 65  llback is invoke
be50: 64 20 77 68 65 6e 20 74 68 65 20 53 65 72 76 65  d when the Serve
be60: 72 20 4e 61 6d 65 20 49 6e 64 69 63 61 74 69 6f  r Name Indicatio
be70: 6e 0a 28 53 4e 49 29 20 65 78 74 65 6e 73 69 6f  n.(SNI) extensio
be80: 6e 20 69 73 20 72 65 63 65 69 76 65 64 2e 20 54  n is received. T
be90: 68 65 20 3c 69 20 63 6c 61 73 73 3d 22 61 72 67  he <i class="arg
bea0: 22 3e 73 65 72 76 65 72 6e 61 6d 65 3c 2f 69 3e  ">servername</i>
beb0: 20 61 72 67 75 6d 65 6e 74 20 69 73 20 74 68 65   argument is the
bec0: 20 63 6c 69 65 6e 74 0a 70 72 6f 76 69 64 65 64   client.provided
bed0: 20 73 65 72 76 65 72 20 6e 61 6d 65 20 73 70 65   server name spe
bee0: 63 69 66 69 65 64 20 69 6e 20 74 68 65 20 3c 62  cified in the <b
bef0: 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e   class="option">
bf00: 2d 73 65 72 76 65 72 6e 61 6d 65 26 6c 74 3b 2f  -servername&lt;/
bf10: 62 26 67 74 3b 3c 2f 62 3e 20 6f 70 74 69 6f 6e  b&gt;</b> option
bf20: 2e 20 54 68 65 0a 70 75 72 70 6f 73 65 20 69 73  . The.purpose is
bf30: 20 73 6f 20 77 68 65 6e 20 61 20 73 65 72 76 65   so when a serve
bf40: 72 20 73 75 70 70 6f 72 74 73 20 6d 75 6c 74 69  r supports multi
bf50: 70 6c 65 20 6e 61 6d 65 73 2c 20 74 68 65 20 72  ple names, the r
bf60: 69 67 68 74 20 63 65 72 74 69 66 69 63 61 74 65  ight certificate
bf70: 0a 63 61 6e 20 62 65 20 75 73 65 64 2e 20 49 74  .can be used. It
bf80: 20 69 73 20 63 61 6c 6c 65 64 20 61 66 74 65 72   is called after
bf90: 20 74 68 65 20 68 65 6c 6c 6f 20 63 61 6c 6c 62   the hello callb
bfa0: 61 63 6b 20 62 75 74 20 62 65 66 6f 72 65 20 74  ack but before t
bfb0: 68 65 20 41 4c 50 4e 0a 63 61 6c 6c 62 61 63 6b  he ALPN.callback
bfc0: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
bfd0: 62 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22  b class="option"
bfe0: 3e 76 65 72 69 66 79 3c 2f 62 3e 20 3c 69 20 63  >verify</b> <i c
bff0: 6c 61 73 73 3d 22 61 72 67 22 3e 63 68 61 6e 6e  lass="arg">chann
c000: 65 6c 49 64 20 64 65 70 74 68 20 63 65 72 74 20  elId depth cert 
c010: 73 74 61 74 75 73 20 65 72 72 6f 72 3c 2f 69 3e  status error</i>
c020: 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68 69  </dt>.<dd><p>Thi
c030: 73 20 66 6f 72 6d 20 6f 66 20 63 61 6c 6c 62 61  s form of callba
c040: 63 6b 20 69 73 20 69 6e 76 6f 6b 65 64 20 62 79  ck is invoked by
c050: 20 4f 70 65 6e 53 53 4c 20 77 68 65 6e 20 61 20   OpenSSL when a 
c060: 6e 65 77 20 63 65 72 74 69 66 69 63 61 74 65 20  new certificate 
c070: 69 73 20 72 65 63 65 69 76 65 64 0a 66 72 6f 6d  is received.from
c080: 20 74 68 65 20 70 65 65 72 2e 20 49 74 20 61 6c   the peer. It al
c090: 6c 6f 77 73 20 74 68 65 20 63 6c 69 65 6e 74 20  lows the client 
c0a0: 74 6f 20 63 68 65 63 6b 20 74 68 65 20 63 65 72  to check the cer
c0b0: 74 69 66 69 63 61 74 65 20 76 65 72 69 66 69 63  tificate verific
c0c0: 61 74 69 6f 6e 0a 72 65 73 75 6c 74 73 20 61 6e  ation.results an
c0d0: 64 20 63 68 6f 6f 73 65 20 77 68 65 74 68 65 72  d choose whether
c0e0: 20 74 6f 20 63 6f 6e 74 69 6e 75 65 20 6f 72 20   to continue or 
c0f0: 6e 6f 74 2e 20 49 74 20 69 73 20 63 61 6c 6c 65  not. It is calle
c100: 64 20 66 6f 72 20 65 61 63 68 0a 63 65 72 74 69  d for each.certi
c110: 66 69 63 61 74 65 20 69 6e 20 74 68 65 20 63 65  ficate in the ce
c120: 72 74 69 66 69 63 61 74 65 20 63 68 61 69 6e 2e  rtificate chain.
c130: 20 54 68 69 73 20 63 61 6c 6c 62 61 63 6b 20 77   This callback w
c140: 61 73 20 6d 6f 76 65 64 20 66 72 6f 6d 0a 3c 62  as moved from.<b
c150: 20 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e   class="option">
c160: 2d 63 6f 6d 6d 61 6e 64 3c 2f 62 3e 20 69 6e 20  -command</b> in 
c170: 54 63 6c 54 4c 53 20 31 2e 38 2e 20 54 68 65 20  TclTLS 1.8. The 
c180: 61 72 67 75 6d 65 6e 74 73 20 61 72 65 3a 3c 2f  arguments are:</
c190: 70 3e 0a 3c 64 6c 20 63 6c 61 73 73 3d 22 64 6f  p>.<dl class="do
c1a0: 63 74 6f 6f 6c 73 5f 64 65 66 69 6e 69 74 69 6f  ctools_definitio
c1b0: 6e 73 22 3e 0a 3c 64 74 3e 3c 69 20 63 6c 61 73  ns">.<dt><i clas
c1c0: 73 3d 22 61 72 67 22 3e 64 65 70 74 68 3c 2f 69  s="arg">depth</i
c1d0: 3e 3c 2f 64 74 3e 0a 3c 64 64 3e 3c 70 3e 54 68  ></dt>.<dd><p>Th
c1e0: 65 20 64 65 70 74 68 20 69 73 20 74 68 65 20 69  e depth is the i
c1f0: 6e 74 65 67 65 72 20 64 65 70 74 68 20 6f 66 20  nteger depth of 
c200: 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65 20  the certificate 
c210: 69 6e 20 74 68 65 20 63 65 72 74 69 66 69 63 61  in the certifica
c220: 74 65 20 63 68 61 69 6e 2c 0a 77 68 65 72 65 20  te chain,.where 
c230: 30 20 69 73 20 74 68 65 20 70 65 65 72 20 63 65  0 is the peer ce
c240: 72 74 69 66 69 63 61 74 65 20 61 6e 64 20 68 69  rtificate and hi
c250: 67 68 65 72 20 76 61 6c 75 65 73 20 67 6f 69 6e  gher values goin
c260: 67 20 75 70 20 74 6f 20 74 68 65 20 43 65 72 74  g up to the Cert
c270: 69 66 69 63 61 74 65 0a 41 75 74 68 6f 72 69 74  ificate.Authorit
c280: 79 20 28 43 41 29 2e 3c 2f 70 3e 3c 2f 64 64 3e  y (CA).</p></dd>
c290: 0a 3c 64 74 3e 3c 69 20 63 6c 61 73 73 3d 22 61  .<dt><i class="a
c2a0: 72 67 22 3e 63 65 72 74 3c 2f 69 3e 3c 2f 64 74  rg">cert</i></dt
c2b0: 3e 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 63 65 72  >.<dd><p>The cer
c2c0: 74 20 61 72 67 75 6d 65 6e 74 20 69 73 20 61 20  t argument is a 
c2d0: 6c 69 73 74 20 6f 66 20 6b 65 79 2d 76 61 6c 75  list of key-valu
c2e0: 65 20 70 61 69 72 73 20 73 69 6d 69 6c 61 72 20  e pairs similar 
c2f0: 74 6f 20 74 68 6f 73 65 20 72 65 74 75 72 6e 65  to those returne
c300: 64 20 62 79 0a 3c 62 20 63 6c 61 73 73 3d 22 63  d by.<b class="c
c310: 6d 64 22 3e 74 6c 73 3a 3a 73 74 61 74 75 73 3c  md">tls::status<
c320: 2f 62 3e 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64  /b>.</p></dd>.<d
c330: 74 3e 3c 69 20 63 6c 61 73 73 3d 22 61 72 67 22  t><i class="arg"
c340: 3e 73 74 61 74 75 73 3c 2f 69 3e 3c 2f 64 74 3e  >status</i></dt>
c350: 0a 3c 64 64 3e 3c 70 3e 54 68 65 20 73 74 61 74  .<dd><p>The stat
c360: 75 73 20 61 72 67 75 6d 65 6e 74 20 69 73 20 74  us argument is t
c370: 68 65 20 62 6f 6f 6c 65 61 6e 20 76 61 6c 69 64  he boolean valid
c380: 69 74 79 20 6f 66 20 74 68 65 20 63 75 72 72 65  ity of the curre
c390: 6e 74 20 63 65 72 74 69 66 69 63 61 74 65 20 77  nt certificate w
c3a0: 68 65 72 65 20 30 0a 69 73 20 69 6e 76 61 6c 69  here 0.is invali
c3b0: 64 20 61 6e 64 20 31 20 69 73 20 76 61 6c 69 64  d and 1 is valid
c3c0: 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c 64 74 3e 3c  .</p></dd>.<dt><
c3d0: 69 20 63 6c 61 73 73 3d 22 61 72 67 22 3e 65 72  i class="arg">er
c3e0: 72 6f 72 3c 2f 69 3e 3c 2f 64 74 3e 0a 3c 64 64  ror</i></dt>.<dd
c3f0: 3e 3c 70 3e 54 68 65 20 65 72 72 6f 72 20 61 72  ><p>The error ar
c400: 67 75 6d 65 6e 74 20 69 73 20 74 68 65 20 65 72  gument is the er
c410: 72 6f 72 20 6d 65 73 73 61 67 65 2c 20 69 66 20  ror message, if 
c420: 61 6e 79 2c 20 67 65 6e 65 72 61 74 65 64 20 62  any, generated b
c430: 79 0a 3c 62 20 63 6c 61 73 73 3d 22 66 75 6e 63  y.<b class="func
c440: 74 69 6f 6e 22 3e 58 35 30 39 5f 53 54 4f 52 45  tion">X509_STORE
c450: 5f 43 54 58 5f 67 65 74 5f 65 72 72 6f 72 28 29  _CTX_get_error()
c460: 3c 2f 62 3e 2e 3c 2f 70 3e 3c 2f 64 64 3e 0a 3c  </b>.</p></dd>.<
c470: 2f 64 6c 3e 3c 2f 64 64 3e 0a 3c 2f 64 6c 3e 0a  /dl></dd>.</dl>.
c480: 3c 70 3e 52 65 66 65 72 65 6e 63 65 20 69 6d 70  <p>Reference imp
c490: 6c 65 6d 65 6e 74 61 74 69 6f 6e 73 20 6f 66 20  lementations of 
c4a0: 74 68 65 73 65 20 63 61 6c 6c 62 61 63 6b 73 20  these callbacks 
c4b0: 61 72 65 20 70 72 6f 76 69 64 65 64 20 69 6e 20  are provided in 
c4c0: 26 71 75 6f 74 3b 3c 62 20 63 6c 61 73 73 3d 22  &quot;<b class="
c4d0: 66 69 6c 65 22 3e 74 6c 73 2e 74 63 6c 3c 2f 62  file">tls.tcl</b
c4e0: 3e 26 71 75 6f 74 3b 0a 61 73 20 3c 62 20 63 6c  >&quot;.as <b cl
c4f0: 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 63  ass="cmd">tls::c
c500: 61 6c 6c 62 61 63 6b 3c 2f 62 3e 2c 20 3c 62 20  allback</b>, <b 
c510: 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a  class="cmd">tls:
c520: 3a 70 61 73 73 77 6f 72 64 3c 2f 62 3e 2c 20 61  :password</b>, a
c530: 6e 64 20 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64  nd <b class="cmd
c540: 22 3e 74 6c 73 3a 3a 76 61 6c 69 64 61 74 65 5f  ">tls::validate_
c550: 63 6f 6d 6d 61 6e 64 3c 2f 62 3e 0a 72 65 73 70  command</b>.resp
c560: 65 63 74 69 76 65 6c 79 2e 20 4e 6f 74 65 20 74  ectively. Note t
c570: 68 61 74 20 74 68 65 73 65 20 61 72 65 20 6f 6e  hat these are on
c580: 6c 79 20 3c 65 6d 3e 73 61 6d 70 6c 65 3c 2f 65  ly <em>sample</e
c590: 6d 3e 20 69 6d 70 6c 65 6d 65 6e 74 61 74 69 6f  m> implementatio
c5a0: 6e 73 2e 20 49 6e 20 61 20 6d 6f 72 65 0a 72 65  ns. In a more.re
c5b0: 61 6c 69 73 74 69 63 20 64 65 70 6c 6f 79 6d 65  alistic deployme
c5c0: 6e 74 20 79 6f 75 20 77 6f 75 6c 64 20 73 70 65  nt you would spe
c5d0: 63 69 66 79 20 79 6f 75 72 20 6f 77 6e 20 63 61  cify your own ca
c5e0: 6c 6c 62 61 63 6b 20 73 63 72 69 70 74 73 20 6f  llback scripts o
c5f0: 6e 20 65 61 63 68 20 54 4c 53 0a 63 68 61 6e 6e  n each TLS.chann
c600: 65 6c 20 75 73 69 6e 67 20 74 68 65 20 3c 62 20  el using the <b 
c610: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
c620: 63 6f 6d 6d 61 6e 64 3c 2f 62 3e 2c 20 3c 62 20  command</b>, <b 
c630: 63 6c 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d  class="option">-
c640: 70 61 73 73 77 6f 72 64 3c 2f 62 3e 2c 20 61 6e  password</b>, an
c650: 64 0a 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  d.<b class="opti
c660: 6f 6e 22 3e 2d 76 61 6c 69 64 61 74 65 5f 63 6f  on">-validate_co
c670: 6d 6d 61 6e 64 3c 2f 62 3e 20 6f 70 74 69 6f 6e  mmand</b> option
c680: 73 2e 3c 2f 70 3e 0a 3c 70 3e 54 68 65 20 64 65  s.</p>.<p>The de
c690: 66 61 75 6c 74 20 62 65 68 61 76 69 6f 72 20 77  fault behavior w
c6a0: 68 65 6e 20 74 68 65 20 3c 62 20 63 6c 61 73 73  hen the <b class
c6b0: 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 6f 6d 6d 61  ="option">-comma
c6c0: 6e 64 3c 2f 62 3e 20 61 6e 64 20 3c 62 20 63 6c  nd</b> and <b cl
c6d0: 61 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 76 61  ass="option">-va
c6e0: 6c 69 64 61 74 65 5f 63 6f 6d 6d 61 6e 64 3c 2f  lidate_command</
c6f0: 62 3e 0a 6f 70 74 69 6f 6e 73 20 61 72 65 20 6e  b>.options are n
c700: 6f 74 20 73 70 65 63 69 66 69 65 64 2c 20 69 73  ot specified, is
c710: 20 66 6f 72 20 54 63 6c 54 4c 53 20 74 6f 20 70   for TclTLS to p
c720: 72 6f 63 65 73 73 20 74 68 65 20 61 73 73 6f 63  rocess the assoc
c730: 69 61 74 65 64 20 6c 69 62 72 61 72 79 0a 63 61  iated library.ca
c740: 6c 6c 62 61 63 6b 73 20 69 6e 74 65 72 6e 61 6c  llbacks internal
c750: 6c 79 2e 20 54 68 65 20 64 65 66 61 75 6c 74 20  ly. The default 
c760: 62 65 68 61 76 69 6f 72 20 77 68 65 6e 20 74 68  behavior when th
c770: 65 20 3c 62 20 63 6c 61 73 73 3d 22 6f 70 74 69  e <b class="opti
c780: 6f 6e 22 3e 2d 70 61 73 73 77 6f 72 64 3c 2f 62  on">-password</b
c790: 3e 20 6f 70 74 69 6f 6e 0a 69 73 20 6e 6f 74 20  > option.is not 
c7a0: 73 70 65 63 69 66 69 65 64 20 69 73 20 66 6f 72  specified is for
c7b0: 20 54 63 6c 54 4c 53 20 74 6f 20 70 72 6f 63 65   TclTLS to proce
c7c0: 73 73 20 74 68 65 20 61 73 73 6f 63 69 61 74 65  ss the associate
c7d0: 64 20 6c 69 62 72 61 72 79 20 63 61 6c 6c 62 61  d library callba
c7e0: 63 6b 73 20 62 79 0a 61 74 74 65 6d 70 74 69 6e  cks by.attemptin
c7f0: 67 20 74 6f 20 63 61 6c 6c 20 3c 62 20 63 6c 61  g to call <b cla
c800: 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 70 61  ss="cmd">tls::pa
c810: 73 73 77 6f 72 64 3c 2f 62 3e 2e 20 54 68 65 20  ssword</b>. The 
c820: 64 69 66 66 65 72 65 6e 63 65 20 62 65 74 77 65  difference betwe
c830: 65 6e 20 74 68 65 73 65 20 74 77 6f 0a 62 65 68  en these two.beh
c840: 61 76 69 6f 72 73 20 69 73 20 61 20 63 6f 6e 73  aviors is a cons
c850: 65 71 75 65 6e 63 65 20 6f 66 20 6d 61 69 6e 74  equence of maint
c860: 61 69 6e 69 6e 67 20 63 6f 6d 70 61 74 69 62 69  aining compatibi
c870: 6c 69 74 79 20 77 69 74 68 20 65 61 72 6c 69 65  lity with earlie
c880: 72 0a 69 6d 70 6c 65 6d 65 6e 74 61 74 69 6f 6e  r.implementation
c890: 73 2e 3c 2f 70 3e 0a 3c 70 3e 3c 65 6d 3e 54 68  s.</p>.<p><em>Th
c8a0: 65 20 75 73 65 20 6f 66 20 74 68 65 20 72 65 66  e use of the ref
c8b0: 65 72 65 6e 63 65 20 63 61 6c 6c 62 61 63 6b 73  erence callbacks
c8c0: 20 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e   <b class="cmd">
c8d0: 74 6c 73 3a 3a 63 61 6c 6c 62 61 63 6b 3c 2f 62  tls::callback</b
c8e0: 3e 2c 20 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64  >, <b class="cmd
c8f0: 22 3e 74 6c 73 3a 3a 70 61 73 73 77 6f 72 64 3c  ">tls::password<
c900: 2f 62 3e 2c 0a 61 6e 64 20 3c 62 20 63 6c 61 73  /b>,.and <b clas
c910: 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 76 61 6c  s="cmd">tls::val
c920: 69 64 61 74 65 5f 63 6f 6d 6d 61 6e 64 3c 2f 62  idate_command</b
c930: 3e 20 69 73 20 6e 6f 74 20 72 65 63 6f 6d 6d 65  > is not recomme
c940: 6e 64 65 64 2e 20 54 68 65 79 20 6d 61 79 20 62  nded. They may b
c950: 65 20 72 65 6d 6f 76 65 64 20 66 72 6f 6d 20 66  e removed from f
c960: 75 74 75 72 65 20 72 65 6c 65 61 73 65 73 2e 3c  uture releases.<
c970: 2f 65 6d 3e 3c 2f 70 3e 0a 3c 2f 64 69 76 3e 0a  /em></p>.</div>.
c980: 3c 2f 64 69 76 3e 0a 3c 64 69 76 20 69 64 3d 22  </div>.<div id="
c990: 73 65 63 74 69 6f 6e 36 22 20 63 6c 61 73 73 3d  section6" class=
c9a0: 22 64 6f 63 74 6f 6f 6c 73 5f 73 65 63 74 69 6f  "doctools_sectio
c9b0: 6e 22 3e 3c 68 32 3e 3c 61 20 6e 61 6d 65 3d 22  n"><h2><a name="
c9c0: 73 65 63 74 69 6f 6e 36 22 3e 44 65 62 75 67 3c  section6">Debug<
c9d0: 2f 61 3e 3c 2f 68 32 3e 0a 3c 70 3e 46 6f 72 20  /a></h2>.<p>For 
c9e0: 6d 6f 73 74 20 64 65 62 75 67 67 69 6e 67 20 6e  most debugging n
c9f0: 65 65 64 73 2c 20 74 68 65 20 3c 62 20 63 6c 61  eeds, the <b cla
ca00: 73 73 3d 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 6c  ss="option">-cal
ca10: 6c 62 61 63 6b 3c 2f 62 3e 20 6f 70 74 69 6f 6e  lback</b> option
ca20: 20 63 61 6e 20 62 65 20 75 73 65 64 20 74 6f 20   can be used to 
ca30: 70 72 6f 76 69 64 65 0a 73 75 66 66 69 63 69 65  provide.sufficie
ca40: 6e 74 20 69 6e 73 69 67 68 74 20 61 6e 64 20 69  nt insight and i
ca50: 6e 66 6f 72 6d 61 74 69 6f 6e 20 6f 6e 20 74 68  nformation on th
ca60: 65 20 54 4c 53 20 68 61 6e 64 73 68 61 6b 65 20  e TLS handshake 
ca70: 61 6e 64 20 70 72 6f 67 72 65 73 73 2e 20 49 66  and progress. If
ca80: 0a 66 75 72 74 68 65 72 20 74 72 6f 75 62 6c 65  .further trouble
ca90: 73 68 6f 6f 74 69 6e 67 20 69 6e 73 69 67 68 74  shooting insight
caa0: 20 69 73 20 6e 65 65 64 65 64 2c 20 74 68 65 20   is needed, the 
cab0: 63 6f 6d 70 69 6c 65 20 74 69 6d 65 20 6f 70 74  compile time opt
cac0: 69 6f 6e 0a 3c 62 20 63 6c 61 73 73 3d 22 6f 70  ion.<b class="op
cad0: 74 69 6f 6e 22 3e 2d 2d 65 6e 61 62 6c 65 2d 64  tion">--enable-d
cae0: 65 62 75 67 3c 2f 62 3e 20 63 61 6e 20 62 65 20  ebug</b> can be 
caf0: 75 73 65 64 20 74 6f 20 67 65 74 20 64 65 74 61  used to get deta
cb00: 69 6c 65 64 20 65 78 65 63 75 74 69 6f 6e 20 66  iled execution f
cb10: 6c 6f 77 20 73 74 61 74 75 73 2e 3c 2f 70 3e 0a  low status.</p>.
cb20: 3c 70 3e 54 4c 53 20 6b 65 79 20 6c 6f 67 67 69  <p>TLS key loggi
cb30: 6e 67 20 63 61 6e 20 62 65 20 65 6e 61 62 6c 65  ng can be enable
cb40: 64 20 62 79 20 73 65 74 74 69 6e 67 20 74 68 65  d by setting the
cb50: 20 65 6e 76 69 72 6f 6e 6d 65 6e 74 20 76 61 72   environment var
cb60: 69 61 62 6c 65 0a 3c 62 20 63 6c 61 73 73 3d 22  iable.<b class="
cb70: 76 61 72 69 61 62 6c 65 22 3e 53 53 4c 4b 45 59  variable">SSLKEY
cb80: 4c 4f 47 46 49 4c 45 3c 2f 62 3e 20 74 6f 20 74  LOGFILE</b> to t
cb90: 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 66  he name of the f
cba0: 69 6c 65 20 74 6f 20 6c 6f 67 20 74 6f 2e 20 54  ile to log to. T
cbb0: 68 65 6e 20 77 68 65 6e 65 76 65 72 20 54 4c 53  hen whenever TLS
cbc0: 20 6b 65 79 0a 6d 61 74 65 72 69 61 6c 20 69 73   key.material is
cbd0: 20 67 65 6e 65 72 61 74 65 64 20 6f 72 20 72 65   generated or re
cbe0: 63 65 69 76 65 64 20 69 74 20 77 69 6c 6c 20 62  ceived it will b
cbf0: 65 20 6c 6f 67 67 65 64 20 74 6f 20 74 68 65 20  e logged to the 
cc00: 66 69 6c 65 2e 20 54 68 69 73 20 69 73 20 75 73  file. This is us
cc10: 65 66 75 6c 0a 66 6f 72 20 6c 6f 67 67 69 6e 67  eful.for logging
cc20: 20 6b 65 79 20 64 61 74 61 20 66 6f 72 20 6e 65   key data for ne
cc30: 74 77 6f 72 6b 20 6c 6f 67 67 69 6e 67 20 74 6f  twork logging to
cc40: 6f 6c 73 20 74 6f 20 75 73 65 20 74 6f 20 64 65  ols to use to de
cc50: 63 72 79 70 74 20 74 68 65 20 64 61 74 61 2e 3c  crypt the data.<
cc60: 2f 70 3e 0a 3c 70 3e 54 68 65 20 3c 62 20 63 6c  /p>.<p>The <b cl
cc70: 61 73 73 3d 22 76 61 72 69 61 62 6c 65 22 3e 74  ass="variable">t
cc80: 6c 73 3a 3a 64 65 62 75 67 3c 2f 62 3e 20 76 61  ls::debug</b> va
cc90: 72 69 61 62 6c 65 20 70 72 6f 76 69 64 65 73 20  riable provides 
cca0: 73 6f 6d 65 20 61 64 64 69 74 69 6f 6e 61 6c 20  some additional 
ccb0: 63 6f 6e 74 72 6f 6c 20 6f 76 65 72 20 74 68 65  control over the
ccc0: 0a 64 65 62 75 67 20 6c 6f 67 67 69 6e 67 20 69  .debug logging i
ccd0: 6e 20 74 68 65 20 3c 62 20 63 6c 61 73 73 3d 22  n the <b class="
cce0: 63 6d 64 22 3e 74 6c 73 3a 3a 63 61 6c 6c 62 61  cmd">tls::callba
ccf0: 63 6b 3c 2f 62 3e 2c 20 3c 62 20 63 6c 61 73 73  ck</b>, <b class
cd00: 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 70 61 73 73  ="cmd">tls::pass
cd10: 77 6f 72 64 3c 2f 62 3e 2c 20 61 6e 64 0a 3c 62  word</b>, and.<b
cd20: 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73   class="cmd">tls
cd30: 3a 3a 76 61 6c 69 64 61 74 65 5f 63 6f 6d 6d 61  ::validate_comma
cd40: 6e 64 3c 2f 62 3e 20 64 65 66 61 75 6c 74 20 68  nd</b> default h
cd50: 61 6e 64 6c 65 72 73 20 69 6e 20 26 71 75 6f 74  andlers in &quot
cd60: 3b 3c 62 20 63 6c 61 73 73 3d 22 66 69 6c 65 22  ;<b class="file"
cd70: 3e 74 6c 73 2e 74 63 6c 3c 2f 62 3e 26 71 75 6f  >tls.tcl</b>&quo
cd80: 74 3b 2e 0a 54 68 65 20 64 65 66 61 75 6c 74 20  t;..The default 
cd90: 76 61 6c 75 65 20 69 73 20 30 20 77 69 74 68 20  value is 0 with 
cda0: 68 69 67 68 65 72 20 76 61 6c 75 65 73 20 70 72  higher values pr
cdb0: 6f 64 75 63 69 6e 67 20 6d 6f 72 65 20 64 69 61  oducing more dia
cdc0: 67 6e 6f 73 74 69 63 20 6f 75 74 70 75 74 2c 0a  gnostic output,.
cdd0: 61 6e 64 20 77 69 6c 6c 20 61 6c 73 6f 20 66 6f  and will also fo
cde0: 72 63 65 20 74 68 65 20 76 65 72 69 66 79 20 6d  rce the verify m
cdf0: 65 74 68 6f 64 20 69 6e 20 3c 62 20 63 6c 61 73  ethod in <b clas
ce00: 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a 63 61 6c  s="cmd">tls::cal
ce10: 6c 62 61 63 6b 3c 2f 62 3e 20 74 6f 20 61 63 63  lback</b> to acc
ce20: 65 70 74 20 74 68 65 0a 63 65 72 74 69 66 69 63  ept the.certific
ce30: 61 74 65 2c 20 65 76 65 6e 20 69 66 20 69 74 20  ate, even if it 
ce40: 69 73 20 69 6e 76 61 6c 69 64 20 77 68 65 6e 20  is invalid when 
ce50: 74 68 65 20 3c 62 20 63 6c 61 73 73 3d 22 6f 70  the <b class="op
ce60: 74 69 6f 6e 22 3e 2d 76 61 6c 69 64 61 74 65 63  tion">-validatec
ce70: 6f 6d 6d 61 6e 64 3c 2f 62 3e 0a 6f 70 74 69 6f  ommand</b>.optio
ce80: 6e 20 69 73 20 73 65 74 20 74 6f 20 3c 62 20 63  n is set to <b c
ce90: 6c 61 73 73 3d 22 63 6d 64 22 3e 74 6c 73 3a 3a  lass="cmd">tls::
cea0: 76 61 6c 69 64 61 74 65 5f 63 6f 6d 6d 61 6e 64  validate_command
ceb0: 3c 2f 62 3e 2e 3c 2f 70 3e 0a 3c 70 3e 3c 65 6d  </b>.</p>.<p><em
cec0: 3e 54 68 65 20 75 73 65 20 6f 66 20 74 68 65 20  >The use of the 
ced0: 76 61 72 69 61 62 6c 65 20 3c 62 20 63 6c 61 73  variable <b clas
cee0: 73 3d 22 76 61 72 69 61 62 6c 65 22 3e 74 6c 73  s="variable">tls
cef0: 3a 3a 64 65 62 75 67 3c 2f 62 3e 20 69 73 20 6e  ::debug</b> is n
cf00: 6f 74 20 72 65 63 6f 6d 6d 65 6e 64 65 64 2e 0a  ot recommended..
cf10: 49 74 20 6d 61 79 20 62 65 20 72 65 6d 6f 76 65  It may be remove
cf20: 64 20 66 72 6f 6d 20 66 75 74 75 72 65 20 72 65  d from future re
cf30: 6c 65 61 73 65 73 2e 3c 2f 65 6d 3e 3c 2f 70 3e  leases.</em></p>
cf40: 0a 3c 2f 64 69 76 3e 0a 3c 64 69 76 20 69 64 3d  .</div>.<div id=
cf50: 22 73 65 63 74 69 6f 6e 37 22 20 63 6c 61 73 73  "section7" class
cf60: 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73 65 63 74 69  ="doctools_secti
cf70: 6f 6e 22 3e 3c 68 32 3e 3c 61 20 6e 61 6d 65 3d  on"><h2><a name=
cf80: 22 73 65 63 74 69 6f 6e 37 22 3e 45 78 61 6d 70  "section7">Examp
cf90: 6c 65 73 3c 2f 61 3e 3c 2f 68 32 3e 0a 3c 70 3e  les</a></h2>.<p>
cfa0: 54 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 61 72  The following ar
cfb0: 65 20 65 78 61 6d 70 6c 65 20 73 63 72 69 70 74  e example script
cfc0: 73 20 74 6f 20 64 6f 77 6e 6c 6f 61 64 20 61 20  s to download a 
cfd0: 77 65 62 70 61 67 65 20 61 6e 64 20 66 69 6c 65  webpage and file
cfe0: 20 75 73 69 6e 67 20 74 68 65 0a 68 74 74 70 20   using the.http 
cff0: 70 61 63 6b 61 67 65 2e 20 53 65 65 20 3c 73 70  package. See <sp
d000: 61 6e 20 63 6c 61 73 73 3d 22 73 65 63 74 72 65  an class="sectre
d010: 66 22 3e 3c 61 20 68 72 65 66 3d 22 23 73 65 63  f"><a href="#sec
d020: 74 69 6f 6e 34 22 3e 43 65 72 74 69 66 69 63 61  tion4">Certifica
d030: 74 65 20 56 61 6c 69 64 61 74 69 6f 6e 3c 2f 61  te Validation</a
d040: 3e 3c 2f 73 70 61 6e 3e 20 66 6f 72 20 77 68 65  ></span> for whe
d050: 6e 20 74 68 65 0a 3c 62 20 63 6c 61 73 73 3d 22  n the.<b class="
d060: 6f 70 74 69 6f 6e 22 3e 2d 63 61 64 69 72 3c 2f  option">-cadir</
d070: 62 3e 2c 20 3c 62 20 63 6c 61 73 73 3d 22 6f 70  b>, <b class="op
d080: 74 69 6f 6e 22 3e 2d 63 61 66 69 6c 65 3c 2f 62  tion">-cafile</b
d090: 3e 2c 20 61 6e 64 20 3c 62 20 63 6c 61 73 73 3d  >, and <b class=
d0a0: 22 6f 70 74 69 6f 6e 22 3e 2d 63 61 73 74 6f 72  "option">-castor
d0b0: 65 3c 2f 62 3e 20 6f 70 74 69 6f 6e 73 20 61 72  e</b> options ar
d0c0: 65 20 61 6c 73 6f 0a 6e 65 65 64 65 64 2e 20 53  e also.needed. S
d0d0: 65 65 20 74 68 65 20 26 71 75 6f 74 3b 3c 62 20  ee the &quot;<b 
d0e0: 63 6c 61 73 73 3d 22 66 69 6c 65 22 3e 64 65 6d  class="file">dem
d0f0: 6f 73 3c 2f 62 3e 26 71 75 6f 74 3b 20 64 69 72  os</b>&quot; dir
d100: 65 63 74 6f 72 79 20 66 6f 72 20 6d 6f 72 65 20  ectory for more 
d110: 65 78 61 6d 70 6c 65 20 73 63 72 69 70 74 73 2e  example scripts.
d120: 3c 2f 70 3e 0a 3c 70 3e 45 78 61 6d 70 6c 65 20  </p>.<p>Example 
d130: 23 31 3a 20 44 6f 77 6e 6c 6f 61 64 20 61 20 77  #1: Download a w
d140: 65 62 20 70 61 67 65 3c 2f 70 3e 0a 3c 70 72 65  eb page</p>.<pre
d150: 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f 6f 6c 73   class="doctools
d160: 5f 65 78 61 6d 70 6c 65 22 3e 0a 70 61 63 6b 61  _example">.packa
d170: 67 65 20 72 65 71 75 69 72 65 20 68 74 74 70 0a  ge require http.
d180: 70 61 63 6b 61 67 65 20 72 65 71 75 69 72 65 20  package require 
d190: 74 6c 73 0a 73 65 74 20 75 72 6c 20 26 71 75 6f  tls.set url &quo
d1a0: 74 3b 68 74 74 70 73 3a 2f 2f 77 77 77 2e 74 63  t;https://www.tc
d1b0: 6c 2e 74 6b 2f 26 71 75 6f 74 3b 0a 68 74 74 70  l.tk/&quot;.http
d1c0: 3a 3a 72 65 67 69 73 74 65 72 20 68 74 74 70 73  ::register https
d1d0: 20 34 34 33 20 5b 6c 69 73 74 20 3a 3a 74 6c 73   443 [list ::tls
d1e0: 3a 3a 73 6f 63 6b 65 74 20 2d 61 75 74 6f 73 65  ::socket -autose
d1f0: 72 76 65 72 6e 61 6d 65 20 31 20 2d 72 65 71 75  rvername 1 -requ
d200: 69 72 65 20 31 5d 0a 23 20 47 65 74 20 55 52 4c  ire 1].# Get URL
d210: 0a 73 65 74 20 74 6f 6b 65 6e 20 5b 68 74 74 70  .set token [http
d220: 3a 3a 67 65 74 75 72 6c 20 24 75 72 6c 5d 0a 23  ::geturl $url].#
d230: 20 43 68 65 63 6b 20 66 6f 72 20 65 72 72 6f 72   Check for error
d240: 0a 69 66 20 7b 5b 68 74 74 70 3a 3a 73 74 61 74  .if {[http::stat
d250: 75 73 20 24 74 6f 6b 65 6e 5d 20 6e 65 20 26 71  us $token] ne &q
d260: 75 6f 74 3b 6f 6b 26 71 75 6f 74 3b 7d 20 7b 0a  uot;ok&quot;} {.
d270: 20 20 20 20 70 75 74 73 20 5b 66 6f 72 6d 61 74      puts [format
d280: 20 26 71 75 6f 74 3b 45 72 72 6f 72 20 25 73 26   &quot;Error %s&
d290: 71 75 6f 74 3b 20 5b 68 74 74 70 3a 3a 73 74 61  quot; [http::sta
d2a0: 74 75 73 20 24 74 6f 6b 65 6e 5d 5d 0a 7d 0a 23  tus $token]].}.#
d2b0: 20 53 61 76 65 20 77 65 62 20 70 61 67 65 20 74   Save web page t
d2c0: 6f 20 66 69 6c 65 0a 73 65 74 20 63 68 20 5b 6f  o file.set ch [o
d2d0: 70 65 6e 20 65 78 61 6d 70 6c 65 2e 68 74 6d 6c  pen example.html
d2e0: 20 77 62 5d 0a 70 75 74 73 20 24 63 68 20 5b 68   wb].puts $ch [h
d2f0: 74 74 70 3a 3a 64 61 74 61 20 24 74 6f 6b 65 6e  ttp::data $token
d300: 5d 0a 63 6c 6f 73 65 20 24 63 68 0a 23 20 43 6c  ].close $ch.# Cl
d310: 65 61 6e 75 70 0a 3a 3a 68 74 74 70 3a 3a 63 6c  eanup.::http::cl
d320: 65 61 6e 75 70 20 24 74 6f 6b 65 6e 0a 3c 2f 70  eanup $token.</p
d330: 72 65 3e 0a 3c 70 3e 45 78 61 6d 70 6c 65 20 23  re>.<p>Example #
d340: 32 3a 20 44 6f 77 6e 6c 6f 61 64 20 61 20 66 69  2: Download a fi
d350: 6c 65 3c 2f 70 3e 0a 3c 70 72 65 20 63 6c 61 73  le</p>.<pre clas
d360: 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 65 78 61 6d  s="doctools_exam
d370: 70 6c 65 22 3e 0a 70 61 63 6b 61 67 65 20 72 65  ple">.package re
d380: 71 75 69 72 65 20 68 74 74 70 0a 70 61 63 6b 61  quire http.packa
d390: 67 65 20 72 65 71 75 69 72 65 20 74 6c 73 0a 73  ge require tls.s
d3a0: 65 74 20 75 72 6c 20 26 71 75 6f 74 3b 68 74 74  et url &quot;htt
d3b0: 70 73 3a 2f 2f 77 69 6b 69 2e 74 63 6c 2d 6c 61  ps://wiki.tcl-la
d3c0: 6e 67 2e 6f 72 67 2f 73 69 74 65 6d 61 70 2e 78  ng.org/sitemap.x
d3d0: 6d 6c 26 71 75 6f 74 3b 0a 68 74 74 70 3a 3a 72  ml&quot;.http::r
d3e0: 65 67 69 73 74 65 72 20 68 74 74 70 73 20 34 34  egister https 44
d3f0: 33 20 5b 6c 69 73 74 20 3a 3a 74 6c 73 3a 3a 73  3 [list ::tls::s
d400: 6f 63 6b 65 74 20 2d 61 75 74 6f 73 65 72 76 65  ocket -autoserve
d410: 72 6e 61 6d 65 20 31 20 2d 72 65 71 75 69 72 65  rname 1 -require
d420: 20 31 5d 0a 23 20 4f 70 65 6e 20 6f 75 74 70 75   1].# Open outpu
d430: 74 20 66 69 6c 65 0a 73 65 74 20 66 69 6c 65 6e  t file.set filen
d440: 61 6d 65 20 5b 66 69 6c 65 20 74 61 69 6c 20 24  ame [file tail $
d450: 75 72 6c 5d 0a 73 65 74 20 63 68 20 5b 6f 70 65  url].set ch [ope
d460: 6e 20 24 66 69 6c 65 6e 61 6d 65 20 77 62 5d 0a  n $filename wb].
d470: 23 20 47 65 74 20 66 69 6c 65 0a 73 65 74 20 74  # Get file.set t
d480: 6f 6b 65 6e 20 5b 3a 3a 68 74 74 70 3a 3a 67 65  oken [::http::ge
d490: 74 75 72 6c 20 24 75 72 6c 20 2d 62 6c 6f 63 6b  turl $url -block
d4a0: 73 69 7a 65 20 36 35 35 33 36 20 2d 63 68 61 6e  size 65536 -chan
d4b0: 6e 65 6c 20 24 63 68 5d 0a 23 20 43 68 65 63 6b  nel $ch].# Check
d4c0: 20 66 6f 72 20 65 72 72 6f 72 0a 69 66 20 7b 5b   for error.if {[
d4d0: 68 74 74 70 3a 3a 73 74 61 74 75 73 20 24 74 6f  http::status $to
d4e0: 6b 65 6e 5d 20 6e 65 20 26 71 75 6f 74 3b 6f 6b  ken] ne &quot;ok
d4f0: 26 71 75 6f 74 3b 7d 20 7b 0a 20 20 20 20 70 75  &quot;} {.    pu
d500: 74 73 20 5b 66 6f 72 6d 61 74 20 26 71 75 6f 74  ts [format &quot
d510: 3b 45 72 72 6f 72 20 25 73 26 71 75 6f 74 3b 20  ;Error %s&quot; 
d520: 5b 68 74 74 70 3a 3a 73 74 61 74 75 73 20 24 74  [http::status $t
d530: 6f 6b 65 6e 5d 5d 0a 7d 0a 23 20 43 6c 65 61 6e  oken]].}.# Clean
d540: 75 70 0a 63 6c 6f 73 65 20 24 63 68 0a 3a 3a 68  up.close $ch.::h
d550: 74 74 70 3a 3a 63 6c 65 61 6e 75 70 20 24 74 6f  ttp::cleanup $to
d560: 6b 65 6e 0a 3c 2f 70 72 65 3e 0a 3c 2f 64 69 76  ken.</pre>.</div
d570: 3e 0a 3c 64 69 76 20 69 64 3d 22 73 65 63 74 69  >.<div id="secti
d580: 6f 6e 38 22 20 63 6c 61 73 73 3d 22 64 6f 63 74  on8" class="doct
d590: 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c 68  ools_section"><h
d5a0: 32 3e 3c 61 20 6e 61 6d 65 3d 22 73 65 63 74 69  2><a name="secti
d5b0: 6f 6e 38 22 3e 53 70 65 63 69 61 6c 20 43 6f 6e  on8">Special Con
d5c0: 73 69 64 65 72 61 74 69 6f 6e 73 3c 2f 61 3e 3c  siderations</a><
d5d0: 2f 68 32 3e 0a 3c 70 3e 54 68 65 20 63 61 70 61  /h2>.<p>The capa
d5e0: 62 69 6c 69 74 69 65 73 20 6f 66 20 74 68 69 73  bilities of this
d5f0: 20 70 61 63 6b 61 67 65 20 63 61 6e 20 76 61 72   package can var
d600: 79 20 65 6e 6f 72 6d 6f 75 73 6c 79 20 62 61 73  y enormously bas
d610: 65 64 20 75 70 6f 6e 20 68 6f 77 20 74 68 65 0a  ed upon how the.
d620: 6c 69 6e 6b 65 64 20 74 6f 20 4f 70 65 6e 53 53  linked to OpenSS
d630: 4c 20 6c 69 62 72 61 72 79 20 77 61 73 20 63 6f  L library was co
d640: 6e 66 69 67 75 72 65 64 20 61 6e 64 20 62 75 69  nfigured and bui
d650: 6c 74 2e 20 4e 65 77 20 76 65 72 73 69 6f 6e 73  lt. New versions
d660: 20 6d 61 79 20 6f 62 73 6f 6c 65 74 65 0a 6f 6c   may obsolete.ol
d670: 64 65 72 20 70 72 6f 74 6f 63 6f 6c 20 76 65 72  der protocol ver
d680: 73 69 6f 6e 73 2c 20 61 64 64 20 6f 72 20 72 65  sions, add or re
d690: 6d 6f 76 65 20 63 69 70 68 65 72 73 2c 20 63 68  move ciphers, ch
d6a0: 61 6e 67 65 20 64 65 66 61 75 6c 74 20 76 61 6c  ange default val
d6b0: 75 65 73 2c 20 65 74 63 2e 0a 55 73 65 20 74 68  ues, etc..Use th
d6c0: 65 20 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22  e <b class="cmd"
d6d0: 3e 74 6c 73 3a 3a 70 72 6f 74 6f 63 6f 6c 73 3c  >tls::protocols<
d6e0: 2f 62 3e 20 63 6f 6d 6d 61 6e 64 73 20 74 6f 20  /b> commands to 
d6f0: 6f 62 74 61 69 6e 20 74 68 65 20 73 75 70 70 6f  obtain the suppo
d700: 72 74 65 64 0a 70 72 6f 74 6f 63 6f 6c 20 76 65  rted.protocol ve
d710: 72 73 69 6f 6e 73 2e 3c 2f 70 3e 0a 3c 2f 64 69  rsions.</p>.</di
d720: 76 3e 0a 3c 64 69 76 20 69 64 3d 22 73 65 65 2d  v>.<div id="see-
d730: 61 6c 73 6f 22 20 63 6c 61 73 73 3d 22 64 6f 63  also" class="doc
d740: 74 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c  tools_section"><
d750: 68 32 3e 3c 61 20 6e 61 6d 65 3d 22 73 65 65 2d  h2><a name="see-
d760: 61 6c 73 6f 22 3e 53 65 65 20 41 6c 73 6f 3c 2f  also">See Also</
d770: 61 3e 3c 2f 68 32 3e 0a 3c 70 3e 3c 61 20 68 72  a></h2>.<p><a hr
d780: 65 66 3d 22 68 74 74 70 73 3a 2f 2f 77 77 77 2e  ef="https://www.
d790: 6f 70 65 6e 73 73 6c 2e 6f 72 67 2f 22 3e 4f 70  openssl.org/">Op
d7a0: 65 6e 53 53 4c 3c 2f 61 3e 2c 20 68 74 74 70 2c  enSSL</a>, http,
d7b0: 20 73 6f 63 6b 65 74 3c 2f 70 3e 0a 3c 2f 64 69   socket</p>.</di
d7c0: 76 3e 0a 3c 64 69 76 20 69 64 3d 22 6b 65 79 77  v>.<div id="keyw
d7d0: 6f 72 64 73 22 20 63 6c 61 73 73 3d 22 64 6f 63  ords" class="doc
d7e0: 74 6f 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c  tools_section"><
d7f0: 68 32 3e 3c 61 20 6e 61 6d 65 3d 22 6b 65 79 77  h2><a name="keyw
d800: 6f 72 64 73 22 3e 4b 65 79 77 6f 72 64 73 3c 2f  ords">Keywords</
d810: 61 3e 3c 2f 68 32 3e 0a 3c 70 3e 49 2f 4f 2c 20  a></h2>.<p>I/O, 
d820: 49 50 20 41 64 64 72 65 73 73 2c 20 4f 70 65 6e  IP Address, Open
d830: 53 53 4c 2c 20 53 53 4c 2c 20 54 43 50 2c 20 54  SSL, SSL, TCP, T
d840: 4c 53 2c 20 54 63 6c 54 4c 53 2c 20 61 73 79 6e  LS, TclTLS, asyn
d850: 63 68 72 6f 6e 6f 75 73 20 49 2f 4f 2c 20 62 69  chronous I/O, bi
d860: 6e 64 2c 20 63 65 72 74 69 66 69 63 61 74 65 2c  nd, certificate,
d870: 20 63 68 61 6e 6e 65 6c 2c 20 63 6f 6e 6e 65 63   channel, connec
d880: 74 69 6f 6e 2c 20 64 6f 6d 61 69 6e 20 6e 61 6d  tion, domain nam
d890: 65 2c 20 68 6f 73 74 2c 20 68 74 74 70 73 2c 20  e, host, https, 
d8a0: 6e 65 74 77 6f 72 6b 2c 20 6e 65 74 77 6f 72 6b  network, network
d8b0: 20 61 64 64 72 65 73 73 2c 20 73 6f 63 6b 65 74   address, socket
d8c0: 2c 20 74 6c 73 3c 2f 70 3e 0a 3c 2f 64 69 76 3e  , tls</p>.</div>
d8d0: 0a 3c 64 69 76 20 69 64 3d 22 63 61 74 65 67 6f  .<div id="catego
d8e0: 72 79 22 20 63 6c 61 73 73 3d 22 64 6f 63 74 6f  ry" class="docto
d8f0: 6f 6c 73 5f 73 65 63 74 69 6f 6e 22 3e 3c 68 32  ols_section"><h2
d900: 3e 3c 61 20 6e 61 6d 65 3d 22 63 61 74 65 67 6f  ><a name="catego
d910: 72 79 22 3e 43 61 74 65 67 6f 72 79 3c 2f 61 3e  ry">Category</a>
d920: 3c 2f 68 32 3e 0a 3c 70 3e 74 6c 73 3c 2f 70 3e  </h2>.<p>tls</p>
d930: 0a 3c 2f 64 69 76 3e 0a 3c 64 69 76 20 69 64 3d  .</div>.<div id=
d940: 22 63 6f 70 79 72 69 67 68 74 22 20 63 6c 61 73  "copyright" clas
d950: 73 3d 22 64 6f 63 74 6f 6f 6c 73 5f 73 65 63 74  s="doctools_sect
d960: 69 6f 6e 22 3e 3c 68 32 3e 3c 61 20 6e 61 6d 65  ion"><h2><a name
d970: 3d 22 63 6f 70 79 72 69 67 68 74 22 3e 43 6f 70  ="copyright">Cop
d980: 79 72 69 67 68 74 3c 2f 61 3e 3c 2f 68 32 3e 0a  yright</a></h2>.
d990: 3c 70 3e 43 6f 70 79 72 69 67 68 74 20 26 63 6f  <p>Copyright &co
d9a0: 70 79 3b 20 31 39 39 39 20 4d 61 74 74 20 4e 65  py; 1999 Matt Ne
d9b0: 77 6d 61 6e 3c 62 72 3e 0a 43 6f 70 79 72 69 67  wman<br>.Copyrig
d9c0: 68 74 20 26 63 6f 70 79 3b 20 32 30 30 34 20 53  ht &copy; 2004 S
d9d0: 74 61 72 66 69 73 68 20 53 79 73 74 65 6d 73 3c  tarfish Systems<
d9e0: 62 72 3e 0a 43 6f 70 79 72 69 67 68 74 20 26 63  br>.Copyright &c
d9f0: 6f 70 79 3b 20 32 30 32 34 20 42 72 69 61 6e 20  opy; 2024 Brian 
da00: 4f 27 48 61 67 61 6e 3c 2f 70 3e 0a 3c 2f 64 69  O'Hagan</p>.</di
da10: 76 3e 0a 3c 2f 64 69 76 3e 3c 2f 62 6f 64 79 3e  v>.</div></body>
da20: 3c 2f 68 74 6d 6c 3e 0a                          </html>.