0000: 27 5c 22 0a 27 5c 22 20 47 65 6e 65 72 61 74 65 '\".'\" Generate
0010: 64 20 66 72 6f 6d 20 66 69 6c 65 20 27 74 6c 73 d from file 'tls
0020: 5c 26 2e 6d 61 6e 27 20 62 79 20 74 63 6c 6c 69 \&.man' by tclli
0030: 62 2f 64 6f 63 74 6f 6f 6c 73 20 77 69 74 68 20 b/doctools with
0040: 66 6f 72 6d 61 74 20 27 6e 72 6f 66 66 27 0a 27 format 'nroff'.'
0050: 5c 22 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 \" Copyright (c)
0060: 20 31 39 39 39 20 4d 61 74 74 20 4e 65 77 6d 61 1999 Matt Newma
0070: 6e 0a 27 5c 22 20 43 6f 70 79 72 69 67 68 74 20 n.'\" Copyright
0080: 28 63 29 20 32 30 30 34 20 53 74 61 72 66 69 73 (c) 2004 Starfis
0090: 68 20 53 79 73 74 65 6d 73 0a 27 5c 22 20 43 6f h Systems.'\" Co
00a0: 70 79 72 69 67 68 74 20 28 63 29 20 32 30 32 34 pyright (c) 2024
00b0: 20 42 72 69 61 6e 20 4f 27 48 61 67 61 6e 0a 27 Brian O'Hagan.'
00c0: 5c 22 0a 2e 54 48 20 22 74 6c 73 22 20 6e 20 32 \"..TH "tls" n 2
00d0: 5c 26 2e 30 62 31 20 74 6c 73 20 22 54 63 6c 20 \&.0b1 tls "Tcl
00e0: 54 4c 53 20 65 78 74 65 6e 73 69 6f 6e 22 0a 2e TLS extension"..
00f0: 5c 22 20 54 68 65 20 2d 2a 2d 20 6e 72 6f 66 66 \" The -*- nroff
0100: 20 2d 2a 2d 20 64 65 66 69 6e 69 74 69 6f 6e 73 -*- definitions
0110: 20 62 65 6c 6f 77 20 61 72 65 20 66 6f 72 20 73 below are for s
0120: 75 70 70 6c 65 6d 65 6e 74 61 6c 20 6d 61 63 72 upplemental macr
0130: 6f 73 20 75 73 65 64 0a 2e 5c 22 20 69 6e 20 54 os used..\" in T
0140: 63 6c 2f 54 6b 20 6d 61 6e 75 61 6c 20 65 6e 74 cl/Tk manual ent
0150: 72 69 65 73 2e 0a 2e 5c 22 0a 2e 5c 22 20 2e 41 ries...\"..\" .A
0160: 50 20 74 79 70 65 20 6e 61 6d 65 20 69 6e 2f 6f P type name in/o
0170: 75 74 20 3f 69 6e 64 65 6e 74 3f 0a 2e 5c 22 09 ut ?indent?..\".
0180: 53 74 61 72 74 20 70 61 72 61 67 72 61 70 68 20 Start paragraph
0190: 64 65 73 63 72 69 62 69 6e 67 20 61 6e 20 61 72 describing an ar
01a0: 67 75 6d 65 6e 74 20 74 6f 20 61 20 6c 69 62 72 gument to a libr
01b0: 61 72 79 20 70 72 6f 63 65 64 75 72 65 2e 0a 2e ary procedure...
01c0: 5c 22 09 74 79 70 65 20 69 73 20 74 79 70 65 20 \".type is type
01d0: 6f 66 20 61 72 67 75 6d 65 6e 74 20 28 69 6e 74 of argument (int
01e0: 2c 20 65 74 63 2e 29 2c 20 69 6e 2f 6f 75 74 20 , etc.), in/out
01f0: 69 73 20 65 69 74 68 65 72 20 22 69 6e 22 2c 20 is either "in",
0200: 22 6f 75 74 22 2c 0a 2e 5c 22 09 6f 72 20 22 69 "out",..\".or "i
0210: 6e 2f 6f 75 74 22 20 74 6f 20 64 65 73 63 72 69 n/out" to descri
0220: 62 65 20 77 68 65 74 68 65 72 20 70 72 6f 63 65 be whether proce
0230: 64 75 72 65 20 72 65 61 64 73 20 6f 72 20 6d 6f dure reads or mo
0240: 64 69 66 69 65 73 20 61 72 67 2c 0a 2e 5c 22 09 difies arg,..\".
0250: 61 6e 64 20 69 6e 64 65 6e 74 20 69 73 20 65 71 and indent is eq
0260: 75 69 76 61 6c 65 6e 74 20 74 6f 20 73 65 63 6f uivalent to seco
0270: 6e 64 20 61 72 67 20 6f 66 20 2e 49 50 20 28 73 nd arg of .IP (s
0280: 68 6f 75 6c 64 6e 27 74 20 65 76 65 72 20 62 65 houldn't ever be
0290: 0a 2e 5c 22 09 6e 65 65 64 65 64 3b 20 20 75 73 ..\".needed; us
02a0: 65 20 2e 41 53 20 62 65 6c 6f 77 20 69 6e 73 74 e .AS below inst
02b0: 65 61 64 29 0a 2e 5c 22 0a 2e 5c 22 20 2e 41 53 ead)..\"..\" .AS
02c0: 20 3f 74 79 70 65 3f 20 3f 6e 61 6d 65 3f 0a 2e ?type? ?name?..
02d0: 5c 22 09 47 69 76 65 20 6d 61 78 69 6d 75 6d 20 \".Give maximum
02e0: 73 69 7a 65 73 20 6f 66 20 61 72 67 75 6d 65 6e sizes of argumen
02f0: 74 73 20 66 6f 72 20 73 65 74 74 69 6e 67 20 74 ts for setting t
0300: 61 62 20 73 74 6f 70 73 2e 20 20 54 79 70 65 20 ab stops. Type
0310: 61 6e 64 0a 2e 5c 22 09 6e 61 6d 65 20 61 72 65 and..\".name are
0320: 20 65 78 61 6d 70 6c 65 73 20 6f 66 20 6c 61 72 examples of lar
0330: 67 65 73 74 20 70 6f 73 73 69 62 6c 65 20 61 72 gest possible ar
0340: 67 75 6d 65 6e 74 73 20 74 68 61 74 20 77 69 6c guments that wil
0350: 6c 20 62 65 20 70 61 73 73 65 64 0a 2e 5c 22 09 l be passed..\".
0360: 74 6f 20 2e 41 50 20 6c 61 74 65 72 2e 20 20 49 to .AP later. I
0370: 66 20 61 72 67 73 20 61 72 65 20 6f 6d 69 74 74 f args are omitt
0380: 65 64 2c 20 64 65 66 61 75 6c 74 20 74 61 62 20 ed, default tab
0390: 73 74 6f 70 73 20 61 72 65 20 75 73 65 64 2e 0a stops are used..
03a0: 2e 5c 22 0a 2e 5c 22 20 2e 42 53 0a 2e 5c 22 09 .\"..\" .BS..\".
03b0: 53 74 61 72 74 20 62 6f 78 20 65 6e 63 6c 6f 73 Start box enclos
03c0: 75 72 65 2e 20 20 46 72 6f 6d 20 68 65 72 65 20 ure. From here
03d0: 75 6e 74 69 6c 20 6e 65 78 74 20 2e 42 45 2c 20 until next .BE,
03e0: 65 76 65 72 79 74 68 69 6e 67 20 77 69 6c 6c 20 everything will
03f0: 62 65 0a 2e 5c 22 09 65 6e 63 6c 6f 73 65 64 20 be..\".enclosed
0400: 69 6e 20 6f 6e 65 20 6c 61 72 67 65 20 62 6f 78 in one large box
0410: 2e 0a 2e 5c 22 0a 2e 5c 22 20 2e 42 45 0a 2e 5c ...\"..\" .BE..\
0420: 22 09 45 6e 64 20 6f 66 20 62 6f 78 20 65 6e 63 ".End of box enc
0430: 6c 6f 73 75 72 65 2e 0a 2e 5c 22 0a 2e 5c 22 20 losure...\"..\"
0440: 2e 43 53 0a 2e 5c 22 09 42 65 67 69 6e 20 63 6f .CS..\".Begin co
0450: 64 65 20 65 78 63 65 72 70 74 2e 0a 2e 5c 22 0a de excerpt...\".
0460: 2e 5c 22 20 2e 43 45 0a 2e 5c 22 09 45 6e 64 20 .\" .CE..\".End
0470: 63 6f 64 65 20 65 78 63 65 72 70 74 2e 0a 2e 5c code excerpt...\
0480: 22 0a 2e 5c 22 20 2e 56 53 20 3f 76 65 72 73 69 "..\" .VS ?versi
0490: 6f 6e 3f 20 3f 62 72 3f 0a 2e 5c 22 09 42 65 67 on? ?br?..\".Beg
04a0: 69 6e 20 76 65 72 74 69 63 61 6c 20 73 69 64 65 in vertical side
04b0: 62 61 72 2c 20 66 6f 72 20 75 73 65 20 69 6e 20 bar, for use in
04c0: 6d 61 72 6b 69 6e 67 20 6e 65 77 6c 79 2d 63 68 marking newly-ch
04d0: 61 6e 67 65 64 20 70 61 72 74 73 0a 2e 5c 22 09 anged parts..\".
04e0: 6f 66 20 6d 61 6e 20 70 61 67 65 73 2e 20 20 54 of man pages. T
04f0: 68 65 20 66 69 72 73 74 20 61 72 67 75 6d 65 6e he first argumen
0500: 74 20 69 73 20 69 67 6e 6f 72 65 64 20 61 6e 64 t is ignored and
0510: 20 75 73 65 64 20 66 6f 72 20 72 65 63 6f 72 64 used for record
0520: 69 6e 67 0a 2e 5c 22 09 74 68 65 20 76 65 72 73 ing..\".the vers
0530: 69 6f 6e 20 77 68 65 6e 20 74 68 65 20 2e 56 53 ion when the .VS
0540: 20 77 61 73 20 61 64 64 65 64 2c 20 73 6f 20 74 was added, so t
0550: 68 61 74 20 74 68 65 20 73 69 64 65 62 61 72 73 hat the sidebars
0560: 20 63 61 6e 20 62 65 0a 2e 5c 22 09 66 6f 75 6e can be..\".foun
0570: 64 20 61 6e 64 20 72 65 6d 6f 76 65 64 20 77 68 d and removed wh
0580: 65 6e 20 74 68 65 79 20 72 65 61 63 68 20 61 20 en they reach a
0590: 63 65 72 74 61 69 6e 20 61 67 65 2e 20 20 49 66 certain age. If
05a0: 20 61 6e 6f 74 68 65 72 20 61 72 67 75 6d 65 6e another argumen
05b0: 74 0a 2e 5c 22 09 69 73 20 70 72 65 73 65 6e 74 t..\".is present
05c0: 2c 20 74 68 65 6e 20 61 20 6c 69 6e 65 20 62 72 , then a line br
05d0: 65 61 6b 20 69 73 20 66 6f 72 63 65 64 20 62 65 eak is forced be
05e0: 66 6f 72 65 20 73 74 61 72 74 69 6e 67 20 74 68 fore starting th
05f0: 65 20 73 69 64 65 62 61 72 2e 0a 2e 5c 22 0a 2e e sidebar...\"..
0600: 5c 22 20 2e 56 45 0a 2e 5c 22 09 45 6e 64 20 6f \" .VE..\".End o
0610: 66 20 76 65 72 74 69 63 61 6c 20 73 69 64 65 62 f vertical sideb
0620: 61 72 2e 0a 2e 5c 22 0a 2e 5c 22 20 2e 44 53 0a ar...\"..\" .DS.
0630: 2e 5c 22 09 42 65 67 69 6e 20 61 6e 20 69 6e 64 .\".Begin an ind
0640: 65 6e 74 65 64 20 75 6e 66 69 6c 6c 65 64 20 64 ented unfilled d
0650: 69 73 70 6c 61 79 2e 0a 2e 5c 22 0a 2e 5c 22 20 isplay...\"..\"
0660: 2e 44 45 0a 2e 5c 22 09 45 6e 64 20 6f 66 20 69 .DE..\".End of i
0670: 6e 64 65 6e 74 65 64 20 75 6e 66 69 6c 6c 65 64 ndented unfilled
0680: 20 64 69 73 70 6c 61 79 2e 0a 2e 5c 22 0a 2e 5c display...\"..\
0690: 22 20 2e 53 4f 20 3f 6d 61 6e 70 61 67 65 3f 0a " .SO ?manpage?.
06a0: 2e 5c 22 09 53 74 61 72 74 20 6f 66 20 6c 69 73 .\".Start of lis
06b0: 74 20 6f 66 20 73 74 61 6e 64 61 72 64 20 6f 70 t of standard op
06c0: 74 69 6f 6e 73 20 66 6f 72 20 61 20 54 6b 20 77 tions for a Tk w
06d0: 69 64 67 65 74 2e 20 54 68 65 20 6d 61 6e 70 61 idget. The manpa
06e0: 67 65 0a 2e 5c 22 09 61 72 67 75 6d 65 6e 74 20 ge..\".argument
06f0: 64 65 66 69 6e 65 73 20 77 68 65 72 65 20 74 6f defines where to
0700: 20 6c 6f 6f 6b 20 75 70 20 74 68 65 20 73 74 61 look up the sta
0710: 6e 64 61 72 64 20 6f 70 74 69 6f 6e 73 3b 20 69 ndard options; i
0720: 66 0a 2e 5c 22 09 6f 6d 69 74 74 65 64 2c 20 64 f..\".omitted, d
0730: 65 66 61 75 6c 74 73 20 74 6f 20 22 6f 70 74 69 efaults to "opti
0740: 6f 6e 73 22 2e 20 54 68 65 20 6f 70 74 69 6f 6e ons". The option
0750: 73 20 66 6f 6c 6c 6f 77 20 6f 6e 20 73 75 63 63 s follow on succ
0760: 65 73 73 69 76 65 0a 2e 5c 22 09 6c 69 6e 65 73 essive..\".lines
0770: 2c 20 69 6e 20 74 68 72 65 65 20 63 6f 6c 75 6d , in three colum
0780: 6e 73 20 73 65 70 61 72 61 74 65 64 20 62 79 20 ns separated by
0790: 74 61 62 73 2e 0a 2e 5c 22 0a 2e 5c 22 20 2e 53 tabs...\"..\" .S
07a0: 45 0a 2e 5c 22 09 45 6e 64 20 6f 66 20 6c 69 73 E..\".End of lis
07b0: 74 20 6f 66 20 73 74 61 6e 64 61 72 64 20 6f 70 t of standard op
07c0: 74 69 6f 6e 73 20 66 6f 72 20 61 20 54 6b 20 77 tions for a Tk w
07d0: 69 64 67 65 74 2e 0a 2e 5c 22 0a 2e 5c 22 20 2e idget...\"..\" .
07e0: 4f 50 20 63 6d 64 4e 61 6d 65 20 64 62 4e 61 6d OP cmdName dbNam
07f0: 65 20 64 62 43 6c 61 73 73 0a 2e 5c 22 09 53 74 e dbClass..\".St
0800: 61 72 74 20 6f 66 20 64 65 73 63 72 69 70 74 69 art of descripti
0810: 6f 6e 20 6f 66 20 61 20 73 70 65 63 69 66 69 63 on of a specific
0820: 20 6f 70 74 69 6f 6e 2e 20 20 63 6d 64 4e 61 6d option. cmdNam
0830: 65 20 67 69 76 65 73 20 74 68 65 0a 2e 5c 22 09 e gives the..\".
0840: 6f 70 74 69 6f 6e 27 73 20 6e 61 6d 65 20 61 73 option's name as
0850: 20 73 70 65 63 69 66 69 65 64 20 69 6e 20 74 68 specified in th
0860: 65 20 63 6c 61 73 73 20 63 6f 6d 6d 61 6e 64 2c e class command,
0870: 20 64 62 4e 61 6d 65 20 67 69 76 65 73 0a 2e 5c dbName gives..\
0880: 22 09 74 68 65 20 6f 70 74 69 6f 6e 27 73 20 6e ".the option's n
0890: 61 6d 65 20 69 6e 20 74 68 65 20 6f 70 74 69 6f ame in the optio
08a0: 6e 20 64 61 74 61 62 61 73 65 2c 20 61 6e 64 20 n database, and
08b0: 64 62 43 6c 61 73 73 20 67 69 76 65 73 0a 2e 5c dbClass gives..\
08c0: 22 09 74 68 65 20 6f 70 74 69 6f 6e 27 73 20 63 ".the option's c
08d0: 6c 61 73 73 20 69 6e 20 74 68 65 20 6f 70 74 69 lass in the opti
08e0: 6f 6e 20 64 61 74 61 62 61 73 65 2e 0a 2e 5c 22 on database...\"
08f0: 0a 2e 5c 22 20 2e 55 4c 20 61 72 67 31 20 61 72 ..\" .UL arg1 ar
0900: 67 32 0a 2e 5c 22 09 50 72 69 6e 74 20 61 72 67 g2..\".Print arg
0910: 31 20 75 6e 64 65 72 6c 69 6e 65 64 2c 20 74 68 1 underlined, th
0920: 65 6e 20 70 72 69 6e 74 20 61 72 67 32 20 6e 6f en print arg2 no
0930: 72 6d 61 6c 6c 79 2e 0a 2e 5c 22 0a 2e 5c 22 20 rmally...\"..\"
0940: 2e 51 57 20 61 72 67 31 20 3f 61 72 67 32 3f 0a .QW arg1 ?arg2?.
0950: 2e 5c 22 09 50 72 69 6e 74 20 61 72 67 31 20 69 .\".Print arg1 i
0960: 6e 20 71 75 6f 74 65 73 2c 20 74 68 65 6e 20 61 n quotes, then a
0970: 72 67 32 20 6e 6f 72 6d 61 6c 6c 79 20 28 66 6f rg2 normally (fo
0980: 72 20 74 72 61 69 6c 69 6e 67 20 70 75 6e 63 74 r trailing punct
0990: 75 61 74 69 6f 6e 29 2e 0a 2e 5c 22 0a 2e 5c 22 uation)...\"..\"
09a0: 20 2e 50 51 20 61 72 67 31 20 3f 61 72 67 32 3f .PQ arg1 ?arg2?
09b0: 0a 2e 5c 22 09 50 72 69 6e 74 20 61 6e 20 6f 70 ..\".Print an op
09c0: 65 6e 20 70 61 72 65 6e 74 68 65 73 69 73 2c 20 en parenthesis,
09d0: 61 72 67 31 20 69 6e 20 71 75 6f 74 65 73 2c 20 arg1 in quotes,
09e0: 74 68 65 6e 20 61 72 67 32 20 6e 6f 72 6d 61 6c then arg2 normal
09f0: 6c 79 0a 2e 5c 22 09 28 66 6f 72 20 74 72 61 69 ly..\".(for trai
0a00: 6c 69 6e 67 20 70 75 6e 63 74 75 61 74 69 6f 6e ling punctuation
0a10: 29 20 61 6e 64 20 74 68 65 6e 20 61 20 63 6c 6f ) and then a clo
0a20: 73 69 6e 67 20 70 61 72 65 6e 74 68 65 73 69 73 sing parenthesis
0a30: 2e 0a 2e 5c 22 0a 2e 5c 22 09 23 20 53 65 74 20 ...\"..\".# Set
0a40: 75 70 20 74 72 61 70 73 20 61 6e 64 20 6f 74 68 up traps and oth
0a50: 65 72 20 6d 69 73 63 65 6c 6c 61 6e 65 6f 75 73 er miscellaneous
0a60: 20 73 74 75 66 66 20 66 6f 72 20 54 63 6c 2f 54 stuff for Tcl/T
0a70: 6b 20 6d 61 6e 20 70 61 67 65 73 2e 0a 2e 69 66 k man pages...if
0a80: 20 74 20 2e 77 68 20 2d 31 2e 33 69 20 5e 42 0a t .wh -1.3i ^B.
0a90: 2e 6e 72 20 5e 6c 20 5c 6e 28 2e 6c 0a 2e 61 64 .nr ^l \n(.l..ad
0aa0: 20 62 0a 2e 5c 22 09 23 20 53 74 61 72 74 20 61 b..\".# Start a
0ab0: 6e 20 61 72 67 75 6d 65 6e 74 20 64 65 73 63 72 n argument descr
0ac0: 69 70 74 69 6f 6e 0a 2e 64 65 20 41 50 0a 2e 69 iption..de AP..i
0ad0: 65 20 21 22 5c 5c 24 34 22 22 20 2e 54 50 20 5c e !"\\$4"" .TP \
0ae0: 5c 24 34 0a 2e 65 6c 20 5c 7b 5c 0a 2e 20 20 20 \$4..el \{\..
0af0: 69 65 20 21 22 5c 5c 24 32 22 22 20 2e 54 50 20 ie !"\\$2"" .TP
0b00: 5c 5c 6e 28 29 43 75 0a 2e 20 20 20 65 6c 20 20 \\n()Cu.. el
0b10: 20 20 20 20 20 20 20 20 2e 54 50 20 31 35 0a 2e .TP 15..
0b20: 5c 7d 0a 2e 74 61 20 5c 5c 6e 28 29 41 75 20 5c \}..ta \\n()Au \
0b30: 5c 6e 28 29 42 75 0a 2e 69 65 20 21 22 5c 5c 24 \n()Bu..ie !"\\$
0b40: 33 22 22 20 5c 7b 5c 0a 5c 26 5c 5c 24 31 20 5c 3"" \{\.\&\\$1 \
0b50: 5c 66 49 5c 5c 24 32 5c 5c 66 50 20 28 5c 5c 24 \fI\\$2\\fP (\\$
0b60: 33 29 0a 2e 5c 22 2e 62 0a 2e 5c 7d 0a 2e 65 6c 3)..\".b..\}..el
0b70: 20 5c 7b 5c 0a 2e 62 72 0a 2e 69 65 20 21 22 5c \{\..br..ie !"\
0b80: 5c 24 32 22 22 20 5c 7b 5c 0a 5c 26 5c 5c 24 31 \$2"" \{\.\&\\$1
0b90: 09 5c 5c 66 49 5c 5c 24 32 5c 5c 66 50 0a 2e 5c .\\fI\\$2\\fP..\
0ba0: 7d 0a 2e 65 6c 20 5c 7b 5c 0a 5c 26 5c 5c 66 49 }..el \{\.\&\\fI
0bb0: 5c 5c 24 31 5c 5c 66 50 0a 2e 5c 7d 0a 2e 5c 7d \\$1\\fP..\}..\}
0bc0: 0a 2e 2e 0a 2e 5c 22 09 23 20 64 65 66 69 6e 65 .....\".# define
0bd0: 20 74 61 62 62 69 6e 67 20 76 61 6c 75 65 73 20 tabbing values
0be0: 66 6f 72 20 2e 41 50 0a 2e 64 65 20 41 53 0a 2e for .AP..de AS..
0bf0: 6e 72 20 29 41 20 31 30 6e 0a 2e 69 66 20 21 22 nr )A 10n..if !"
0c00: 5c 5c 24 31 22 22 20 2e 6e 72 20 29 41 20 5c 5c \\$1"" .nr )A \\
0c10: 77 27 5c 5c 24 31 27 75 2b 33 6e 0a 2e 6e 72 20 w'\\$1'u+3n..nr
0c20: 29 42 20 5c 5c 6e 28 29 41 75 2b 31 35 6e 0a 2e )B \\n()Au+15n..
0c30: 5c 22 0a 2e 69 66 20 21 22 5c 5c 24 32 22 22 20 \"..if !"\\$2""
0c40: 2e 6e 72 20 29 42 20 5c 5c 77 27 5c 5c 24 32 27 .nr )B \\w'\\$2'
0c50: 75 2b 5c 5c 6e 28 29 41 75 2b 33 6e 0a 2e 6e 72 u+\\n()Au+3n..nr
0c60: 20 29 43 20 5c 5c 6e 28 29 42 75 2b 5c 5c 77 27 )C \\n()Bu+\\w'
0c70: 28 69 6e 2f 6f 75 74 29 27 75 2b 32 6e 0a 2e 2e (in/out)'u+2n...
0c80: 0a 2e 41 53 20 54 63 6c 5f 49 6e 74 65 72 70 20 ..AS Tcl_Interp
0c90: 54 63 6c 5f 43 72 65 61 74 65 49 6e 74 65 72 70 Tcl_CreateInterp
0ca0: 20 69 6e 2f 6f 75 74 0a 2e 5c 22 09 23 20 42 53 in/out..\".# BS
0cb0: 20 2d 20 73 74 61 72 74 20 62 6f 78 65 64 20 74 - start boxed t
0cc0: 65 78 74 0a 2e 5c 22 09 23 20 5e 79 20 3d 20 73 ext..\".# ^y = s
0cd0: 74 61 72 74 69 6e 67 20 79 20 6c 6f 63 61 74 69 tarting y locati
0ce0: 6f 6e 0a 2e 5c 22 09 23 20 5e 62 20 3d 20 31 0a on..\".# ^b = 1.
0cf0: 2e 64 65 20 42 53 0a 2e 62 72 0a 2e 6d 6b 20 5e .de BS..br..mk ^
0d00: 79 0a 2e 6e 72 20 5e 62 20 31 75 0a 2e 69 66 20 y..nr ^b 1u..if
0d10: 6e 20 2e 6e 66 0a 2e 69 66 20 6e 20 2e 74 69 20 n .nf..if n .ti
0d20: 30 0a 2e 69 66 20 6e 20 5c 6c 27 5c 5c 6e 28 2e 0..if n \l'\\n(.
0d30: 6c 75 5c 28 75 6c 27 0a 2e 69 66 20 6e 20 2e 66 lu\(ul'..if n .f
0d40: 69 0a 2e 2e 0a 2e 5c 22 09 23 20 42 45 20 2d 20 i.....\".# BE -
0d50: 65 6e 64 20 62 6f 78 65 64 20 74 65 78 74 20 28 end boxed text (
0d60: 64 72 61 77 20 62 6f 78 20 6e 6f 77 29 0a 2e 64 draw box now)..d
0d70: 65 20 42 45 0a 2e 6e 66 0a 2e 74 69 20 30 0a 2e e BE..nf..ti 0..
0d80: 6d 6b 20 5e 74 0a 2e 69 65 20 6e 20 5c 6c 27 5c mk ^t..ie n \l'\
0d90: 5c 6e 28 5e 6c 75 5c 28 75 6c 27 0a 2e 65 6c 20 \n(^lu\(ul'..el
0da0: 5c 7b 5c 0a 2e 5c 22 09 44 72 61 77 20 66 6f 75 \{\..\".Draw fou
0db0: 72 2d 73 69 64 65 64 20 62 6f 78 20 6e 6f 72 6d r-sided box norm
0dc0: 61 6c 6c 79 2c 20 62 75 74 20 64 6f 6e 27 74 20 ally, but don't
0dd0: 64 72 61 77 20 74 6f 70 20 6f 66 0a 2e 5c 22 09 draw top of..\".
0de0: 62 6f 78 20 69 66 20 74 68 65 20 62 6f 78 20 73 box if the box s
0df0: 74 61 72 74 65 64 20 6f 6e 20 61 6e 20 65 61 72 tarted on an ear
0e00: 6c 69 65 72 20 70 61 67 65 2e 0a 2e 69 65 20 21 lier page...ie !
0e10: 5c 5c 6e 28 5e 62 2d 31 20 5c 7b 5c 0a 5c 68 27 \\n(^b-1 \{\.\h'
0e20: 2d 31 2e 35 6e 27 5c 4c 27 7c 5c 5c 6e 28 5e 79 -1.5n'\L'|\\n(^y
0e30: 75 2d 31 76 27 5c 6c 27 5c 5c 6e 28 5e 6c 75 2b u-1v'\l'\\n(^lu+
0e40: 33 6e 5c 28 75 6c 27 5c 4c 27 5c 5c 6e 28 5e 74 3n\(ul'\L'\\n(^t
0e50: 75 2b 31 76 2d 5c 5c 6e 28 5e 79 75 27 5c 6c 27 u+1v-\\n(^yu'\l'
0e60: 7c 30 75 2d 31 2e 35 6e 5c 28 75 6c 27 0a 2e 5c |0u-1.5n\(ul'..\
0e70: 7d 0a 2e 65 6c 20 5c 7d 5c 0a 5c 68 27 2d 31 2e }..el \}\.\h'-1.
0e80: 35 6e 27 5c 4c 27 7c 5c 5c 6e 28 5e 79 75 2d 31 5n'\L'|\\n(^yu-1
0e90: 76 27 5c 68 27 5c 5c 6e 28 5e 6c 75 2b 33 6e 27 v'\h'\\n(^lu+3n'
0ea0: 5c 4c 27 5c 5c 6e 28 5e 74 75 2b 31 76 2d 5c 5c \L'\\n(^tu+1v-\\
0eb0: 6e 28 5e 79 75 27 5c 6c 27 7c 30 75 2d 31 2e 35 n(^yu'\l'|0u-1.5
0ec0: 6e 5c 28 75 6c 27 0a 2e 5c 7d 0a 2e 5c 7d 0a 2e n\(ul'..\}..\}..
0ed0: 66 69 0a 2e 62 72 0a 2e 6e 72 20 5e 62 20 30 0a fi..br..nr ^b 0.
0ee0: 2e 2e 0a 2e 5c 22 09 23 20 56 53 20 2d 20 73 74 ....\".# VS - st
0ef0: 61 72 74 20 76 65 72 74 69 63 61 6c 20 73 69 64 art vertical sid
0f00: 65 62 61 72 0a 2e 5c 22 09 23 20 5e 59 20 3d 20 ebar..\".# ^Y =
0f10: 73 74 61 72 74 69 6e 67 20 79 20 6c 6f 63 61 74 starting y locat
0f20: 69 6f 6e 0a 2e 5c 22 09 23 20 5e 76 20 3d 20 31 ion..\".# ^v = 1
0f30: 20 28 66 6f 72 20 74 72 6f 66 66 3b 20 20 66 6f (for troff; fo
0f40: 72 20 6e 72 6f 66 66 20 74 68 69 73 20 64 6f 65 r nroff this doe
0f50: 73 6e 27 74 20 6d 61 74 74 65 72 29 0a 2e 64 65 sn't matter)..de
0f60: 20 56 53 0a 2e 69 66 20 21 22 5c 5c 24 32 22 22 VS..if !"\\$2""
0f70: 20 2e 62 72 0a 2e 6d 6b 20 5e 59 0a 2e 69 65 20 .br..mk ^Y..ie
0f80: 6e 20 27 6d 63 20 5c 73 31 32 5c 28 62 72 5c 73 n 'mc \s12\(br\s
0f90: 30 0a 2e 65 6c 20 2e 6e 72 20 5e 76 20 31 75 0a 0..el .nr ^v 1u.
0fa0: 2e 2e 0a 2e 5c 22 09 23 20 56 45 20 2d 20 65 6e ....\".# VE - en
0fb0: 64 20 6f 66 20 76 65 72 74 69 63 61 6c 20 73 69 d of vertical si
0fc0: 64 65 62 61 72 0a 2e 64 65 20 56 45 0a 2e 69 65 debar..de VE..ie
0fd0: 20 6e 20 27 6d 63 0a 2e 65 6c 20 5c 7b 5c 0a 2e n 'mc..el \{\..
0fe0: 65 76 20 32 0a 2e 6e 66 0a 2e 74 69 20 30 0a 2e ev 2..nf..ti 0..
0ff0: 6d 6b 20 5e 74 0a 5c 68 27 7c 5c 5c 6e 28 5e 6c mk ^t.\h'|\\n(^l
1000: 75 2b 33 6e 27 5c 4c 27 7c 5c 5c 6e 28 5e 59 75 u+3n'\L'|\\n(^Yu
1010: 2d 31 76 5c 28 62 76 27 5c 76 27 5c 5c 6e 28 5e -1v\(bv'\v'\\n(^
1020: 74 75 2b 31 76 2d 5c 5c 6e 28 5e 59 75 27 5c 68 tu+1v-\\n(^Yu'\h
1030: 27 2d 7c 5c 5c 6e 28 5e 6c 75 2b 33 6e 27 0a 2e '-|\\n(^lu+3n'..
1040: 73 70 20 2d 31 0a 2e 66 69 0a 2e 65 76 0a 2e 5c sp -1..fi..ev..\
1050: 7d 0a 2e 6e 72 20 5e 76 20 30 0a 2e 2e 0a 2e 5c }..nr ^v 0.....\
1060: 22 09 23 20 53 70 65 63 69 61 6c 20 6d 61 63 72 ".# Special macr
1070: 6f 20 74 6f 20 68 61 6e 64 6c 65 20 70 61 67 65 o to handle page
1080: 20 62 6f 74 74 6f 6d 3a 20 20 66 69 6e 69 73 68 bottom: finish
1090: 20 6f 66 66 20 63 75 72 72 65 6e 74 0a 2e 5c 22 off current..\"
10a0: 09 23 20 62 6f 78 2f 73 69 64 65 62 61 72 20 69 .# box/sidebar i
10b0: 66 20 69 6e 20 62 6f 78 2f 73 69 64 65 62 61 72 f in box/sidebar
10c0: 20 6d 6f 64 65 2c 20 74 68 65 6e 20 69 6e 76 6f mode, then invo
10d0: 6b 65 64 20 73 74 61 6e 64 61 72 64 0a 2e 5c 22 ked standard..\"
10e0: 09 23 20 70 61 67 65 20 62 6f 74 74 6f 6d 20 6d .# page bottom m
10f0: 61 63 72 6f 2e 0a 2e 64 65 20 5e 42 0a 2e 65 76 acro...de ^B..ev
1100: 20 32 0a 27 74 69 20 30 0a 27 6e 66 0a 2e 6d 6b 2.'ti 0.'nf..mk
1110: 20 5e 74 0a 2e 69 66 20 5c 5c 6e 28 5e 62 20 5c ^t..if \\n(^b \
1120: 7b 5c 0a 2e 5c 22 09 44 72 61 77 20 74 68 72 65 {\..\".Draw thre
1130: 65 2d 73 69 64 65 64 20 62 6f 78 20 69 66 20 74 e-sided box if t
1140: 68 69 73 20 69 73 20 74 68 65 20 62 6f 78 27 73 his is the box's
1150: 20 66 69 72 73 74 20 70 61 67 65 2c 0a 2e 5c 22 first page,..\"
1160: 09 64 72 61 77 20 74 77 6f 20 73 69 64 65 73 20 .draw two sides
1170: 62 75 74 20 6e 6f 20 74 6f 70 20 6f 74 68 65 72 but no top other
1180: 77 69 73 65 2e 0a 2e 69 65 20 21 5c 5c 6e 28 5e wise...ie !\\n(^
1190: 62 2d 31 20 5c 68 27 2d 31 2e 35 6e 27 5c 4c 27 b-1 \h'-1.5n'\L'
11a0: 7c 5c 5c 6e 28 5e 79 75 2d 31 76 27 5c 6c 27 5c |\\n(^yu-1v'\l'\
11b0: 5c 6e 28 5e 6c 75 2b 33 6e 5c 28 75 6c 27 5c 4c \n(^lu+3n\(ul'\L
11c0: 27 5c 5c 6e 28 5e 74 75 2b 31 76 2d 5c 5c 6e 28 '\\n(^tu+1v-\\n(
11d0: 5e 79 75 27 5c 68 27 7c 30 75 27 5c 63 0a 2e 65 ^yu'\h'|0u'\c..e
11e0: 6c 20 5c 68 27 2d 31 2e 35 6e 27 5c 4c 27 7c 5c l \h'-1.5n'\L'|\
11f0: 5c 6e 28 5e 79 75 2d 31 76 27 5c 68 27 5c 5c 6e \n(^yu-1v'\h'\\n
1200: 28 5e 6c 75 2b 33 6e 27 5c 4c 27 5c 5c 6e 28 5e (^lu+3n'\L'\\n(^
1210: 74 75 2b 31 76 2d 5c 5c 6e 28 5e 79 75 27 5c 68 tu+1v-\\n(^yu'\h
1220: 27 7c 30 75 27 5c 63 0a 2e 5c 7d 0a 2e 69 66 20 '|0u'\c..\}..if
1230: 5c 5c 6e 28 5e 76 20 5c 7b 5c 0a 2e 6e 72 20 5e \\n(^v \{\..nr ^
1240: 78 20 5c 5c 6e 28 5e 74 75 2b 31 76 2d 5c 5c 6e x \\n(^tu+1v-\\n
1250: 28 5e 59 75 0a 5c 6b 78 5c 68 27 2d 5c 5c 6e 78 (^Yu.\kx\h'-\\nx
1260: 75 27 5c 68 27 7c 5c 5c 6e 28 5e 6c 75 2b 33 6e u'\h'|\\n(^lu+3n
1270: 27 5c 6b 79 5c 4c 27 2d 5c 5c 6e 28 5e 78 75 27 '\ky\L'-\\n(^xu'
1280: 5c 76 27 5c 5c 6e 28 5e 78 75 27 5c 68 27 7c 30 \v'\\n(^xu'\h'|0
1290: 75 27 5c 63 0a 2e 5c 7d 0a 2e 62 70 0a 27 66 69 u'\c..\}..bp.'fi
12a0: 0a 2e 65 76 0a 2e 69 66 20 5c 5c 6e 28 5e 62 20 ..ev..if \\n(^b
12b0: 5c 7b 5c 0a 2e 6d 6b 20 5e 79 0a 2e 6e 72 20 5e \{\..mk ^y..nr ^
12c0: 62 20 32 0a 2e 5c 7d 0a 2e 69 66 20 5c 5c 6e 28 b 2..\}..if \\n(
12d0: 5e 76 20 5c 7b 5c 0a 2e 6d 6b 20 5e 59 0a 2e 5c ^v \{\..mk ^Y..\
12e0: 7d 0a 2e 2e 0a 2e 5c 22 09 23 20 44 53 20 2d 20 }.....\".# DS -
12f0: 62 65 67 69 6e 20 64 69 73 70 6c 61 79 0a 2e 64 begin display..d
1300: 65 20 44 53 0a 2e 52 53 0a 2e 6e 66 0a 2e 73 70 e DS..RS..nf..sp
1310: 0a 2e 2e 0a 2e 5c 22 09 23 20 44 45 20 2d 20 65 .....\".# DE - e
1320: 6e 64 20 64 69 73 70 6c 61 79 0a 2e 64 65 20 44 nd display..de D
1330: 45 0a 2e 66 69 0a 2e 52 45 0a 2e 73 70 0a 2e 2e E..fi..RE..sp...
1340: 0a 2e 5c 22 09 23 20 53 4f 20 2d 20 73 74 61 72 ..\".# SO - star
1350: 74 20 6f 66 20 6c 69 73 74 20 6f 66 20 73 74 61 t of list of sta
1360: 6e 64 61 72 64 20 6f 70 74 69 6f 6e 73 0a 2e 64 ndard options..d
1370: 65 20 53 4f 0a 27 69 65 20 27 5c 5c 24 31 27 27 e SO.'ie '\\$1''
1380: 20 2e 64 73 20 53 6f 20 5c 5c 66 42 6f 70 74 69 .ds So \\fBopti
1390: 6f 6e 73 5c 5c 66 52 0a 27 65 6c 20 2e 64 73 20 ons\\fR.'el .ds
13a0: 53 6f 20 5c 5c 66 42 5c 5c 24 31 5c 5c 66 52 0a So \\fB\\$1\\fR.
13b0: 2e 53 48 20 22 53 54 41 4e 44 41 52 44 20 4f 50 .SH "STANDARD OP
13c0: 54 49 4f 4e 53 22 0a 2e 4c 50 0a 2e 6e 66 0a 2e TIONS"..LP..nf..
13d0: 74 61 20 35 2e 35 63 20 31 31 63 0a 2e 66 74 20 ta 5.5c 11c..ft
13e0: 42 0a 2e 2e 0a 2e 5c 22 09 23 20 53 45 20 2d 20 B.....\".# SE -
13f0: 65 6e 64 20 6f 66 20 6c 69 73 74 20 6f 66 20 73 end of list of s
1400: 74 61 6e 64 61 72 64 20 6f 70 74 69 6f 6e 73 0a tandard options.
1410: 2e 64 65 20 53 45 0a 2e 66 69 0a 2e 66 74 20 52 .de SE..fi..ft R
1420: 0a 2e 4c 50 0a 53 65 65 20 74 68 65 20 5c 5c 2a ..LP.See the \\*
1430: 28 53 6f 20 6d 61 6e 75 61 6c 20 65 6e 74 72 79 (So manual entry
1440: 20 66 6f 72 20 64 65 74 61 69 6c 73 20 6f 6e 20 for details on
1450: 74 68 65 20 73 74 61 6e 64 61 72 64 20 6f 70 74 the standard opt
1460: 69 6f 6e 73 2e 0a 2e 2e 0a 2e 5c 22 09 23 20 4f ions......\".# O
1470: 50 20 2d 20 73 74 61 72 74 20 6f 66 20 66 75 6c P - start of ful
1480: 6c 20 64 65 73 63 72 69 70 74 69 6f 6e 20 66 6f l description fo
1490: 72 20 61 20 73 69 6e 67 6c 65 20 6f 70 74 69 6f r a single optio
14a0: 6e 0a 2e 64 65 20 4f 50 0a 2e 4c 50 0a 2e 6e 66 n..de OP..LP..nf
14b0: 0a 2e 74 61 20 34 63 0a 43 6f 6d 6d 61 6e 64 2d ..ta 4c.Command-
14c0: 4c 69 6e 65 20 4e 61 6d 65 3a 09 5c 5c 66 42 5c Line Name:.\\fB\
14d0: 5c 24 31 5c 5c 66 52 0a 44 61 74 61 62 61 73 65 \$1\\fR.Database
14e0: 20 4e 61 6d 65 3a 09 5c 5c 66 42 5c 5c 24 32 5c Name:.\\fB\\$2\
14f0: 5c 66 52 0a 44 61 74 61 62 61 73 65 20 43 6c 61 \fR.Database Cla
1500: 73 73 3a 09 5c 5c 66 42 5c 5c 24 33 5c 5c 66 52 ss:.\\fB\\$3\\fR
1510: 0a 2e 66 69 0a 2e 49 50 0a 2e 2e 0a 2e 5c 22 09 ..fi..IP.....\".
1520: 23 20 43 53 20 2d 20 62 65 67 69 6e 20 63 6f 64 # CS - begin cod
1530: 65 20 65 78 63 65 72 70 74 0a 2e 64 65 20 43 53 e excerpt..de CS
1540: 0a 2e 52 53 0a 2e 6e 66 0a 2e 74 61 20 2e 32 35 ..RS..nf..ta .25
1550: 69 20 2e 35 69 20 2e 37 35 69 20 31 69 0a 2e 2e i .5i .75i 1i...
1560: 0a 2e 5c 22 09 23 20 43 45 20 2d 20 65 6e 64 20 ..\".# CE - end
1570: 63 6f 64 65 20 65 78 63 65 72 70 74 0a 2e 64 65 code excerpt..de
1580: 20 43 45 0a 2e 66 69 0a 2e 52 45 0a 2e 2e 0a 2e CE..fi..RE.....
1590: 5c 22 09 23 20 55 4c 20 2d 20 75 6e 64 65 72 6c \".# UL - underl
15a0: 69 6e 65 20 77 6f 72 64 0a 2e 64 65 20 55 4c 0a ine word..de UL.
15b0: 5c 5c 24 31 5c 6c 27 7c 30 5c 28 75 6c 27 5c 5c \\$1\l'|0\(ul'\\
15c0: 24 32 0a 2e 2e 0a 2e 5c 22 09 23 20 51 57 20 2d $2.....\".# QW -
15d0: 20 61 70 70 6c 79 20 71 75 6f 74 61 74 69 6f 6e apply quotation
15e0: 20 6d 61 72 6b 73 20 74 6f 20 77 6f 72 64 0a 2e marks to word..
15f0: 64 65 20 51 57 0a 2e 69 65 20 27 5c 5c 2a 28 6c de QW..ie '\\*(l
1600: 71 27 22 27 20 60 60 5c 5c 24 31 27 27 5c 5c 24 q'"' ``\\$1''\\$
1610: 32 0a 2e 5c 22 22 20 66 69 78 20 65 6d 61 63 73 2..\"" fix emacs
1620: 20 68 69 67 68 6c 69 67 68 74 69 6e 67 0a 2e 65 highlighting..e
1630: 6c 20 5c 5c 2a 28 6c 71 5c 5c 24 31 5c 5c 2a 28 l \\*(lq\\$1\\*(
1640: 72 71 5c 5c 24 32 0a 2e 2e 0a 2e 5c 22 09 23 20 rq\\$2.....\".#
1650: 50 51 20 2d 20 61 70 70 6c 79 20 70 61 72 65 6e PQ - apply paren
1660: 73 20 61 6e 64 20 71 75 6f 74 61 74 69 6f 6e 20 s and quotation
1670: 6d 61 72 6b 73 20 74 6f 20 77 6f 72 64 0a 2e 64 marks to word..d
1680: 65 20 50 51 0a 2e 69 65 20 27 5c 5c 2a 28 6c 71 e PQ..ie '\\*(lq
1690: 27 22 27 20 28 60 60 5c 5c 24 31 27 27 5c 5c 24 '"' (``\\$1''\\$
16a0: 32 29 5c 5c 24 33 0a 2e 5c 22 22 20 66 69 78 20 2)\\$3..\"" fix
16b0: 65 6d 61 63 73 20 68 69 67 68 6c 69 67 68 74 69 emacs highlighti
16c0: 6e 67 0a 2e 65 6c 20 28 5c 5c 2a 28 6c 71 5c 5c ng..el (\\*(lq\\
16d0: 24 31 5c 5c 2a 28 72 71 5c 5c 24 32 29 5c 5c 24 $1\\*(rq\\$2)\\$
16e0: 33 0a 2e 2e 0a 2e 5c 22 09 23 20 51 52 20 2d 20 3.....\".# QR -
16f0: 71 75 6f 74 65 64 20 72 61 6e 67 65 0a 2e 64 65 quoted range..de
1700: 20 51 52 0a 2e 69 65 20 27 5c 5c 2a 28 6c 71 27 QR..ie '\\*(lq'
1710: 22 27 20 60 60 5c 5c 24 31 27 27 5c 5c 2d 60 60 "' ``\\$1''\\-``
1720: 5c 5c 24 32 27 27 5c 5c 24 33 0a 2e 5c 22 22 20 \\$2''\\$3..\""
1730: 66 69 78 20 65 6d 61 63 73 20 68 69 67 68 6c 69 fix emacs highli
1740: 67 68 74 69 6e 67 0a 2e 65 6c 20 5c 5c 2a 28 6c ghting..el \\*(l
1750: 71 5c 5c 24 31 5c 5c 2a 28 72 71 5c 5c 2d 5c 5c q\\$1\\*(rq\\-\\
1760: 2a 28 6c 71 5c 5c 24 32 5c 5c 2a 28 72 71 5c 5c *(lq\\$2\\*(rq\\
1770: 24 33 0a 2e 2e 0a 2e 5c 22 09 23 20 4d 54 20 2d $3.....\".# MT -
1780: 20 22 65 6d 70 74 79 22 20 73 74 72 69 6e 67 0a "empty" string.
1790: 2e 64 65 20 4d 54 0a 2e 51 57 20 22 22 0a 2e 2e .de MT..QW ""...
17a0: 0a 2e 42 53 0a 2e 53 48 20 4e 41 4d 45 0a 74 6c ..BS..SH NAME.tl
17b0: 73 20 5c 2d 20 62 69 6e 64 69 6e 67 20 74 6f 20 s \- binding to
17c0: 74 68 65 20 4f 70 65 6e 53 53 4c 20 6c 69 62 72 the OpenSSL libr
17d0: 61 72 79 20 66 6f 72 20 65 6e 63 72 79 70 74 65 ary for encrypte
17e0: 64 20 73 6f 63 6b 65 74 20 61 6e 64 20 49 2f 4f d socket and I/O
17f0: 20 63 68 61 6e 6e 65 6c 20 63 6f 6d 6d 75 6e 69 channel communi
1800: 63 61 74 69 6f 6e 73 0a 2e 53 48 20 53 59 4e 4f cations..SH SYNO
1810: 50 53 49 53 0a 70 61 63 6b 61 67 65 20 72 65 71 PSIS.package req
1820: 75 69 72 65 20 5c 66 42 54 63 6c 20 38 5c 26 2e uire \fBTcl 8\&.
1830: 35 2d 5c 66 52 0a 2e 73 70 0a 70 61 63 6b 61 67 5-\fR..sp.packag
1840: 65 20 72 65 71 75 69 72 65 20 5c 66 42 74 6c 73 e require \fBtls
1850: 20 32 5c 26 2e 30 62 31 5c 66 52 0a 2e 73 70 0a 2\&.0b1\fR..sp.
1860: 5c 66 42 74 6c 73 3a 3a 69 6e 69 74 5c 66 52 20 \fBtls::init\fR
1870: 3f 5c 66 49 2d 6f 70 74 69 6f 6e 5c 66 52 3f 20 ?\fI-option\fR?
1880: 3f 5c 66 49 76 61 6c 75 65 5c 66 52 3f 20 3f 5c ?\fIvalue\fR? ?\
1890: 66 49 2d 6f 70 74 69 6f 6e 20 76 61 6c 75 65 20 fI-option value
18a0: 5c 26 2e 5c 26 2e 5c 26 2e 5c 66 52 3f 0a 2e 73 \&.\&.\&.\fR?..s
18b0: 70 0a 5c 66 42 74 6c 73 3a 3a 73 6f 63 6b 65 74 p.\fBtls::socket
18c0: 5c 66 52 20 3f 5c 66 49 2d 6f 70 74 69 6f 6e 5c \fR ?\fI-option\
18d0: 66 52 3f 20 3f 5c 66 49 76 61 6c 75 65 5c 66 52 fR? ?\fIvalue\fR
18e0: 3f 20 3f 5c 66 49 2d 6f 70 74 69 6f 6e 20 76 61 ? ?\fI-option va
18f0: 6c 75 65 20 5c 26 2e 5c 26 2e 5c 26 2e 5c 66 52 lue \&.\&.\&.\fR
1900: 3f 20 5c 66 49 68 6f 73 74 5c 66 52 20 5c 66 49 ? \fIhost\fR \fI
1910: 70 6f 72 74 5c 66 52 0a 2e 73 70 0a 5c 66 42 74 port\fR..sp.\fBt
1920: 6c 73 3a 3a 73 6f 63 6b 65 74 5c 66 52 20 5c 66 ls::socket\fR \f
1930: 42 2d 73 65 72 76 65 72 5c 66 52 20 5c 66 49 63 B-server\fR \fIc
1940: 6f 6d 6d 61 6e 64 5c 66 52 20 3f 5c 66 49 2d 6f ommand\fR ?\fI-o
1950: 70 74 69 6f 6e 5c 66 52 3f 20 3f 5c 66 49 76 61 ption\fR? ?\fIva
1960: 6c 75 65 5c 66 52 3f 20 3f 5c 66 49 2d 6f 70 74 lue\fR? ?\fI-opt
1970: 69 6f 6e 20 76 61 6c 75 65 20 5c 26 2e 5c 26 2e ion value \&.\&.
1980: 5c 26 2e 5c 66 52 3f 20 5c 66 49 70 6f 72 74 5c \&.\fR? \fIport\
1990: 66 52 0a 2e 73 70 0a 5c 66 42 74 6c 73 3a 3a 69 fR..sp.\fBtls::i
19a0: 6d 70 6f 72 74 5c 66 52 20 5c 66 49 63 68 61 6e mport\fR \fIchan
19b0: 6e 65 6c 5c 66 52 20 3f 5c 66 49 2d 6f 70 74 69 nel\fR ?\fI-opti
19c0: 6f 6e 5c 66 52 3f 20 3f 5c 66 49 76 61 6c 75 65 on\fR? ?\fIvalue
19d0: 5c 66 52 3f 20 3f 5c 66 49 2d 6f 70 74 69 6f 6e \fR? ?\fI-option
19e0: 20 76 61 6c 75 65 20 5c 26 2e 5c 26 2e 5c 26 2e value \&.\&.\&.
19f0: 5c 66 52 3f 0a 2e 73 70 0a 5c 66 42 74 6c 73 3a \fR?..sp.\fBtls:
1a00: 3a 75 6e 69 6d 70 6f 72 74 5c 66 52 20 5c 66 49 :unimport\fR \fI
1a10: 63 68 61 6e 6e 65 6c 5c 66 52 0a 2e 73 70 0a 5c channel\fR..sp.\
1a20: 66 42 74 6c 73 3a 3a 68 61 6e 64 73 68 61 6b 65 fBtls::handshake
1a30: 5c 66 52 20 5c 66 49 63 68 61 6e 6e 65 6c 5c 66 \fR \fIchannel\f
1a40: 52 0a 2e 73 70 0a 5c 66 42 74 6c 73 3a 3a 73 74 R..sp.\fBtls::st
1a50: 61 74 75 73 5c 66 52 20 3f 5c 66 42 2d 6c 6f 63 atus\fR ?\fB-loc
1a60: 61 6c 5c 66 52 3f 20 5c 66 49 63 68 61 6e 6e 65 al\fR? \fIchanne
1a70: 6c 5c 66 52 0a 2e 73 70 0a 5c 66 42 74 6c 73 3a l\fR..sp.\fBtls:
1a80: 3a 63 6f 6e 6e 65 63 74 69 6f 6e 5c 66 52 20 5c :connection\fR \
1a90: 66 49 63 68 61 6e 6e 65 6c 5c 66 52 0a 2e 73 70 fIchannel\fR..sp
1aa0: 0a 5c 66 42 74 6c 73 3a 3a 63 69 70 68 65 72 73 .\fBtls::ciphers
1ab0: 5c 66 52 20 3f 5c 66 49 70 72 6f 74 6f 63 6f 6c \fR ?\fIprotocol
1ac0: 5c 66 52 3f 20 3f 5c 66 49 76 65 72 62 6f 73 65 \fR? ?\fIverbose
1ad0: 5c 66 52 3f 20 3f 5c 66 49 73 75 70 70 6f 72 74 \fR? ?\fIsupport
1ae0: 65 64 5c 66 52 3f 0a 2e 73 70 0a 5c 66 42 74 6c ed\fR?..sp.\fBtl
1af0: 73 3a 3a 70 72 6f 74 6f 63 6f 6c 73 5c 66 52 0a s::protocols\fR.
1b00: 2e 73 70 0a 5c 66 42 74 6c 73 3a 3a 76 65 72 73 .sp.\fBtls::vers
1b10: 69 6f 6e 5c 66 52 0a 2e 73 70 0a 2e 42 45 0a 2e ion\fR..sp..BE..
1b20: 53 48 20 44 45 53 43 52 49 50 54 49 4f 4e 0a 54 SH DESCRIPTION.T
1b30: 68 69 73 20 65 78 74 65 6e 73 69 6f 6e 20 70 72 his extension pr
1b40: 6f 76 69 64 65 73 20 54 43 4c 20 73 63 72 69 70 ovides TCL scrip
1b50: 74 20 61 63 63 65 73 73 20 74 6f 20 73 65 63 75 t access to secu
1b60: 72 65 20 73 6f 63 6b 65 74 20 63 6f 6d 6d 75 6e re socket commun
1b70: 69 63 61 74 69 6f 6e 73 0a 75 73 69 6e 67 20 74 ications.using t
1b80: 68 65 20 54 72 61 6e 73 70 6f 72 74 20 4c 61 79 he Transport Lay
1b90: 65 72 20 53 65 63 75 72 69 74 79 20 28 54 4c 53 er Security (TLS
1ba0: 29 20 70 72 6f 74 6f 63 6f 6c 5c 26 2e 20 49 74 ) protocol\&. It
1bb0: 20 70 72 6f 76 69 64 65 73 20 61 20 67 65 6e 65 provides a gene
1bc0: 72 69 63 0a 62 69 6e 64 69 6e 67 20 74 6f 20 5c ric.binding to \
1bd0: 66 49 4f 70 65 6e 53 53 4c 5c 66 52 20 5b 68 74 fIOpenSSL\fR [ht
1be0: 74 70 73 3a 2f 2f 77 77 77 5c 26 2e 6f 70 65 6e tps://www\&.open
1bf0: 73 73 6c 5c 26 2e 6f 72 67 2f 5d 2c 20 75 74 69 ssl\&.org/], uti
1c00: 6c 69 7a 69 6e 67 20 74 68 65 0a 5c 66 42 54 63 lizing the.\fBTc
1c10: 6c 5f 53 74 61 63 6b 43 68 61 6e 6e 65 6c 5c 66 l_StackChannel\f
1c20: 52 20 41 50 49 20 69 6e 20 54 43 4c 20 38 5c 26 R API in TCL 8\&
1c30: 2e 34 20 61 6e 64 20 68 69 67 68 65 72 5c 26 2e .4 and higher\&.
1c40: 0a 54 68 65 73 65 20 73 6f 63 6b 65 74 73 20 62 .These sockets b
1c50: 65 68 61 76 65 20 65 78 61 63 74 6c 79 20 74 68 ehave exactly th
1c60: 65 20 73 61 6d 65 20 61 73 20 63 68 61 6e 6e 65 e same as channe
1c70: 6c 73 20 63 72 65 61 74 65 64 20 75 73 69 6e 67 ls created using
1c80: 20 74 68 65 20 62 75 69 6c 74 2d 69 6e 0a 5c 66 the built-in.\f
1c90: 42 73 6f 63 6b 65 74 5c 66 52 20 63 6f 6d 6d 61 Bsocket\fR comma
1ca0: 6e 64 2c 20 61 6c 6f 6e 67 20 77 69 74 68 20 61 nd, along with a
1cb0: 64 64 69 74 69 6f 6e 61 6c 20 6f 70 74 69 6f 6e dditional option
1cc0: 73 20 66 6f 72 20 63 6f 6e 74 72 6f 6c 6c 69 6e s for controllin
1cd0: 67 0a 74 68 65 20 53 53 4c 2f 54 4c 53 20 73 65 g.the SSL/TLS se
1ce0: 73 73 69 6f 6e 5c 26 2e 0a 2e 53 48 20 43 4f 4d ssion\&...SH COM
1cf0: 4d 41 4e 44 53 0a 54 79 70 69 63 61 6c 6c 79 20 MANDS.Typically
1d00: 6f 6e 65 20 77 6f 75 6c 64 20 75 73 65 20 74 68 one would use th
1d10: 65 20 5c 66 42 74 6c 73 3a 3a 73 6f 63 6b 65 74 e \fBtls::socket
1d20: 5c 66 52 20 63 6f 6d 6d 61 6e 64 20 74 6f 20 63 \fR command to c
1d30: 72 65 61 74 65 20 61 20 6e 65 77 20 65 6e 63 72 reate a new encr
1d40: 79 70 74 65 64 0a 54 43 50 20 73 6f 63 6b 65 74 ypted.TCP socket
1d50: 5c 26 2e 20 49 74 20 69 73 20 63 6f 6d 70 61 74 \&. It is compat
1d60: 69 62 6c 65 20 77 69 74 68 20 74 68 65 20 6e 61 ible with the na
1d70: 74 69 76 65 20 54 43 4c 20 5c 66 42 3a 3a 73 6f tive TCL \fB::so
1d80: 63 6b 65 74 5c 66 52 20 63 6f 6d 6d 61 6e 64 5c cket\fR command\
1d90: 26 2e 0a 41 6c 74 65 72 6e 61 74 69 76 65 6c 79 &..Alternatively
1da0: 20 66 6f 72 20 61 6e 20 65 78 69 73 74 69 6e 67 for an existing
1db0: 20 54 43 50 20 73 6f 63 6b 65 74 2c 20 74 68 65 TCP socket, the
1dc0: 20 5c 66 42 74 6c 73 3a 3a 69 6d 70 6f 72 74 5c \fBtls::import\
1dd0: 66 52 20 63 6f 6d 6d 61 6e 64 20 63 61 6e 20 62 fR command can b
1de0: 65 0a 75 73 65 64 20 74 6f 20 73 74 61 72 74 20 e.used to start
1df0: 54 4c 53 20 6f 6e 20 74 68 65 20 63 6f 6e 6e 65 TLS on the conne
1e00: 63 74 69 6f 6e 5c 26 2e 0a 2e 54 50 0a 5c 66 42 ction\&...TP.\fB
1e10: 74 6c 73 3a 3a 69 6e 69 74 5c 66 52 20 3f 5c 66 tls::init\fR ?\f
1e20: 49 2d 6f 70 74 69 6f 6e 5c 66 52 3f 20 3f 5c 66 I-option\fR? ?\f
1e30: 49 76 61 6c 75 65 5c 66 52 3f 20 3f 5c 66 49 2d Ivalue\fR? ?\fI-
1e40: 6f 70 74 69 6f 6e 20 76 61 6c 75 65 20 5c 26 2e option value \&.
1e50: 5c 26 2e 5c 26 2e 5c 66 52 3f 0a 4f 70 74 69 6f \&.\&.\fR?.Optio
1e60: 6e 61 6c 20 66 75 6e 63 74 69 6f 6e 20 74 6f 20 nal function to
1e70: 73 65 74 20 74 68 65 20 64 65 66 61 75 6c 74 20 set the default
1e80: 6f 70 74 69 6f 6e 73 20 75 73 65 64 20 62 79 20 options used by
1e90: 5c 66 42 74 6c 73 3a 3a 73 6f 63 6b 65 74 5c 66 \fBtls::socket\f
1ea0: 52 5c 26 2e 20 49 66 20 79 6f 75 0a 63 61 6c 6c R\&. If you.call
1eb0: 20 5c 66 42 74 6c 73 3a 3a 69 6d 70 6f 72 74 5c \fBtls::import\
1ec0: 66 52 20 64 69 72 65 63 74 6c 79 2c 20 74 68 69 fR directly, thi
1ed0: 73 20 63 6f 6d 6d 61 6e 64 20 68 61 73 20 6e 6f s command has no
1ee0: 20 65 66 66 65 63 74 5c 26 2e 20 54 68 69 73 20 effect\&. This
1ef0: 63 6f 6d 6d 61 6e 64 0a 73 75 70 70 6f 72 74 73 command.supports
1f00: 20 61 6c 6c 20 6f 66 20 74 68 65 20 73 61 6d 65 all of the same
1f10: 20 6f 70 74 69 6f 6e 73 20 61 73 20 74 68 65 20 options as the
1f20: 5c 66 42 74 6c 73 3a 3a 73 6f 63 6b 65 74 5c 66 \fBtls::socket\f
1f30: 52 20 63 6f 6d 6d 61 6e 64 2c 20 74 68 6f 75 67 R command, thoug
1f40: 68 20 79 6f 75 0a 73 68 6f 75 6c 64 20 6c 69 6d h you.should lim
1f50: 69 74 20 79 6f 75 72 20 6f 70 74 69 6f 6e 73 20 it your options
1f60: 74 6f 20 6f 6e 6c 79 20 54 4c 53 20 72 65 6c 61 to only TLS rela
1f70: 74 65 64 20 6f 6e 65 73 5c 26 2e 0a 2e 54 50 0a ted ones\&...TP.
1f80: 5c 66 42 74 6c 73 3a 3a 73 6f 63 6b 65 74 5c 66 \fBtls::socket\f
1f90: 52 20 3f 5c 66 49 2d 6f 70 74 69 6f 6e 5c 66 52 R ?\fI-option\fR
1fa0: 3f 20 3f 5c 66 49 76 61 6c 75 65 5c 66 52 3f 20 ? ?\fIvalue\fR?
1fb0: 3f 5c 66 49 2d 6f 70 74 69 6f 6e 20 76 61 6c 75 ?\fI-option valu
1fc0: 65 20 5c 26 2e 5c 26 2e 5c 26 2e 5c 66 52 3f 20 e \&.\&.\&.\fR?
1fd0: 5c 66 49 68 6f 73 74 5c 66 52 20 5c 66 49 70 6f \fIhost\fR \fIpo
1fe0: 72 74 5c 66 52 0a 54 68 69 73 20 69 73 20 61 20 rt\fR.This is a
1ff0: 68 65 6c 70 65 72 20 66 75 6e 63 74 69 6f 6e 20 helper function
2000: 74 68 61 74 20 75 74 69 6c 69 7a 65 73 20 74 68 that utilizes th
2010: 65 20 75 6e 64 65 72 6c 79 69 6e 67 20 63 6f 6d e underlying com
2020: 6d 61 6e 64 73 20 5c 66 42 73 6f 63 6b 65 74 5c mands \fBsocket\
2030: 66 52 0a 61 6e 64 20 5c 66 42 74 6c 73 3a 3a 69 fR.and \fBtls::i
2040: 6d 70 6f 72 74 5c 66 52 20 74 6f 20 63 72 65 61 mport\fR to crea
2050: 74 65 20 74 68 65 20 63 6f 6e 6e 65 63 74 69 6f te the connectio
2060: 6e 5c 26 2e 20 49 74 20 62 65 68 61 76 65 73 20 n\&. It behaves
2070: 74 68 65 20 73 61 6d 65 20 61 73 20 74 68 65 0a the same as the.
2080: 6e 61 74 69 76 65 20 54 43 4c 20 5c 66 42 73 6f native TCL \fBso
2090: 63 6b 65 74 5c 66 52 20 63 6f 6d 6d 61 6e 64 2c cket\fR command,
20a0: 20 62 75 74 20 61 6c 73 6f 20 73 75 70 70 6f 72 but also suppor
20b0: 74 73 20 74 68 65 20 5c 66 42 74 6c 73 3a 69 6d ts the \fBtls:im
20c0: 70 6f 72 74 5c 66 52 0a 63 6f 6d 6d 61 6e 64 20 port\fR.command
20d0: 6f 70 74 69 6f 6e 73 20 77 69 74 68 20 6f 6e 65 options with one
20e0: 20 61 64 64 69 74 69 6f 6e 61 6c 20 6f 70 74 69 additional opti
20f0: 6f 6e 5c 26 2e 20 49 74 20 72 65 74 75 72 6e 73 on\&. It returns
2100: 20 74 68 65 20 63 68 61 6e 6e 65 6c 20 68 61 6e the channel han
2110: 64 6c 65 20 69 64 0a 66 6f 72 20 74 68 65 20 6e dle id.for the n
2120: 65 77 20 73 6f 63 6b 65 74 5c 26 2e 0a 2e 52 53 ew socket\&...RS
2130: 0a 2e 54 50 0a 5c 66 42 2d 61 75 74 6f 73 65 72 ..TP.\fB-autoser
2140: 76 65 72 6e 61 6d 65 5c 66 52 20 5c 66 49 62 6f vername\fR \fIbo
2150: 6f 6c 5c 66 52 0a 49 66 20 5c 66 42 74 72 75 65 ol\fR.If \fBtrue
2160: 5c 66 52 2c 20 61 75 74 6f 6d 61 74 69 63 61 6c \fR, automatical
2170: 6c 79 20 73 65 74 20 74 68 65 20 5c 66 42 2d 73 ly set the \fB-s
2180: 65 72 76 65 72 6e 61 6d 65 5c 66 52 20 61 72 67 ervername\fR arg
2190: 75 6d 65 6e 74 20 74 6f 20 74 68 65 0a 5c 66 49 ument to the.\fI
21a0: 68 6f 73 74 5c 66 52 20 61 72 67 75 6d 65 6e 74 host\fR argument
21b0: 5c 26 2e 20 50 72 69 6f 72 20 74 6f 20 54 63 6c \&. Prior to Tcl
21c0: 54 4c 53 20 32 5c 26 2e 30 2c 20 74 68 65 20 64 TLS 2\&.0, the d
21d0: 65 66 61 75 6c 74 20 69 73 20 5c 66 42 66 61 6c efault is \fBfal
21e0: 73 65 5c 66 52 5c 26 2e 0a 53 74 61 72 74 69 6e se\fR\&..Startin
21f0: 67 20 69 6e 20 54 63 6c 54 4c 53 20 32 5c 26 2e g in TclTLS 2\&.
2200: 30 2c 20 74 68 65 20 64 65 66 61 75 6c 74 20 69 0, the default i
2210: 73 20 5c 66 42 74 72 75 65 5c 66 52 20 75 6e 6c s \fBtrue\fR unl
2220: 65 73 73 20 5c 66 42 2d 73 65 72 76 65 72 6e 61 ess \fB-serverna
2230: 6d 65 5c 66 52 0a 69 73 20 61 6c 73 6f 20 73 70 me\fR.is also sp
2240: 65 63 69 66 69 65 64 5c 26 2e 0a 2e 52 45 0a 2e ecified\&...RE..
2250: 54 50 0a 5c 66 42 74 6c 73 3a 3a 73 6f 63 6b 65 TP.\fBtls::socke
2260: 74 5c 66 52 20 5c 66 42 2d 73 65 72 76 65 72 5c t\fR \fB-server\
2270: 66 52 20 5c 66 49 63 6f 6d 6d 61 6e 64 5c 66 52 fR \fIcommand\fR
2280: 20 3f 5c 66 49 2d 6f 70 74 69 6f 6e 5c 66 52 3f ?\fI-option\fR?
2290: 20 3f 5c 66 49 76 61 6c 75 65 5c 66 52 3f 20 3f ?\fIvalue\fR? ?
22a0: 5c 66 49 2d 6f 70 74 69 6f 6e 20 76 61 6c 75 65 \fI-option value
22b0: 20 5c 26 2e 5c 26 2e 5c 26 2e 5c 66 52 3f 20 5c \&.\&.\&.\fR? \
22c0: 66 49 70 6f 72 74 5c 66 52 0a 53 61 6d 65 20 61 fIport\fR.Same a
22d0: 73 20 70 72 65 76 69 6f 75 73 2c 20 62 75 74 20 s previous, but
22e0: 69 6e 73 74 65 61 64 20 63 72 65 61 74 65 73 20 instead creates
22f0: 61 20 73 65 72 76 65 72 20 73 6f 63 6b 65 74 20 a server socket
2300: 66 6f 72 20 63 6c 69 65 6e 74 73 20 74 6f 20 63 for clients to c
2310: 6f 6e 6e 65 63 74 20 74 6f 0a 6a 75 73 74 20 6c onnect to.just l
2320: 69 6b 65 20 74 68 65 20 54 63 6c 20 5c 66 42 73 ike the Tcl \fBs
2330: 6f 63 6b 65 74 20 2d 73 65 72 76 65 72 5c 66 52 ocket -server\fR
2340: 20 63 6f 6d 6d 61 6e 64 5c 26 2e 20 49 74 20 72 command\&. It r
2350: 65 74 75 72 6e 73 20 74 68 65 20 63 68 61 6e 6e eturns the chann
2360: 65 6c 0a 68 61 6e 64 6c 65 20 69 64 20 66 6f 72 el.handle id for
2370: 20 74 68 65 20 6e 65 77 20 73 6f 63 6b 65 74 5c the new socket\
2380: 26 2e 0a 2e 54 50 0a 5c 66 42 74 6c 73 3a 3a 69 &...TP.\fBtls::i
2390: 6d 70 6f 72 74 5c 66 52 20 5c 66 49 63 68 61 6e mport\fR \fIchan
23a0: 6e 65 6c 5c 66 52 20 3f 5c 66 49 2d 6f 70 74 69 nel\fR ?\fI-opti
23b0: 6f 6e 5c 66 52 3f 20 3f 5c 66 49 76 61 6c 75 65 on\fR? ?\fIvalue
23c0: 5c 66 52 3f 20 3f 5c 66 49 2d 6f 70 74 69 6f 6e \fR? ?\fI-option
23d0: 20 76 61 6c 75 65 20 5c 26 2e 5c 26 2e 5c 26 2e value \&.\&.\&.
23e0: 5c 66 52 3f 0a 53 74 61 72 74 20 54 4c 53 20 65 \fR?.Start TLS e
23f0: 6e 63 72 79 70 74 69 6f 6e 20 6f 6e 20 54 43 4c ncryption on TCL
2400: 20 63 68 61 6e 6e 65 6c 20 5c 66 49 63 68 61 6e channel \fIchan
2410: 6e 65 6c 5c 66 52 20 76 69 61 20 61 20 73 74 61 nel\fR via a sta
2420: 63 6b 65 64 20 63 68 61 6e 6e 65 6c 5c 26 2e 20 cked channel\&.
2430: 49 74 0a 6e 65 65 64 20 6e 6f 74 20 62 65 20 61 It.need not be a
2440: 20 73 6f 63 6b 65 74 2c 20 62 75 74 20 6d 75 73 socket, but mus
2450: 74 20 70 72 6f 76 69 64 65 20 62 69 2d 64 69 72 t provide bi-dir
2460: 65 63 74 69 6f 6e 61 6c 20 66 6c 6f 77 5c 26 2e ectional flow\&.
2470: 20 41 6c 73 6f 20 73 65 74 73 20 73 65 73 73 69 Also sets sessi
2480: 6f 6e 0a 70 61 72 61 6d 65 74 65 72 73 20 66 6f on.parameters fo
2490: 72 20 53 53 4c 20 68 61 6e 64 73 68 61 6b 65 5c r SSL handshake\
24a0: 26 2e 20 56 61 6c 69 64 20 6f 70 74 69 6f 6e 73 &. Valid options
24b0: 20 61 72 65 3a 0a 2e 52 53 0a 2e 54 50 0a 5c 66 are:..RS..TP.\f
24c0: 42 2d 61 6c 70 6e 5c 66 52 20 5c 66 49 6c 69 73 B-alpn\fR \fIlis
24d0: 74 5c 66 52 0a 4c 69 73 74 20 6f 66 20 70 72 6f t\fR.List of pro
24e0: 74 6f 63 6f 6c 73 20 74 6f 20 6f 66 66 65 72 20 tocols to offer
24f0: 64 75 72 69 6e 67 20 41 70 70 6c 69 63 61 74 69 during Applicati
2500: 6f 6e 2d 4c 61 79 65 72 20 50 72 6f 74 6f 63 6f on-Layer Protoco
2510: 6c 20 4e 65 67 6f 74 69 61 74 69 6f 6e 0a 28 41 l Negotiation.(A
2520: 4c 50 4e 29 5c 26 2e 20 46 6f 72 20 65 78 61 6d LPN)\&. For exam
2530: 70 6c 65 3a 20 5c 66 42 68 32 5c 66 52 20 61 6e ple: \fBh2\fR an
2540: 64 20 5c 66 42 68 74 74 70 2f 31 5c 26 2e 31 5c d \fBhttp/1\&.1\
2550: 66 52 2c 20 62 75 74 20 6e 6f 74 20 5c 66 42 68 fR, but not \fBh
2560: 33 5c 66 52 20 6f 72 0a 5c 66 42 71 75 69 63 5c 3\fR or.\fBquic\
2570: 66 52 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 63 61 fR\&...TP.\fB-ca
2580: 64 69 72 5c 66 52 20 5c 66 49 64 69 72 65 63 74 dir\fR \fIdirect
2590: 6f 72 79 5c 66 52 0a 53 70 65 63 69 66 69 65 73 ory\fR.Specifies
25a0: 20 74 68 65 20 64 69 72 65 63 74 6f 72 79 20 77 the directory w
25b0: 68 65 72 65 20 74 68 65 20 43 65 72 74 69 66 69 here the Certifi
25c0: 63 61 74 65 20 41 75 74 68 6f 72 69 74 79 20 28 cate Authority (
25d0: 43 41 29 20 63 65 72 74 69 66 69 63 61 74 65 73 CA) certificates
25e0: 20 61 72 65 0a 73 74 6f 72 65 64 5c 26 2e 20 54 are.stored\&. T
25f0: 68 65 20 64 65 66 61 75 6c 74 20 69 73 20 70 6c he default is pl
2600: 61 74 66 6f 72 6d 20 73 70 65 63 69 66 69 63 20 atform specific
2610: 61 6e 64 20 63 61 6e 20 62 65 20 73 65 74 20 61 and can be set a
2620: 74 20 63 6f 6d 70 69 6c 65 20 74 69 6d 65 5c 26 t compile time\&
2630: 2e 20 54 68 65 0a 64 65 66 61 75 6c 74 20 6c 6f . The.default lo
2640: 63 61 74 69 6f 6e 20 63 61 6e 20 62 65 20 6f 76 cation can be ov
2650: 65 72 72 69 64 64 65 6e 20 62 79 20 74 68 65 20 erridden by the
2660: 5c 66 42 53 53 4c 5f 43 45 52 54 5f 44 49 52 5c \fBSSL_CERT_DIR\
2670: 66 52 20 65 6e 76 69 72 6f 6e 6d 65 6e 74 0a 76 fR environment.v
2680: 61 72 69 61 62 6c 65 5c 26 2e 20 53 65 65 20 5c ariable\&. See \
2690: 66 42 43 65 72 74 69 66 69 63 61 74 65 20 56 61 fBCertificate Va
26a0: 6c 69 64 61 74 69 6f 6e 5c 66 52 20 66 6f 72 20 lidation\fR for
26b0: 6d 6f 72 65 20 64 65 74 61 69 6c 73 5c 26 2e 0a more details\&..
26c0: 2e 54 50 0a 5c 66 42 2d 63 61 66 69 6c 65 5c 66 .TP.\fB-cafile\f
26d0: 52 20 5c 66 49 66 69 6c 65 6e 61 6d 65 5c 66 52 R \fIfilename\fR
26e0: 0a 53 70 65 63 69 66 69 65 73 20 74 68 65 20 66 .Specifies the f
26f0: 69 6c 65 20 77 69 74 68 20 74 68 65 20 43 65 72 ile with the Cer
2700: 74 69 66 69 63 61 74 65 20 41 75 74 68 6f 72 69 tificate Authori
2710: 74 79 20 28 43 41 29 20 63 65 72 74 69 66 69 63 ty (CA) certific
2720: 61 74 65 73 20 74 6f 20 75 73 65 20 69 6e 0a 5c ates to use in.\
2730: 66 42 50 45 4d 5c 66 52 20 66 69 6c 65 20 66 6f fBPEM\fR file fo
2740: 72 6d 61 74 5c 26 2e 20 54 68 65 20 64 65 66 61 rmat\&. The defa
2750: 75 6c 74 20 69 73 20 22 5c 66 49 63 65 72 74 5c ult is "\fIcert\
2760: 26 2e 70 65 6d 5c 66 52 22 2c 20 69 6e 20 74 68 &.pem\fR", in th
2770: 65 20 4f 70 65 6e 53 53 4c 0a 64 69 72 65 63 74 e OpenSSL.direct
2780: 6f 72 79 5c 26 2e 20 54 68 65 20 64 65 66 61 75 ory\&. The defau
2790: 6c 74 20 66 69 6c 65 20 63 61 6e 20 62 65 20 6f lt file can be o
27a0: 76 65 72 72 69 64 64 65 6e 20 62 79 20 74 68 65 verridden by the
27b0: 20 5c 66 42 53 53 4c 5f 43 45 52 54 5f 46 49 4c \fBSSL_CERT_FIL
27c0: 45 5c 66 52 20 65 6e 76 69 72 6f 6e 6d 65 6e 74 E\fR environment
27d0: 0a 76 61 72 69 61 62 6c 65 5c 26 2e 20 53 65 65 .variable\&. See
27e0: 20 5c 66 42 43 65 72 74 69 66 69 63 61 74 65 20 \fBCertificate
27f0: 56 61 6c 69 64 61 74 69 6f 6e 5c 66 52 20 66 6f Validation\fR fo
2800: 72 20 6d 6f 72 65 20 64 65 74 61 69 6c 73 5c 26 r more details\&
2810: 2e 0a 2e 54 50 0a 5c 66 42 2d 63 61 73 74 6f 72 ...TP.\fB-castor
2820: 65 5c 66 52 20 5c 66 49 55 52 49 5c 66 52 0a 53 e\fR \fIURI\fR.S
2830: 70 65 63 69 66 69 65 73 20 74 68 65 20 55 6e 69 pecifies the Uni
2840: 66 6f 72 6d 20 52 65 73 6f 75 72 63 65 20 49 64 form Resource Id
2850: 65 6e 74 69 66 69 65 72 20 28 55 52 49 29 20 66 entifier (URI) f
2860: 6f 72 20 74 68 65 20 43 65 72 74 69 66 69 63 61 or the Certifica
2870: 74 65 20 41 75 74 68 6f 72 69 74 79 0a 28 43 41 te Authority.(CA
2880: 29 20 73 74 6f 72 65 2c 20 77 68 69 63 68 20 6d ) store, which m
2890: 61 79 20 62 65 20 61 20 73 69 6e 67 6c 65 20 63 ay be a single c
28a0: 6f 6e 74 61 69 6e 65 72 20 6f 72 20 61 20 63 61 ontainer or a ca
28b0: 74 61 6c 6f 67 20 6f 66 20 63 6f 6e 74 61 69 6e talog of contain
28c0: 65 72 73 5c 26 2e 0a 53 74 61 72 74 69 6e 67 20 ers\&..Starting
28d0: 77 69 74 68 20 4f 70 65 6e 53 53 4c 20 33 5c 26 with OpenSSL 3\&
28e0: 2e 32 20 6f 6e 20 4d 53 20 57 69 6e 64 6f 77 73 .2 on MS Windows
28f0: 2c 20 73 65 74 20 74 6f 20 22 5c 66 42 6f 72 67 , set to "\fBorg
2900: 5c 26 2e 6f 70 65 6e 73 73 6c 5c 26 2e 77 69 6e \&.openssl\&.win
2910: 73 74 6f 72 65 3a 2f 2f 5c 66 52 22 0a 74 6f 20 store://\fR".to
2920: 75 73 65 20 74 68 65 20 62 75 69 6c 74 2d 69 6e use the built-in
2930: 20 4d 53 20 57 69 6e 64 6f 77 73 20 43 65 72 74 MS Windows Cert
2940: 69 66 69 63 61 74 65 20 53 74 6f 72 65 5c 26 2e ificate Store\&.
2950: 20 53 65 65 0a 5c 66 42 43 65 72 74 69 66 69 63 See.\fBCertific
2960: 61 74 65 20 56 61 6c 69 64 61 74 69 6f 6e 5c 66 ate Validation\f
2970: 52 20 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 69 R for more detai
2980: 6c 73 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 63 65 ls\&...TP.\fB-ce
2990: 72 74 66 69 6c 65 5c 66 52 20 5c 66 49 66 69 6c rtfile\fR \fIfil
29a0: 65 6e 61 6d 65 5c 66 52 0a 53 70 65 63 69 66 69 ename\fR.Specifi
29b0: 65 73 20 74 68 65 20 6e 61 6d 65 20 6f 66 20 74 es the name of t
29c0: 68 65 20 66 69 6c 65 20 77 69 74 68 20 74 68 65 he file with the
29d0: 20 63 65 72 74 69 66 69 63 61 74 65 20 74 6f 20 certificate to
29e0: 75 73 65 20 69 6e 20 50 45 4d 20 66 6f 72 6d 61 use in PEM forma
29f0: 74 0a 61 73 20 74 68 65 20 6c 6f 63 61 6c 20 28 t.as the local (
2a00: 63 6c 69 65 6e 74 20 6f 72 20 73 65 72 76 65 72 client or server
2a10: 29 20 63 65 72 74 69 66 69 63 61 74 65 5c 26 2e ) certificate\&.
2a20: 20 49 74 20 61 6c 73 6f 20 63 6f 6e 74 61 69 6e It also contain
2a30: 73 20 74 68 65 20 70 75 62 6c 69 63 20 6b 65 79 s the public key
2a40: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 63 65 72 74 \&...TP.\fB-cert
2a50: 5c 66 52 20 5c 66 49 73 74 72 69 6e 67 5c 66 52 \fR \fIstring\fR
2a60: 0a 53 70 65 63 69 66 69 65 73 20 74 68 65 20 63 .Specifies the c
2a70: 65 72 74 69 66 69 63 61 74 65 20 74 6f 20 75 73 ertificate to us
2a80: 65 20 61 73 20 61 20 44 45 52 20 65 6e 63 6f 64 e as a DER encod
2a90: 65 64 20 73 74 72 69 6e 67 20 28 58 5c 26 2e 35 ed string (X\&.5
2aa0: 30 39 20 44 45 52 29 5c 26 2e 0a 2e 54 50 0a 5c 09 DER)\&...TP.\
2ab0: 66 42 2d 63 69 70 68 65 72 5c 66 52 20 5c 66 49 fB-cipher\fR \fI
2ac0: 73 74 72 69 6e 67 5c 66 52 0a 53 70 65 63 69 66 string\fR.Specif
2ad0: 69 65 73 20 74 68 65 20 6c 69 73 74 20 6f 66 20 ies the list of
2ae0: 63 69 70 68 65 72 73 20 74 6f 20 75 73 65 20 66 ciphers to use f
2af0: 6f 72 20 54 4c 53 20 31 5c 26 2e 32 20 61 6e 64 or TLS 1\&.2 and
2b00: 20 65 61 72 6c 69 65 72 20 63 6f 6e 6e 65 63 74 earlier connect
2b10: 69 6f 6e 73 5c 26 2e 0a 53 74 72 69 6e 67 20 69 ions\&..String i
2b20: 73 20 61 20 63 6f 6c 6f 6e 20 22 5c 66 42 3a 5c s a colon "\fB:\
2b30: 66 52 22 20 73 65 70 61 72 61 74 65 64 20 6c 69 fR" separated li
2b40: 73 74 20 6f 66 20 63 69 70 68 65 72 73 5c 26 2e st of ciphers\&.
2b50: 0a 43 69 70 68 65 72 73 20 63 61 6e 20 62 65 20 .Ciphers can be
2b60: 63 6f 6d 62 69 6e 65 64 20 75 73 69 6e 67 20 74 combined using t
2b70: 68 65 20 22 5c 66 42 2b 5c 66 52 22 20 63 68 61 he "\fB+\fR" cha
2b80: 72 61 63 74 65 72 5c 26 2e 0a 50 72 65 66 69 78 racter\&..Prefix
2b90: 65 73 20 63 61 6e 20 62 65 20 75 73 65 64 20 74 es can be used t
2ba0: 6f 20 70 65 72 6d 61 6e 65 6e 74 6c 79 20 72 65 o permanently re
2bb0: 6d 6f 76 65 20 22 5c 66 42 21 5c 66 52 22 2c 20 move "\fB!\fR",
2bc0: 64 65 6c 65 74 65 20 22 5c 66 42 2d 5c 66 52 22 delete "\fB-\fR"
2bd0: 2c 20 6f 72 0a 6d 6f 76 65 20 74 6f 20 74 68 65 , or.move to the
2be0: 20 65 6e 64 20 22 5c 66 42 2b 5c 66 52 22 20 61 end "\fB+\fR" a
2bf0: 20 73 70 65 63 69 66 69 65 64 20 63 69 70 68 65 specified ciphe
2c00: 72 5c 26 2e 0a 4b 65 79 77 6f 72 64 73 20 5c 66 r\&..Keywords \f
2c10: 42 40 53 54 52 45 4e 47 54 48 5c 66 52 20 28 73 B@STRENGTH\fR (s
2c20: 6f 72 74 20 62 79 20 61 6c 67 6f 72 69 74 68 6d ort by algorithm
2c30: 20 6b 65 79 20 6c 65 6e 67 74 68 29 2c 0a 5c 66 key length),.\f
2c40: 42 40 53 45 43 4c 45 56 45 4c 3d 5c 66 52 5c 66 B@SECLEVEL=\fR\f
2c50: 49 6e 5c 66 52 20 28 73 65 74 20 73 65 63 75 72 In\fR (set secur
2c60: 69 74 79 20 6c 65 76 65 6c 20 74 6f 20 6e 29 2c ity level to n),
2c70: 20 61 6e 64 0a 5c 66 42 44 45 46 41 55 4c 54 5c and.\fBDEFAULT\
2c80: 66 52 20 28 75 73 65 20 64 65 66 61 75 6c 74 20 fR (use default
2c90: 63 69 70 68 65 72 20 6c 69 73 74 2c 20 61 74 20 cipher list, at
2ca0: 73 74 61 72 74 20 6f 6e 6c 79 29 20 63 61 6e 20 start only) can
2cb0: 61 6c 73 6f 20 62 65 20 73 70 65 63 69 66 69 65 also be specifie
2cc0: 64 5c 26 2e 0a 53 65 65 20 74 68 65 20 5c 66 49 d\&..See the \fI
2cd0: 4f 70 65 6e 53 53 4c 5c 66 52 20 5b 68 74 74 70 OpenSSL\fR [http
2ce0: 73 3a 2f 2f 64 6f 63 73 5c 26 2e 6f 70 65 6e 73 s://docs\&.opens
2cf0: 73 6c 5c 26 2e 6f 72 67 2f 6d 61 73 74 65 72 2f sl\&.org/master/
2d00: 6d 61 6e 31 2f 6f 70 65 6e 73 73 6c 2d 63 69 70 man1/openssl-cip
2d10: 68 65 72 73 2f 23 6f 70 74 69 6f 6e 73 5d 0a 64 hers/#options].d
2d20: 6f 63 75 6d 65 6e 74 61 74 69 6f 6e 20 66 6f 72 ocumentation for
2d30: 20 74 68 65 20 66 75 6c 6c 20 6c 69 73 74 20 6f the full list o
2d40: 66 20 76 61 6c 69 64 20 76 61 6c 75 65 73 5c 26 f valid values\&
2d50: 2e 0a 2e 54 50 0a 5c 66 42 2d 63 69 70 68 65 72 ...TP.\fB-cipher
2d60: 73 75 69 74 65 73 5c 66 52 20 5c 66 49 73 74 72 suites\fR \fIstr
2d70: 69 6e 67 5c 66 52 0a 53 70 65 63 69 66 69 65 73 ing\fR.Specifies
2d80: 20 74 68 65 20 6c 69 73 74 20 6f 66 20 63 69 70 the list of cip
2d90: 68 65 72 20 73 75 69 74 65 73 20 74 6f 20 75 73 her suites to us
2da0: 65 20 66 6f 72 20 54 4c 53 20 31 5c 26 2e 33 20 e for TLS 1\&.3
2db0: 61 73 20 61 20 63 6f 6c 6f 6e 0a 22 5c 66 42 3a as a colon."\fB:
2dc0: 5c 66 52 22 20 73 65 70 61 72 61 74 65 64 20 6c \fR" separated l
2dd0: 69 73 74 20 6f 66 20 63 69 70 68 65 72 20 73 75 ist of cipher su
2de0: 69 74 65 20 6e 61 6d 65 73 5c 26 2e 20 53 65 65 ite names\&. See
2df0: 20 74 68 65 0a 5c 66 49 4f 70 65 6e 53 53 4c 5c the.\fIOpenSSL\
2e00: 66 52 20 5b 68 74 74 70 73 3a 2f 2f 64 6f 63 73 fR [https://docs
2e10: 5c 26 2e 6f 70 65 6e 73 73 6c 5c 26 2e 6f 72 67 \&.openssl\&.org
2e20: 2f 6d 61 73 74 65 72 2f 6d 61 6e 31 2f 6f 70 65 /master/man1/ope
2e30: 6e 73 73 6c 2d 63 69 70 68 65 72 73 2f 23 6f 70 nssl-ciphers/#op
2e40: 74 69 6f 6e 73 5d 0a 64 6f 63 75 6d 65 6e 74 61 tions].documenta
2e50: 74 69 6f 6e 20 66 6f 72 20 74 68 65 20 66 75 6c tion for the ful
2e60: 6c 20 6c 69 73 74 20 6f 66 20 76 61 6c 69 64 20 l list of valid
2e70: 76 61 6c 75 65 73 5c 26 2e 0a 2e 54 50 0a 5c 66 values\&...TP.\f
2e80: 42 2d 63 6f 6d 6d 61 6e 64 5c 66 52 20 5c 66 49 B-command\fR \fI
2e90: 63 61 6c 6c 62 61 63 6b 5c 66 52 0a 53 70 65 63 callback\fR.Spec
2ea0: 69 66 69 65 73 20 74 68 65 20 63 61 6c 6c 62 61 ifies the callba
2eb0: 63 6b 20 63 6f 6d 6d 61 6e 64 20 74 6f 20 62 65 ck command to be
2ec0: 20 69 6e 76 6f 6b 65 64 20 61 74 20 73 65 76 65 invoked at seve
2ed0: 72 61 6c 20 70 6f 69 6e 74 73 20 64 75 72 69 6e ral points durin
2ee0: 67 20 74 68 65 0a 68 61 6e 64 73 68 61 6b 65 20 g the.handshake
2ef0: 74 6f 20 70 61 73 73 20 65 72 72 6f 72 73 2c 20 to pass errors,
2f00: 74 72 61 63 69 6e 67 20 69 6e 66 6f 72 6d 61 74 tracing informat
2f10: 69 6f 6e 2c 20 61 6e 64 20 70 72 6f 74 6f 63 6f ion, and protoco
2f20: 6c 20 6d 65 73 73 61 67 65 73 5c 26 2e 0a 53 65 l messages\&..Se
2f30: 65 20 5c 66 42 43 61 6c 6c 62 61 63 6b 20 4f 70 e \fBCallback Op
2f40: 74 69 6f 6e 73 5c 66 52 20 66 6f 72 20 6d 6f 72 tions\fR for mor
2f50: 65 20 69 6e 66 6f 5c 26 2e 0a 2e 54 50 0a 5c 66 e info\&...TP.\f
2f60: 42 2d 64 68 70 61 72 61 6d 73 5c 66 52 20 5c 66 B-dhparams\fR \f
2f70: 49 66 69 6c 65 6e 61 6d 65 5c 66 52 0a 53 70 65 Ifilename\fR.Spe
2f80: 63 69 66 69 65 73 20 74 68 65 20 44 69 66 66 69 cifies the Diffi
2f90: 65 2d 48 65 6c 6c 6d 61 6e 20 28 44 48 29 20 70 e-Hellman (DH) p
2fa0: 61 72 61 6d 65 74 65 72 73 20 66 69 6c 65 5c 26 arameters file\&
2fb0: 2e 0a 2e 54 50 0a 5c 66 42 2d 6b 65 79 66 69 6c ...TP.\fB-keyfil
2fc0: 65 5c 66 52 20 5c 66 49 66 69 6c 65 6e 61 6d 65 e\fR \fIfilename
2fd0: 5c 66 52 0a 53 70 65 63 69 66 69 65 73 20 74 68 \fR.Specifies th
2fe0: 65 20 70 72 69 76 61 74 65 20 6b 65 79 20 66 69 e private key fi
2ff0: 6c 65 5c 26 2e 20 54 68 65 20 64 65 66 61 75 6c le\&. The defaul
3000: 74 20 69 73 20 74 6f 20 75 73 65 20 74 68 65 20 t is to use the
3010: 66 69 6c 65 0a 73 70 65 63 69 66 69 65 64 20 62 file.specified b
3020: 79 20 74 68 65 20 5c 66 49 2d 63 65 72 74 66 69 y the \fI-certfi
3030: 6c 65 5c 66 52 20 6f 70 74 69 6f 6e 5c 26 2e 0a le\fR option\&..
3040: 2e 54 50 0a 5c 66 42 2d 6b 65 79 5c 66 52 20 5c .TP.\fB-key\fR \
3050: 66 49 73 74 72 69 6e 67 5c 66 52 0a 53 70 65 63 fIstring\fR.Spec
3060: 69 66 69 65 73 20 74 68 65 20 70 72 69 76 61 74 ifies the privat
3070: 65 20 6b 65 79 20 74 6f 20 75 73 65 20 61 73 20 e key to use as
3080: 61 20 44 45 52 20 65 6e 63 6f 64 65 64 20 73 74 a DER encoded st
3090: 72 69 6e 67 20 28 50 4b 43 53 23 31 20 44 45 52 ring (PKCS#1 DER
30a0: 29 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 6d 6f 64 )\&...TP.\fB-mod
30b0: 65 6c 5c 66 52 20 5c 66 49 63 68 61 6e 6e 65 6c el\fR \fIchannel
30c0: 5c 66 52 0a 46 6f 72 63 65 20 74 68 69 73 20 63 \fR.Force this c
30d0: 68 61 6e 6e 65 6c 20 74 6f 20 73 68 61 72 65 20 hannel to share
30e0: 74 68 65 20 73 61 6d 65 20 5c 66 49 53 53 4c 5f the same \fISSL_
30f0: 43 54 58 5c 66 52 20 73 74 72 75 63 74 75 72 65 CTX\fR structure
3100: 20 61 73 20 74 68 65 0a 73 70 65 63 69 66 69 65 as the.specifie
3110: 64 20 5c 66 49 63 68 61 6e 6e 65 6c 5c 66 52 2c d \fIchannel\fR,
3120: 20 61 6e 64 20 74 68 65 72 65 66 6f 72 65 20 73 and therefore s
3130: 68 61 72 65 20 63 6f 6e 66 69 67 2c 20 63 61 6c hare config, cal
3140: 6c 62 61 63 6b 73 2c 20 65 74 63 5c 26 2e 0a 2e lbacks, etc\&...
3150: 54 50 0a 5c 66 42 2d 70 61 73 73 77 6f 72 64 5c TP.\fB-password\
3160: 66 52 20 5c 66 49 63 61 6c 6c 62 61 63 6b 5c 66 fR \fIcallback\f
3170: 52 0a 53 70 65 63 69 66 69 65 73 20 74 68 65 20 R.Specifies the
3180: 63 61 6c 6c 62 61 63 6b 20 63 6f 6d 6d 61 6e 64 callback command
3190: 20 74 6f 20 69 6e 76 6f 6b 65 20 77 68 65 6e 20 to invoke when
31a0: 4f 70 65 6e 53 53 4c 20 6e 65 65 64 73 20 74 6f OpenSSL needs to
31b0: 20 6f 62 74 61 69 6e 20 61 0a 70 61 73 73 77 6f obtain a.passwo
31c0: 72 64 5c 26 2e 20 54 68 69 73 20 69 73 20 74 79 rd\&. This is ty
31d0: 70 69 63 61 6c 6c 79 20 75 73 65 64 20 74 6f 20 pically used to
31e0: 75 6e 6c 6f 63 6b 20 74 68 65 20 70 72 69 76 61 unlock the priva
31f0: 74 65 20 6b 65 79 20 6f 66 20 61 20 63 65 72 74 te key of a cert
3200: 69 66 69 63 61 74 65 5c 26 2e 0a 54 68 65 20 63 ificate\&..The c
3210: 61 6c 6c 62 61 63 6b 20 73 68 6f 75 6c 64 20 72 allback should r
3220: 65 74 75 72 6e 20 61 20 70 61 73 73 77 6f 72 64 eturn a password
3230: 20 73 74 72 69 6e 67 5c 26 2e 20 53 65 65 20 5c string\&. See \
3240: 66 42 43 61 6c 6c 62 61 63 6b 20 4f 70 74 69 6f fBCallback Optio
3250: 6e 73 5c 66 52 0a 66 6f 72 20 6d 6f 72 65 20 69 ns\fR.for more i
3260: 6e 66 6f 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 70 nfo\&...TP.\fB-p
3270: 6f 73 74 5f 68 61 6e 64 73 68 61 6b 65 5c 66 52 ost_handshake\fR
3280: 20 5c 66 49 62 6f 6f 6c 5c 66 52 0a 41 6c 6c 6f \fIbool\fR.Allo
3290: 77 20 70 6f 73 74 2d 68 61 6e 64 73 68 61 6b 65 w post-handshake
32a0: 20 73 65 73 73 69 6f 6e 20 74 69 63 6b 65 74 20 session ticket
32b0: 75 70 64 61 74 65 73 5c 26 2e 0a 2e 54 50 0a 5c updates\&...TP.\
32c0: 66 42 2d 72 65 71 75 65 73 74 5c 66 52 20 5c 66 fB-request\fR \f
32d0: 49 62 6f 6f 6c 5c 66 52 0a 52 65 71 75 65 73 74 Ibool\fR.Request
32e0: 20 61 20 63 65 72 74 69 66 69 63 61 74 65 20 66 a certificate f
32f0: 72 6f 6d 20 74 68 65 20 70 65 65 72 20 64 75 72 rom the peer dur
3300: 69 6e 67 20 74 68 65 20 53 53 4c 20 68 61 6e 64 ing the SSL hand
3310: 73 68 61 6b 65 5c 26 2e 20 54 68 69 73 20 69 73 shake\&. This is
3320: 20 6e 65 65 64 65 64 0a 74 6f 20 64 6f 20 43 65 needed.to do Ce
3330: 72 74 69 66 69 63 61 74 65 20 56 61 6c 69 64 61 rtificate Valida
3340: 74 69 6f 6e 5c 26 2e 20 53 74 61 72 74 69 6e 67 tion\&. Starting
3350: 20 69 6e 20 54 63 6c 54 4c 53 20 31 5c 26 2e 38 in TclTLS 1\&.8
3360: 2c 20 74 68 65 20 64 65 66 61 75 6c 74 20 69 73 , the default is
3370: 0a 5c 66 42 74 72 75 65 5c 66 52 5c 26 2e 20 53 .\fBtrue\fR\&. S
3380: 74 61 72 74 69 6e 67 20 69 6e 20 54 63 6c 54 4c tarting in TclTL
3390: 53 20 32 5c 26 2e 30 2c 20 49 66 20 73 65 74 20 S 2\&.0, If set
33a0: 74 6f 20 5c 66 42 66 61 6c 73 65 5c 66 52 20 61 to \fBfalse\fR a
33b0: 6e 64 0a 5c 66 42 2d 72 65 71 75 69 72 65 5c 66 nd.\fB-require\f
33c0: 52 20 69 73 20 5c 66 42 74 72 75 65 5c 66 52 2c R is \fBtrue\fR,
33d0: 20 74 68 65 6e 20 74 68 69 73 20 77 69 6c 6c 20 then this will
33e0: 62 65 20 6f 76 65 72 72 69 64 64 65 6e 20 74 6f be overridden to
33f0: 20 5c 66 42 74 72 75 65 5c 66 52 5c 26 2e 0a 53 \fBtrue\fR\&..S
3400: 65 65 20 5c 66 42 43 65 72 74 69 66 69 63 61 74 ee \fBCertificat
3410: 65 20 56 61 6c 69 64 61 74 69 6f 6e 5c 66 52 20 e Validation\fR
3420: 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 69 6c 73 for more details
3430: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 72 65 71 75 \&...TP.\fB-requ
3440: 69 72 65 5c 66 52 20 5c 66 49 62 6f 6f 6c 5c 66 ire\fR \fIbool\f
3450: 52 0a 52 65 71 75 69 72 65 20 61 20 76 61 6c 69 R.Require a vali
3460: 64 20 63 65 72 74 69 66 69 63 61 74 65 20 66 72 d certificate fr
3470: 6f 6d 20 74 68 65 20 70 65 65 72 20 64 75 72 69 om the peer duri
3480: 6e 67 20 74 68 65 20 53 53 4c 20 68 61 6e 64 73 ng the SSL hands
3490: 68 61 6b 65 5c 26 2e 20 49 66 20 74 68 69 73 20 hake\&. If this
34a0: 69 73 0a 73 65 74 20 74 6f 20 74 72 75 65 2c 20 is.set to true,
34b0: 74 68 65 6e 20 5c 66 42 2d 72 65 71 75 65 73 74 then \fB-request
34c0: 5c 66 52 20 6d 75 73 74 20 61 6c 73 6f 20 62 65 \fR must also be
34d0: 20 73 65 74 20 74 6f 20 74 72 75 65 20 61 6e 64 set to true and
34e0: 20 61 20 65 69 74 68 65 72 0a 5c 66 42 2d 63 61 a either.\fB-ca
34f0: 64 69 72 5c 66 52 2c 20 5c 66 42 2d 63 61 66 69 dir\fR, \fB-cafi
3500: 6c 65 5c 66 52 2c 20 5c 66 42 2d 63 61 73 74 6f le\fR, \fB-casto
3510: 72 65 5c 66 52 2c 20 6f 72 20 61 20 70 6c 61 74 re\fR, or a plat
3520: 66 6f 72 6d 20 64 65 66 61 75 6c 74 0a 6d 75 73 form default.mus
3530: 74 20 62 65 20 70 72 6f 76 69 64 65 64 20 69 6e t be provided in
3540: 20 6f 72 64 65 72 20 74 6f 20 76 61 6c 69 64 61 order to valida
3550: 74 65 20 61 67 61 69 6e 73 74 5c 26 2e 20 54 68 te against\&. Th
3560: 65 20 64 65 66 61 75 6c 74 20 69 6e 20 54 63 6c e default in Tcl
3570: 54 4c 53 20 31 5c 26 2e 38 20 61 6e 64 0a 65 61 TLS 1\&.8 and.ea
3580: 72 6c 69 65 72 20 76 65 72 73 69 6f 6e 73 20 69 rlier versions i
3590: 73 20 5c 66 42 66 61 6c 73 65 5c 66 52 20 73 69 s \fBfalse\fR si
35a0: 6e 63 65 20 6e 6f 74 20 61 6c 6c 20 70 6c 61 74 nce not all plat
35b0: 66 6f 72 6d 73 20 68 61 76 65 20 63 65 72 74 69 forms have certi
35c0: 66 69 63 61 74 65 73 20 74 6f 0a 76 61 6c 69 64 ficates to.valid
35d0: 61 74 65 20 61 67 61 69 6e 73 74 20 69 6e 20 61 ate against in a
35e0: 20 66 6f 72 6d 20 63 6f 6d 70 61 74 69 62 6c 65 form compatible
35f0: 20 77 69 74 68 20 4f 70 65 6e 53 53 4c 5c 26 2e with OpenSSL\&.
3600: 20 53 74 61 72 74 69 6e 67 20 69 6e 20 54 63 6c Starting in Tcl
3610: 54 4c 53 20 32 5c 26 2e 30 2c 0a 74 68 65 20 64 TLS 2\&.0,.the d
3620: 65 66 61 75 6c 74 20 69 73 20 5c 66 42 74 72 75 efault is \fBtru
3630: 65 5c 66 52 5c 26 2e 0a 53 65 65 20 5c 66 42 43 e\fR\&..See \fBC
3640: 65 72 74 69 66 69 63 61 74 65 20 56 61 6c 69 64 ertificate Valid
3650: 61 74 69 6f 6e 5c 66 52 20 66 6f 72 20 6d 6f 72 ation\fR for mor
3660: 65 20 64 65 74 61 69 6c 73 5c 26 2e 0a 2e 54 50 e details\&...TP
3670: 0a 5c 66 42 2d 73 65 63 75 72 69 74 79 5f 6c 65 .\fB-security_le
3680: 76 65 6c 5c 66 52 20 5c 66 49 69 6e 74 65 67 65 vel\fR \fIintege
3690: 72 5c 66 52 0a 53 70 65 63 69 66 69 65 73 20 74 r\fR.Specifies t
36a0: 68 65 20 73 65 63 75 72 69 74 79 20 6c 65 76 65 he security leve
36b0: 6c 20 28 76 61 6c 75 65 20 66 72 6f 6d 20 30 20 l (value from 0
36c0: 74 6f 20 35 29 5c 26 2e 20 54 68 65 20 73 65 63 to 5)\&. The sec
36d0: 75 72 69 74 79 20 6c 65 76 65 6c 20 61 66 66 65 urity level affe
36e0: 63 74 73 0a 74 68 65 20 61 6c 6c 6f 77 65 64 20 cts.the allowed
36f0: 63 69 70 68 65 72 20 73 75 69 74 65 20 65 6e 63 cipher suite enc
3700: 72 79 70 74 69 6f 6e 20 61 6c 67 6f 72 69 74 68 ryption algorith
3710: 6d 73 2c 20 73 75 70 70 6f 72 74 65 64 20 45 43 ms, supported EC
3720: 43 20 63 75 72 76 65 73 2c 0a 73 75 70 70 6f 72 C curves,.suppor
3730: 74 65 64 20 73 69 67 6e 61 74 75 72 65 20 61 6c ted signature al
3740: 67 6f 72 69 74 68 6d 73 2c 20 44 48 20 70 61 72 gorithms, DH par
3750: 61 6d 65 74 65 72 20 73 69 7a 65 73 2c 20 63 65 ameter sizes, ce
3760: 72 74 69 66 69 63 61 74 65 20 6b 65 79 20 73 69 rtificate key si
3770: 7a 65 73 0a 61 6e 64 20 73 69 67 6e 61 74 75 72 zes.and signatur
3780: 65 20 61 6c 67 6f 72 69 74 68 6d 73 5c 26 2e 20 e algorithms\&.
3790: 54 68 65 20 64 65 66 61 75 6c 74 20 69 73 20 31 The default is 1
37a0: 20 70 72 69 6f 72 20 74 6f 20 4f 70 65 6e 53 53 prior to OpenSS
37b0: 4c 20 33 5c 26 2e 32 20 61 6e 64 20 32 0a 74 68 L 3\&.2 and 2.th
37c0: 65 72 65 61 66 74 65 72 5c 26 2e 20 4c 65 76 65 ereafter\&. Leve
37d0: 6c 20 33 20 61 6e 64 20 68 69 67 68 65 72 20 64 l 3 and higher d
37e0: 69 73 61 62 6c 65 20 73 75 70 70 6f 72 74 20 66 isable support f
37f0: 6f 72 20 73 65 73 73 69 6f 6e 20 74 69 63 6b 65 or session ticke
3800: 74 73 20 61 6e 64 0a 6f 6e 6c 79 20 61 63 63 65 ts and.only acce
3810: 70 74 20 63 69 70 68 65 72 20 73 75 69 74 65 73 pt cipher suites
3820: 20 74 68 61 74 20 70 72 6f 76 69 64 65 20 66 6f that provide fo
3830: 72 77 61 72 64 20 73 65 63 72 65 63 79 5c 26 2e rward secrecy\&.
3840: 0a 2e 54 50 0a 5c 66 42 2d 73 65 72 76 65 72 5c ..TP.\fB-server\
3850: 66 52 20 5c 66 49 62 6f 6f 6c 5c 66 52 0a 53 70 fR \fIbool\fR.Sp
3860: 65 63 69 66 69 65 73 20 77 68 65 74 68 65 72 20 ecifies whether
3870: 74 6f 20 61 63 74 20 61 73 20 61 20 73 65 72 76 to act as a serv
3880: 65 72 20 61 6e 64 20 72 65 73 70 6f 6e 64 20 77 er and respond w
3890: 69 74 68 20 61 20 73 65 72 76 65 72 20 68 61 6e ith a server han
38a0: 64 73 68 61 6b 65 20 77 68 65 6e 20 61 0a 63 6c dshake when a.cl
38b0: 69 65 6e 74 20 63 6f 6e 6e 65 63 74 73 20 61 6e ient connects an
38c0: 64 20 70 72 6f 76 69 64 65 73 20 61 20 63 6c 69 d provides a cli
38d0: 65 6e 74 20 68 61 6e 64 73 68 61 6b 65 5c 26 2e ent handshake\&.
38e0: 20 54 68 65 20 64 65 66 61 75 6c 74 20 69 73 20 The default is
38f0: 5c 66 42 66 61 6c 73 65 5c 66 52 5c 26 2e 0a 2e \fBfalse\fR\&...
3900: 54 50 0a 5c 66 42 2d 73 65 72 76 65 72 6e 61 6d TP.\fB-servernam
3910: 65 5c 66 52 20 5c 66 49 68 6f 73 74 6e 61 6d 65 e\fR \fIhostname
3920: 5c 66 52 0a 53 70 65 63 69 66 79 20 74 68 65 20 \fR.Specify the
3930: 70 65 65 72 27 73 20 68 6f 73 74 6e 61 6d 65 5c peer's hostname\
3940: 26 2e 20 54 68 69 73 20 69 73 20 75 73 65 64 20 &. This is used
3950: 74 6f 20 73 65 74 20 74 68 65 20 54 4c 53 20 53 to set the TLS S
3960: 65 72 76 65 72 20 4e 61 6d 65 20 49 6e 64 69 63 erver Name Indic
3970: 61 74 69 6f 6e 0a 28 53 4e 49 29 20 65 78 74 65 ation.(SNI) exte
3980: 6e 73 69 6f 6e 5c 26 2e 20 53 65 74 20 74 68 69 nsion\&. Set thi
3990: 73 20 74 6f 20 74 68 65 20 65 78 70 65 63 74 65 s to the expecte
39a0: 64 20 73 65 72 76 65 72 6e 61 6d 65 20 69 6e 20 d servername in
39b0: 74 68 65 20 73 65 72 76 65 72 27 73 20 63 65 72 the server's cer
39c0: 74 69 66 69 63 61 74 65 0a 6f 72 20 6f 6e 65 20 tificate.or one
39d0: 6f 66 20 74 68 65 20 53 75 62 6a 65 63 74 20 41 of the Subject A
39e0: 6c 74 65 72 6e 61 74 65 20 4e 61 6d 65 73 20 28 lternate Names (
39f0: 53 41 4e 29 5c 26 2e 20 53 74 61 72 74 69 6e 67 SAN)\&. Starting
3a00: 20 69 6e 20 54 63 6c 54 4c 53 20 32 5c 26 2e 30 in TclTLS 2\&.0
3a10: 2c 20 74 68 69 73 20 77 69 6c 6c 0a 64 65 66 61 , this will.defa
3a20: 75 6c 74 20 74 6f 20 74 68 65 20 68 6f 73 74 20 ult to the host
3a30: 66 6f 72 20 74 68 65 20 5c 66 42 74 6c 73 3a 3a for the \fBtls::
3a40: 73 6f 63 6b 65 74 5c 66 52 20 63 6f 6d 6d 61 6e socket\fR comman
3a50: 64 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 73 65 73 d\&...TP.\fB-ses
3a60: 73 69 6f 6e 5f 69 64 5c 66 52 20 5c 66 49 62 69 sion_id\fR \fIbi
3a70: 6e 61 72 79 5f 73 74 72 69 6e 67 5c 66 52 0a 53 nary_string\fR.S
3a80: 70 65 63 69 66 69 65 73 20 74 68 65 20 73 65 73 pecifies the ses
3a90: 73 69 6f 6e 20 69 64 20 74 6f 20 72 65 73 75 6d sion id to resum
3aa0: 65 20 61 20 73 65 73 73 69 6f 6e 5c 26 2e 20 4e e a session\&. N
3ab0: 6f 74 20 73 75 70 70 6f 72 74 65 64 20 79 65 74 ot supported yet
3ac0: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 73 73 6c 32 \&...TP.\fB-ssl2
3ad0: 5c 66 52 20 5c 66 49 62 6f 6f 6c 5c 66 52 0a 45 \fR \fIbool\fR.E
3ae0: 6e 61 62 6c 65 20 75 73 65 20 6f 66 20 53 53 4c nable use of SSL
3af0: 20 76 32 5c 26 2e 54 68 65 20 64 65 66 61 75 6c v2\&.The defaul
3b00: 74 20 69 73 20 5c 66 42 66 61 6c 73 65 5c 66 52 t is \fBfalse\fR
3b10: 5c 26 2e 0a 4f 70 65 6e 53 53 4c 20 31 5c 26 2e \&..OpenSSL 1\&.
3b20: 31 2b 20 6e 6f 20 6c 6f 6e 67 65 72 20 73 75 70 1+ no longer sup
3b30: 70 6f 72 74 73 20 53 53 4c 20 76 32 2c 20 73 6f ports SSL v2, so
3b40: 20 74 68 69 73 20 6d 61 79 20 6e 6f 74 20 68 61 this may not ha
3b50: 76 65 20 61 6e 79 20 65 66 66 65 63 74 5c 26 2e ve any effect\&.
3b60: 0a 53 65 65 20 74 68 65 20 5c 66 42 74 6c 73 3a .See the \fBtls:
3b70: 3a 70 72 6f 74 6f 63 6f 6c 73 5c 66 52 20 63 6f :protocols\fR co
3b80: 6d 6d 61 6e 64 20 66 6f 72 20 73 75 70 70 6f 72 mmand for suppor
3b90: 74 65 64 20 70 72 6f 74 6f 63 6f 6c 73 5c 26 2e ted protocols\&.
3ba0: 0a 2e 54 50 0a 5c 66 42 2d 73 73 6c 33 5c 66 52 ..TP.\fB-ssl3\fR
3bb0: 20 5c 66 49 62 6f 6f 6c 5c 66 52 0a 45 6e 61 62 \fIbool\fR.Enab
3bc0: 6c 65 20 75 73 65 20 6f 66 20 53 53 4c 20 76 33 le use of SSL v3
3bd0: 5c 26 2e 20 54 68 65 20 64 65 66 61 75 6c 74 20 \&. The default
3be0: 69 73 20 5c 66 42 66 61 6c 73 65 5c 66 52 5c 26 is \fBfalse\fR\&
3bf0: 2e 20 53 74 61 72 74 69 6e 67 20 69 6e 20 54 63 . Starting in Tc
3c00: 6c 54 4c 53 20 31 5c 26 2e 38 2c 0a 75 73 65 20 lTLS 1\&.8,.use
3c10: 6f 66 20 53 53 4c 20 76 33 20 69 66 20 6f 6e 6c of SSL v3 if onl
3c20: 79 20 61 76 61 69 6c 61 62 6c 65 20 76 69 61 20 y available via
3c30: 61 20 63 6f 6d 70 69 6c 65 20 74 69 6d 65 20 6f a compile time o
3c40: 70 74 69 6f 6e 5c 26 2e 0a 53 65 65 20 74 68 65 ption\&..See the
3c50: 20 5c 66 42 74 6c 73 3a 3a 70 72 6f 74 6f 63 6f \fBtls::protoco
3c60: 6c 73 5c 66 52 20 63 6f 6d 6d 61 6e 64 20 66 6f ls\fR command fo
3c70: 72 20 73 75 70 70 6f 72 74 65 64 20 70 72 6f 74 r supported prot
3c80: 6f 63 6f 6c 73 5c 26 2e 0a 2e 54 50 0a 5c 66 42 ocols\&...TP.\fB
3c90: 2d 74 6c 73 31 5c 66 52 20 5c 66 49 62 6f 6f 6c -tls1\fR \fIbool
3ca0: 5c 66 52 0a 45 6e 61 62 6c 65 20 75 73 65 20 6f \fR.Enable use o
3cb0: 66 20 54 4c 53 20 76 31 5c 26 2e 20 53 74 61 72 f TLS v1\&. Star
3cc0: 74 69 6e 67 20 69 6e 20 54 63 6c 54 4c 53 20 32 ting in TclTLS 2
3cd0: 5c 26 2e 30 2c 20 74 68 65 20 64 65 66 61 75 6c \&.0, the defaul
3ce0: 74 20 69 73 20 5c 66 42 66 61 6c 73 65 5c 66 52 t is \fBfalse\fR
3cf0: 5c 26 2e 0a 4e 6f 74 65 3a 20 54 4c 53 20 31 5c \&..Note: TLS 1\
3d00: 26 2e 30 20 6e 65 65 64 73 20 53 48 41 31 20 74 &.0 needs SHA1 t
3d10: 6f 20 6f 70 65 72 61 74 65 2c 20 77 68 69 63 68 o operate, which
3d20: 20 69 73 20 6f 6e 6c 79 20 61 76 61 69 6c 61 62 is only availab
3d30: 6c 65 20 69 6e 20 73 65 63 75 72 69 74 79 20 6c le in security l
3d40: 65 76 65 6c 0a 30 20 66 6f 72 20 4f 70 65 6e 20 evel.0 for Open
3d50: 53 53 4c 20 33 5c 26 2e 30 2b 5c 26 2e 20 53 65 SSL 3\&.0+\&. Se
3d60: 65 20 74 68 65 20 5c 66 49 2d 73 65 63 75 72 69 e the \fI-securi
3d70: 74 79 5f 6c 65 76 65 6c 5c 66 52 20 6f 70 74 69 ty_level\fR opti
3d80: 6f 6e 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 74 6c on\&...TP.\fB-tl
3d90: 73 31 5c 26 2e 31 5c 66 52 20 5c 66 49 62 6f 6f s1\&.1\fR \fIboo
3da0: 6c 5c 66 52 0a 45 6e 61 62 6c 65 20 75 73 65 20 l\fR.Enable use
3db0: 6f 66 20 54 4c 53 20 76 31 5c 26 2e 31 5c 26 2e of TLS v1\&.1\&.
3dc0: 20 53 74 61 72 74 69 6e 67 20 69 6e 20 54 63 6c Starting in Tcl
3dd0: 54 4c 53 20 32 5c 26 2e 30 2c 20 74 68 65 20 64 TLS 2\&.0, the d
3de0: 65 66 61 75 6c 74 20 69 73 20 5c 66 42 66 61 6c efault is \fBfal
3df0: 73 65 5c 66 52 5c 26 2e 0a 4e 6f 74 65 3a 20 54 se\fR\&..Note: T
3e00: 4c 53 20 31 5c 26 2e 31 20 6e 65 65 64 73 20 53 LS 1\&.1 needs S
3e10: 48 41 31 20 74 6f 20 6f 70 65 72 61 74 65 2c 20 HA1 to operate,
3e20: 77 68 69 63 68 20 69 73 20 6f 6e 6c 79 20 61 76 which is only av
3e30: 61 69 6c 61 62 6c 65 20 69 6e 20 73 65 63 75 72 ailable in secur
3e40: 69 74 79 20 6c 65 76 65 6c 0a 30 20 66 6f 72 20 ity level.0 for
3e50: 4f 70 65 6e 20 53 53 4c 20 33 5c 26 2e 30 2b 5c Open SSL 3\&.0+\
3e60: 26 2e 20 53 65 65 20 74 68 65 20 5c 66 49 2d 73 &. See the \fI-s
3e70: 65 63 75 72 69 74 79 5f 6c 65 76 65 6c 5c 66 52 ecurity_level\fR
3e80: 20 6f 70 74 69 6f 6e 5c 26 2e 0a 2e 54 50 0a 5c option\&...TP.\
3e90: 66 42 2d 74 6c 73 31 5c 26 2e 32 5c 66 52 20 5c fB-tls1\&.2\fR \
3ea0: 66 49 62 6f 6f 6c 5c 66 52 0a 45 6e 61 62 6c 65 fIbool\fR.Enable
3eb0: 20 75 73 65 20 6f 66 20 54 4c 53 20 76 31 5c 26 use of TLS v1\&
3ec0: 2e 32 5c 26 2e 20 54 68 65 20 64 65 66 61 75 6c .2\&. The defaul
3ed0: 74 20 69 73 20 5c 66 42 74 72 75 65 5c 66 52 5c t is \fBtrue\fR\
3ee0: 26 2e 0a 2e 54 50 0a 5c 66 42 2d 74 6c 73 31 5c &...TP.\fB-tls1\
3ef0: 26 2e 33 5c 66 52 20 5c 66 49 62 6f 6f 6c 5c 66 &.3\fR \fIbool\f
3f00: 52 0a 45 6e 61 62 6c 65 20 75 73 65 20 6f 66 20 R.Enable use of
3f10: 54 4c 53 20 76 31 5c 26 2e 33 5c 26 2e 20 54 68 TLS v1\&.3\&. Th
3f20: 65 20 64 65 66 61 75 6c 74 20 69 73 20 5c 66 42 e default is \fB
3f30: 74 72 75 65 5c 66 52 5c 26 2e 20 54 68 69 73 20 true\fR\&. This
3f40: 69 73 20 6f 6e 6c 79 20 61 76 61 69 6c 61 62 6c is only availabl
3f50: 65 0a 73 74 61 72 74 69 6e 67 20 77 69 74 68 20 e.starting with
3f60: 4f 70 65 6e 53 53 4c 20 31 5c 26 2e 31 5c 26 2e OpenSSL 1\&.1\&.
3f70: 31 20 61 6e 64 20 54 63 6c 54 4c 53 20 31 5c 26 1 and TclTLS 1\&
3f80: 2e 37 5c 26 2e 0a 2e 54 50 0a 5c 66 42 2d 76 61 .7\&...TP.\fB-va
3f90: 6c 69 64 61 74 65 63 6f 6d 6d 61 6e 64 5c 66 52 lidatecommand\fR
3fa0: 20 5c 66 49 63 61 6c 6c 62 61 63 6b 5c 66 52 0a \fIcallback\fR.
3fb0: 53 70 65 63 69 66 69 65 73 20 74 68 65 20 63 61 Specifies the ca
3fc0: 6c 6c 62 61 63 6b 20 63 6f 6d 6d 61 6e 64 20 74 llback command t
3fd0: 6f 20 69 6e 76 6f 6b 65 20 74 6f 20 76 61 6c 69 o invoke to vali
3fe0: 64 61 74 65 20 74 68 65 20 70 65 65 72 20 63 65 date the peer ce
3ff0: 72 74 69 66 69 63 61 74 65 73 0a 61 6e 64 20 6f rtificates.and o
4000: 74 68 65 72 20 63 6f 6e 66 69 67 20 69 6e 66 6f ther config info
4010: 20 64 75 72 69 6e 67 20 74 68 65 20 70 72 6f 74 during the prot
4020: 6f 63 6f 6c 20 6e 65 67 6f 74 69 61 74 69 6f 6e ocol negotiation
4030: 20 70 68 61 73 65 5c 26 2e 20 54 68 69 73 20 63 phase\&. This c
4040: 61 6e 20 62 65 20 75 73 65 64 0a 62 79 20 54 43 an be used.by TC
4050: 4c 20 73 63 72 69 70 74 73 20 74 6f 20 70 65 72 L scripts to per
4060: 66 6f 72 6d 20 74 68 65 69 72 20 6f 77 6e 20 43 form their own C
4070: 65 72 74 69 66 69 63 61 74 65 20 56 61 6c 69 64 ertificate Valid
4080: 61 74 69 6f 6e 20 74 6f 20 73 75 70 70 6c 65 6d ation to supplem
4090: 65 6e 74 20 74 68 65 0a 64 65 66 61 75 6c 74 20 ent the.default
40a0: 76 61 6c 69 64 61 74 69 6f 6e 20 70 72 6f 76 69 validation provi
40b0: 64 65 64 20 62 79 20 4f 70 65 6e 53 53 4c 5c 26 ded by OpenSSL\&
40c0: 2e 20 54 68 65 20 73 63 72 69 70 74 20 6d 75 73 . The script mus
40d0: 74 20 72 65 74 75 72 6e 20 61 20 62 6f 6f 6c 65 t return a boole
40e0: 61 6e 20 74 72 75 65 0a 74 6f 20 63 6f 6e 74 69 an true.to conti
40f0: 6e 75 65 20 74 68 65 20 6e 65 67 6f 74 69 61 74 nue the negotiat
4100: 69 6f 6e 5c 26 2e 20 53 65 65 20 5c 66 42 43 61 ion\&. See \fBCa
4110: 6c 6c 62 61 63 6b 20 4f 70 74 69 6f 6e 73 5c 66 llback Options\f
4120: 52 20 66 6f 72 20 6d 6f 72 65 20 69 6e 66 6f 5c R for more info\
4130: 26 2e 0a 2e 52 45 0a 2e 54 50 0a 5c 66 42 74 6c &...RE..TP.\fBtl
4140: 73 3a 3a 75 6e 69 6d 70 6f 72 74 5c 66 52 20 5c s::unimport\fR \
4150: 66 49 63 68 61 6e 6e 65 6c 5c 66 52 0a 43 6f 6d fIchannel\fR.Com
4160: 70 6c 69 6d 65 6e 74 20 74 6f 20 5c 66 42 74 6c pliment to \fBtl
4170: 73 3a 3a 69 6d 70 6f 72 74 5c 66 52 5c 26 2e 20 s::import\fR\&.
4180: 55 73 65 64 20 74 6f 20 72 65 6d 6f 76 65 20 74 Used to remove t
4190: 68 65 20 74 6f 70 20 6c 65 76 65 6c 20 73 74 61 he top level sta
41a0: 63 6b 65 64 20 63 68 61 6e 6e 65 6c 0a 66 72 6f cked channel.fro
41b0: 6d 20 5c 66 49 63 68 61 6e 6e 65 6c 5c 66 52 5c m \fIchannel\fR\
41c0: 26 2e 20 54 68 69 73 20 75 6e 73 74 61 63 6b 73 &. This unstacks
41d0: 20 74 68 65 20 65 6e 63 72 79 70 74 69 6f 6e 20 the encryption
41e0: 6f 66 20 61 20 72 65 67 75 6c 61 72 20 54 43 4c of a regular TCL
41f0: 20 63 68 61 6e 6e 65 6c 5c 26 2e 20 41 6e 0a 65 channel\&. An.e
4200: 72 72 6f 72 20 69 73 20 74 68 72 6f 77 6e 20 69 rror is thrown i
4210: 66 20 54 4c 53 20 69 73 20 6e 6f 74 20 74 68 65 f TLS is not the
4220: 20 74 6f 70 20 73 74 61 63 6b 65 64 20 63 68 61 top stacked cha
4230: 6e 6e 65 6c 20 74 79 70 65 5c 26 2e 0a 2e 54 50 nnel type\&...TP
4240: 0a 5c 66 42 74 6c 73 3a 3a 68 61 6e 64 73 68 61 .\fBtls::handsha
4250: 6b 65 5c 66 52 20 5c 66 49 63 68 61 6e 6e 65 6c ke\fR \fIchannel
4260: 5c 66 52 0a 46 6f 72 63 65 73 20 74 68 65 20 54 \fR.Forces the T
4270: 4c 53 20 6e 65 67 6f 74 69 61 74 69 6f 6e 20 68 LS negotiation h
4280: 61 6e 64 73 68 61 6b 65 20 74 6f 20 74 61 6b 65 andshake to take
4290: 20 70 6c 61 63 65 20 69 6d 6d 65 64 69 61 74 65 place immediate
42a0: 6c 79 2c 20 61 6e 64 20 72 65 74 75 72 6e 73 20 ly, and returns
42b0: 30 0a 69 66 20 68 61 6e 64 73 68 61 6b 65 20 69 0.if handshake i
42c0: 73 20 73 74 69 6c 6c 20 69 6e 20 70 72 6f 67 72 s still in progr
42d0: 65 73 73 20 28 6e 6f 6e 2d 62 6c 6f 63 6b 69 6e ess (non-blockin
42e0: 67 29 2c 20 6f 72 20 31 20 69 66 20 74 68 65 20 g), or 1 if the
42f0: 68 61 6e 64 73 68 61 6b 65 20 77 61 73 0a 73 75 handshake was.su
4300: 63 63 65 73 73 66 75 6c 5c 26 2e 20 49 66 20 74 ccessful\&. If t
4310: 68 65 20 68 61 6e 64 73 68 61 6b 65 20 66 61 69 he handshake fai
4320: 6c 65 64 2c 20 61 6e 20 65 72 72 6f 72 20 77 69 led, an error wi
4330: 6c 6c 20 62 65 20 72 65 74 75 72 6e 65 64 5c 26 ll be returned\&
4340: 2e 0a 2e 54 50 0a 5c 66 42 74 6c 73 3a 3a 73 74 ...TP.\fBtls::st
4350: 61 74 75 73 5c 66 52 20 3f 5c 66 42 2d 6c 6f 63 atus\fR ?\fB-loc
4360: 61 6c 5c 66 52 3f 20 5c 66 49 63 68 61 6e 6e 65 al\fR? \fIchanne
4370: 6c 5c 66 52 0a 52 65 74 75 72 6e 73 20 74 68 65 l\fR.Returns the
4380: 20 63 75 72 72 65 6e 74 20 73 74 61 74 75 73 20 current status
4390: 6f 66 20 61 6e 20 53 53 4c 20 63 68 61 6e 6e 65 of an SSL channe
43a0: 6c 5c 26 2e 20 54 68 65 20 72 65 73 75 6c 74 20 l\&. The result
43b0: 69 73 20 61 20 6c 69 73 74 20 6f 66 20 6b 65 79 is a list of key
43c0: 2d 76 61 6c 75 65 0a 70 61 69 72 73 20 64 65 73 -value.pairs des
43d0: 63 72 69 62 69 6e 67 20 74 68 65 20 53 53 4c 2c cribing the SSL,
43e0: 20 63 65 72 74 69 66 69 63 61 74 65 2c 20 61 6e certificate, an
43f0: 64 20 63 65 72 74 69 66 69 63 61 74 65 20 76 65 d certificate ve
4400: 72 69 66 69 63 61 74 69 6f 6e 20 73 74 61 74 75 rification statu
4410: 73 5c 26 2e 20 49 66 0a 74 68 65 20 53 53 4c 20 s\&. If.the SSL
4420: 68 61 6e 64 73 68 61 6b 65 20 68 61 73 20 6e 6f handshake has no
4430: 74 20 79 65 74 20 63 6f 6d 70 6c 65 74 65 64 2c t yet completed,
4440: 20 61 6e 20 65 6d 70 74 79 20 6c 69 73 74 20 69 an empty list i
4450: 73 20 72 65 74 75 72 6e 65 64 5c 26 2e 20 49 66 s returned\&. If
4460: 20 74 68 65 0a 5c 66 42 2d 6c 6f 63 61 6c 5c 66 the.\fB-local\f
4470: 52 20 6f 70 74 69 6f 6e 20 69 73 20 73 70 65 63 R option is spec
4480: 69 66 69 65 64 2c 20 74 68 65 6e 20 74 68 65 20 ified, then the
4490: 6c 6f 63 61 6c 20 63 65 72 74 69 66 69 63 61 74 local certificat
44a0: 65 20 69 73 20 75 73 65 64 5c 26 2e 20 52 65 74 e is used\&. Ret
44b0: 75 72 6e 65 64 0a 76 61 6c 75 65 73 20 69 6e 63 urned.values inc
44c0: 6c 75 64 65 3a 0a 2e 73 70 0a 53 53 4c 20 53 74 lude:..sp.SSL St
44d0: 61 74 75 73 0a 2e 52 53 0a 2e 54 50 0a 5c 66 42 atus..RS..TP.\fB
44e0: 61 6c 70 6e 5c 66 52 20 5c 66 49 70 72 6f 74 6f alpn\fR \fIproto
44f0: 63 6f 6c 5c 66 52 0a 54 68 65 20 70 72 6f 74 6f col\fR.The proto
4500: 63 6f 6c 20 73 65 6c 65 63 74 65 64 20 61 66 74 col selected aft
4510: 65 72 20 41 70 70 6c 69 63 61 74 69 6f 6e 2d 4c er Application-L
4520: 61 79 65 72 20 50 72 6f 74 6f 63 6f 6c 20 4e 65 ayer Protocol Ne
4530: 67 6f 74 69 61 74 69 6f 6e 20 28 41 4c 50 4e 29 gotiation (ALPN)
4540: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 63 69 70 68 65 \&...TP.\fBciphe
4550: 72 5c 66 52 20 5c 66 49 63 69 70 68 65 72 5c 66 r\fR \fIcipher\f
4560: 52 0a 54 68 65 20 63 75 72 72 65 6e 74 20 63 69 R.The current ci
4570: 70 68 65 72 20 69 6e 20 75 73 65 20 66 6f 72 20 pher in use for
4580: 74 68 65 20 73 65 73 73 69 6f 6e 5c 26 2e 0a 2e the session\&...
4590: 54 50 0a 5c 66 42 70 65 65 72 6e 61 6d 65 5c 66 TP.\fBpeername\f
45a0: 52 20 5c 66 49 6e 61 6d 65 5c 66 52 0a 54 68 65 R \fIname\fR.The
45b0: 20 70 65 65 72 6e 61 6d 65 20 66 72 6f 6d 20 74 peername from t
45c0: 68 65 20 63 65 72 74 69 66 69 63 61 74 65 5c 26 he certificate\&
45d0: 2e 0a 2e 54 50 0a 5c 66 42 70 72 6f 74 6f 63 6f ...TP.\fBprotoco
45e0: 6c 5c 66 52 20 5c 66 49 76 65 72 73 69 6f 6e 5c l\fR \fIversion\
45f0: 66 52 0a 54 68 65 20 70 72 6f 74 6f 63 6f 6c 20 fR.The protocol
4600: 76 65 72 73 69 6f 6e 20 75 73 65 64 20 66 6f 72 version used for
4610: 20 74 68 65 20 63 6f 6e 6e 65 63 74 69 6f 6e 3a the connection:
4620: 20 53 53 4c 32 2c 20 53 53 4c 33 2c 20 54 4c 53 SSL2, SSL3, TLS
4630: 31 2c 20 54 4c 53 31 5c 26 2e 31 2c 20 54 4c 53 1, TLS1\&.1, TLS
4640: 31 5c 26 2e 32 2c 20 54 4c 53 31 5c 26 2e 33 2c 1\&.2, TLS1\&.3,
4650: 20 6f 72 20 75 6e 6b 6e 6f 77 6e 5c 26 2e 0a 2e or unknown\&...
4660: 54 50 0a 5c 66 42 73 62 69 74 73 5c 66 52 20 5c TP.\fBsbits\fR \
4670: 66 49 6e 5c 66 52 0a 54 68 65 20 6e 75 6d 62 65 fIn\fR.The numbe
4680: 72 20 6f 66 20 62 69 74 73 20 75 73 65 64 20 66 r of bits used f
4690: 6f 72 20 74 68 65 20 73 65 73 73 69 6f 6e 20 6b or the session k
46a0: 65 79 5c 26 2e 0a 2e 54 50 0a 5c 66 42 73 69 67 ey\&...TP.\fBsig
46b0: 6e 61 74 75 72 65 48 61 73 68 41 6c 67 6f 72 69 natureHashAlgori
46c0: 74 68 6d 5c 66 52 20 5c 66 49 61 6c 67 6f 72 69 thm\fR \fIalgori
46d0: 74 68 6d 5c 66 52 0a 54 68 65 20 73 69 67 6e 61 thm\fR.The signa
46e0: 74 75 72 65 20 68 61 73 68 20 61 6c 67 6f 72 69 ture hash algori
46f0: 74 68 6d 5c 26 2e 0a 2e 54 50 0a 5c 66 42 73 69 thm\&...TP.\fBsi
4700: 67 6e 61 74 75 72 65 54 79 70 65 5c 66 52 20 5c gnatureType\fR \
4710: 66 49 74 79 70 65 5c 66 52 0a 54 68 65 20 73 69 fItype\fR.The si
4720: 67 6e 61 74 75 72 65 20 74 79 70 65 20 76 61 6c gnature type val
4730: 75 65 5c 26 2e 0a 2e 54 50 0a 5c 66 42 76 65 72 ue\&...TP.\fBver
4740: 69 66 79 44 65 70 74 68 5c 66 52 20 5c 66 49 6e ifyDepth\fR \fIn
4750: 5c 66 52 0a 4d 61 78 69 6d 75 6d 20 64 65 70 74 \fR.Maximum dept
4760: 68 20 66 6f 72 20 74 68 65 20 63 65 72 74 69 66 h for the certif
4770: 69 63 61 74 65 20 63 68 61 69 6e 20 76 65 72 69 icate chain veri
4780: 66 69 63 61 74 69 6f 6e 5c 26 2e 20 44 65 66 61 fication\&. Defa
4790: 75 6c 74 20 69 73 20 2d 31 2c 20 74 6f 20 63 68 ult is -1, to ch
47a0: 65 63 6b 20 61 6c 6c 5c 26 2e 0a 2e 54 50 0a 5c eck all\&...TP.\
47b0: 66 42 76 65 72 69 66 79 4d 6f 64 65 5c 66 52 20 fBverifyMode\fR
47c0: 5c 66 49 6c 69 73 74 5c 66 52 0a 4c 69 73 74 20 \fIlist\fR.List
47d0: 6f 66 20 63 65 72 74 69 66 69 63 61 74 65 20 76 of certificate v
47e0: 65 72 69 66 69 63 61 74 69 6f 6e 20 6d 6f 64 65 erification mode
47f0: 73 5c 26 2e 0a 2e 54 50 0a 5c 66 42 76 65 72 69 s\&...TP.\fBveri
4800: 66 79 52 65 73 75 6c 74 5c 66 52 20 5c 66 49 72 fyResult\fR \fIr
4810: 65 73 75 6c 74 5c 66 52 0a 43 65 72 74 69 66 69 esult\fR.Certifi
4820: 63 61 74 65 20 76 65 72 69 66 69 63 61 74 69 6f cate verificatio
4830: 6e 20 72 65 73 75 6c 74 5c 26 2e 0a 2e 54 50 0a n result\&...TP.
4840: 5c 66 42 63 61 5f 6e 61 6d 65 73 5c 66 52 20 5c \fBca_names\fR \
4850: 66 49 6c 69 73 74 5c 66 52 0a 4c 69 73 74 20 6f fIlist\fR.List o
4860: 66 20 74 68 65 20 43 65 72 74 69 66 69 63 61 74 f the Certificat
4870: 65 20 41 75 74 68 6f 72 69 74 69 65 73 20 75 73 e Authorities us
4880: 65 64 20 74 6f 20 63 72 65 61 74 65 20 74 68 65 ed to create the
4890: 20 63 65 72 74 69 66 69 63 61 74 65 5c 26 2e 0a certificate\&..
48a0: 2e 52 45 0a 2e 49 50 0a 43 65 72 74 69 66 69 63 .RE..IP.Certific
48b0: 61 74 65 20 53 74 61 74 75 73 0a 2e 52 53 0a 2e ate Status..RS..
48c0: 54 50 0a 5c 66 42 61 6c 6c 5c 66 52 20 5c 66 49 TP.\fBall\fR \fI
48d0: 73 74 72 69 6e 67 5c 66 52 0a 44 75 6d 70 20 6f string\fR.Dump o
48e0: 66 20 61 6c 6c 20 63 65 72 74 69 66 69 63 61 74 f all certificat
48f0: 65 20 69 6e 66 6f 5c 26 2e 0a 2e 54 50 0a 5c 66 e info\&...TP.\f
4900: 42 76 65 72 73 69 6f 6e 5c 66 52 20 5c 66 49 76 Bversion\fR \fIv
4910: 61 6c 75 65 5c 66 52 0a 54 68 65 20 63 65 72 74 alue\fR.The cert
4920: 69 66 69 63 61 74 65 20 76 65 72 73 69 6f 6e 5c ificate version\
4930: 26 2e 0a 2e 54 50 0a 5c 66 42 73 65 72 69 61 6c &...TP.\fBserial
4940: 4e 75 6d 62 65 72 5c 66 52 20 5c 66 49 73 74 72 Number\fR \fIstr
4950: 69 6e 67 5c 66 52 0a 54 68 65 20 73 65 72 69 61 ing\fR.The seria
4960: 6c 20 6e 75 6d 62 65 72 20 6f 66 20 74 68 65 20 l number of the
4970: 63 65 72 74 69 66 69 63 61 74 65 20 61 73 20 61 certificate as a
4980: 20 68 65 78 20 73 74 72 69 6e 67 5c 26 2e 0a 2e hex string\&...
4990: 54 50 0a 5c 66 42 73 69 67 6e 61 74 75 72 65 5c TP.\fBsignature\
49a0: 66 52 20 5c 66 49 61 6c 67 6f 72 69 74 68 6d 5c fR \fIalgorithm\
49b0: 66 52 0a 43 69 70 68 65 72 20 61 6c 67 6f 72 69 fR.Cipher algori
49c0: 74 68 6d 20 75 73 65 64 20 66 6f 72 20 63 65 72 thm used for cer
49d0: 74 69 66 69 63 61 74 65 20 73 69 67 6e 61 74 75 tificate signatu
49e0: 72 65 5c 26 2e 0a 2e 54 50 0a 5c 66 42 69 73 73 re\&...TP.\fBiss
49f0: 75 65 72 5c 66 52 20 5c 66 49 73 74 72 69 6e 67 uer\fR \fIstring
4a00: 5c 66 52 0a 54 68 65 20 64 69 73 74 69 6e 67 75 \fR.The distingu
4a10: 69 73 68 65 64 20 6e 61 6d 65 20 28 44 4e 29 20 ished name (DN)
4a20: 6f 66 20 74 68 65 20 63 65 72 74 69 66 69 63 61 of the certifica
4a30: 74 65 20 69 73 73 75 65 72 5c 26 2e 0a 2e 54 50 te issuer\&...TP
4a40: 0a 5c 66 42 6e 6f 74 42 65 66 6f 72 65 5c 66 52 .\fBnotBefore\fR
4a50: 20 5c 66 49 64 61 74 65 5c 66 52 0a 54 68 65 20 \fIdate\fR.The
4a60: 62 65 67 69 6e 6e 69 6e 67 20 64 61 74 65 20 6f beginning date o
4a70: 66 20 74 68 65 20 63 65 72 74 69 66 69 63 61 74 f the certificat
4a80: 65 20 76 61 6c 69 64 69 74 79 5c 26 2e 0a 2e 54 e validity\&...T
4a90: 50 0a 5c 66 42 6e 6f 74 41 66 74 65 72 5c 66 52 P.\fBnotAfter\fR
4aa0: 20 5c 66 49 64 61 74 65 5c 66 52 0a 54 68 65 20 \fIdate\fR.The
4ab0: 65 78 70 69 72 61 74 69 6f 6e 20 64 61 74 65 20 expiration date
4ac0: 6f 66 20 74 68 65 20 63 65 72 74 69 66 69 63 61 of the certifica
4ad0: 74 65 20 76 61 6c 69 64 69 74 79 5c 26 2e 0a 2e te validity\&...
4ae0: 54 50 0a 5c 66 42 73 75 62 6a 65 63 74 5c 66 52 TP.\fBsubject\fR
4af0: 20 5c 66 49 73 74 72 69 6e 67 5c 66 52 0a 54 68 \fIstring\fR.Th
4b00: 65 20 64 69 73 74 69 6e 67 75 69 73 68 65 64 20 e distinguished
4b10: 6e 61 6d 65 20 28 44 4e 29 20 6f 66 20 74 68 65 name (DN) of the
4b20: 20 63 65 72 74 69 66 69 63 61 74 65 20 73 75 62 certificate sub
4b30: 6a 65 63 74 5c 26 2e 20 46 69 65 6c 64 73 20 69 ject\&. Fields i
4b40: 6e 63 6c 75 64 65 3a 20 43 6f 6d 6d 6f 6e 0a 4e nclude: Common.N
4b50: 61 6d 65 20 28 43 4e 29 2c 20 4f 72 67 61 6e 69 ame (CN), Organi
4b60: 7a 61 74 69 6f 6e 20 28 4f 29 2c 20 4c 6f 63 61 zation (O), Loca
4b70: 6c 69 74 79 20 6f 72 20 43 69 74 79 20 28 4c 29 lity or City (L)
4b80: 2c 20 53 74 61 74 65 20 6f 72 20 50 72 6f 76 69 , State or Provi
4b90: 6e 63 65 20 28 53 29 2c 20 61 6e 64 0a 43 6f 75 nce (S), and.Cou
4ba0: 6e 74 72 79 20 4e 61 6d 65 20 28 43 29 5c 26 2e ntry Name (C)\&.
4bb0: 0a 2e 54 50 0a 5c 66 42 69 73 73 75 65 72 55 6e ..TP.\fBissuerUn
4bc0: 69 71 75 65 49 44 5c 66 52 20 5c 66 49 73 74 72 iqueID\fR \fIstr
4bd0: 69 6e 67 5c 66 52 0a 54 68 65 20 69 73 73 75 65 ing\fR.The issue
4be0: 72 20 75 6e 69 71 75 65 20 69 64 5c 26 2e 0a 2e r unique id\&...
4bf0: 54 50 0a 5c 66 42 73 75 62 6a 65 63 74 55 6e 69 TP.\fBsubjectUni
4c00: 71 75 65 49 44 5c 66 52 20 5c 66 49 73 74 72 69 queID\fR \fIstri
4c10: 6e 67 5c 66 52 0a 54 68 65 20 73 75 62 6a 65 63 ng\fR.The subjec
4c20: 74 20 75 6e 69 71 75 65 20 69 64 5c 26 2e 0a 2e t unique id\&...
4c30: 54 50 0a 5c 66 42 6e 75 6d 5f 65 78 74 65 6e 73 TP.\fBnum_extens
4c40: 69 6f 6e 73 5c 66 52 20 5c 66 49 6e 5c 66 52 0a ions\fR \fIn\fR.
4c50: 4e 75 6d 62 65 72 20 6f 66 20 63 65 72 74 69 66 Number of certif
4c60: 69 63 61 74 65 20 65 78 74 65 6e 73 69 6f 6e 73 icate extensions
4c70: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 65 78 74 65 6e \&...TP.\fBexten
4c80: 73 69 6f 6e 73 5c 66 52 20 5c 66 49 6c 69 73 74 sions\fR \fIlist
4c90: 5c 66 52 0a 4c 69 73 74 20 6f 66 20 63 65 72 74 \fR.List of cert
4ca0: 69 66 69 63 61 74 65 20 65 78 74 65 6e 73 69 6f ificate extensio
4cb0: 6e 20 6e 61 6d 65 73 5c 26 2e 0a 2e 54 50 0a 5c n names\&...TP.\
4cc0: 66 42 61 75 74 68 6f 72 69 74 79 4b 65 79 49 64 fBauthorityKeyId
4cd0: 65 6e 74 69 66 69 65 72 5c 66 52 20 5c 66 49 73 entifier\fR \fIs
4ce0: 74 72 69 6e 67 5c 66 52 0a 41 75 74 68 6f 72 69 tring\fR.Authori
4cf0: 74 79 20 4b 65 79 20 49 64 65 6e 74 69 66 69 65 ty Key Identifie
4d00: 72 20 28 41 4b 49 29 20 6f 66 20 74 68 65 20 49 r (AKI) of the I
4d10: 73 73 75 69 6e 67 20 43 41 20 63 65 72 74 69 66 ssuing CA certif
4d20: 69 63 61 74 65 20 74 68 61 74 20 73 69 67 6e 65 icate that signe
4d30: 64 20 74 68 65 0a 53 53 4c 20 63 65 72 74 69 66 d the.SSL certif
4d40: 69 63 61 74 65 20 61 73 20 61 20 68 65 78 20 73 icate as a hex s
4d50: 74 72 69 6e 67 5c 26 2e 20 54 68 69 73 20 76 61 tring\&. This va
4d60: 6c 75 65 20 6d 61 74 63 68 65 73 20 74 68 65 20 lue matches the
4d70: 53 4b 49 20 76 61 6c 75 65 20 6f 66 20 74 68 65 SKI value of the
4d80: 0a 49 6e 74 65 72 6d 65 64 69 61 74 65 20 43 41 .Intermediate CA
4d90: 20 63 65 72 74 69 66 69 63 61 74 65 5c 26 2e 0a certificate\&..
4da0: 2e 54 50 0a 5c 66 42 73 75 62 6a 65 63 74 4b 65 .TP.\fBsubjectKe
4db0: 79 49 64 65 6e 74 69 66 69 65 72 5c 66 52 20 5c yIdentifier\fR \
4dc0: 66 49 73 74 72 69 6e 67 5c 66 52 0a 53 75 62 6a fIstring\fR.Subj
4dd0: 65 63 74 20 4b 65 79 20 49 64 65 6e 74 69 66 69 ect Key Identifi
4de0: 65 72 20 28 53 4b 49 29 20 68 61 73 68 20 6f 66 er (SKI) hash of
4df0: 20 74 68 65 20 70 75 62 6c 69 63 20 6b 65 79 20 the public key
4e00: 69 6e 73 69 64 65 20 74 68 65 20 63 65 72 74 69 inside the certi
4e10: 66 69 63 61 74 65 20 61 73 20 61 0a 68 65 78 20 ficate as a.hex
4e20: 73 74 72 69 6e 67 5c 26 2e 20 55 73 65 64 20 74 string\&. Used t
4e30: 6f 20 69 64 65 6e 74 69 66 79 20 63 65 72 74 69 o identify certi
4e40: 66 69 63 61 74 65 73 20 74 68 61 74 20 63 6f 6e ficates that con
4e50: 74 61 69 6e 20 61 20 70 61 72 74 69 63 75 6c 61 tain a particula
4e60: 72 20 70 75 62 6c 69 63 20 6b 65 79 5c 26 2e 0a r public key\&..
4e70: 2e 54 50 0a 5c 66 42 73 75 62 6a 65 63 74 41 6c .TP.\fBsubjectAl
4e80: 74 4e 61 6d 65 5c 66 52 20 5c 66 49 6c 69 73 74 tName\fR \fIlist
4e90: 5c 66 52 0a 4c 69 73 74 20 6f 66 20 61 6c 6c 20 \fR.List of all
4ea0: 6f 66 20 74 68 65 20 53 75 62 6a 65 63 74 20 41 of the Subject A
4eb0: 6c 74 65 72 6e 61 74 69 76 65 20 4e 61 6d 65 73 lternative Names
4ec0: 20 28 53 41 4e 29 20 69 6e 63 6c 75 64 69 6e 67 (SAN) including
4ed0: 20 64 6f 6d 61 69 6e 20 6e 61 6d 65 73 2c 20 73 domain names, s
4ee0: 75 62 0a 64 6f 6d 61 69 6e 73 2c 20 61 6e 64 20 ub.domains, and
4ef0: 49 50 20 61 64 64 72 65 73 73 65 73 20 74 68 61 IP addresses tha
4f00: 74 20 61 72 65 20 73 65 63 75 72 65 64 20 62 79 t are secured by
4f10: 20 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65 the certificate
4f20: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 6f 63 73 70 5c \&...TP.\fBocsp\
4f30: 66 52 20 5c 66 49 6c 69 73 74 5c 66 52 0a 4c 69 fR \fIlist\fR.Li
4f40: 73 74 20 6f 66 20 61 6c 6c 20 4f 6e 6c 69 6e 65 st of all Online
4f50: 20 43 65 72 74 69 66 69 63 61 74 65 20 53 74 61 Certificate Sta
4f60: 74 75 73 20 50 72 6f 74 6f 63 6f 6c 20 28 4f 43 tus Protocol (OC
4f70: 53 50 29 20 55 52 4c 73 20 74 68 61 74 20 63 61 SP) URLs that ca
4f80: 6e 20 62 65 20 75 73 65 64 20 74 6f 0a 63 68 65 n be used to.che
4f90: 63 6b 20 74 68 65 20 76 61 6c 69 64 69 74 79 20 ck the validity
4fa0: 6f 66 20 74 68 69 73 20 63 65 72 74 69 66 69 63 of this certific
4fb0: 61 74 65 5c 26 2e 0a 2e 54 50 0a 5c 66 42 63 65 ate\&...TP.\fBce
4fc0: 72 74 69 66 69 63 61 74 65 5c 66 52 20 5c 66 49 rtificate\fR \fI
4fd0: 63 65 72 74 5c 66 52 0a 54 68 65 20 50 45 4d 20 cert\fR.The PEM
4fe0: 65 6e 63 6f 64 65 64 20 63 65 72 74 69 66 69 63 encoded certific
4ff0: 61 74 65 5c 26 2e 0a 2e 54 50 0a 5c 66 42 73 69 ate\&...TP.\fBsi
5000: 67 6e 61 74 75 72 65 41 6c 67 6f 72 69 74 68 6d gnatureAlgorithm
5010: 5c 66 52 20 5c 66 49 61 6c 67 6f 72 69 74 68 6d \fR \fIalgorithm
5020: 5c 66 52 0a 43 69 70 68 65 72 20 61 6c 67 6f 72 \fR.Cipher algor
5030: 69 74 68 6d 20 75 73 65 64 20 66 6f 72 20 74 68 ithm used for th
5040: 65 20 63 65 72 74 69 66 69 63 61 74 65 20 73 69 e certificate si
5050: 67 6e 61 74 75 72 65 5c 26 2e 0a 2e 54 50 0a 5c gnature\&...TP.\
5060: 66 42 73 69 67 6e 61 74 75 72 65 56 61 6c 75 65 fBsignatureValue
5070: 5c 66 52 20 5c 66 49 73 74 72 69 6e 67 5c 66 52 \fR \fIstring\fR
5080: 0a 43 65 72 74 69 66 69 63 61 74 65 20 73 69 67 .Certificate sig
5090: 6e 61 74 75 72 65 20 61 73 20 61 20 68 65 78 20 nature as a hex
50a0: 73 74 72 69 6e 67 5c 26 2e 0a 2e 54 50 0a 5c 66 string\&...TP.\f
50b0: 42 73 69 67 6e 61 74 75 72 65 44 69 67 65 73 74 BsignatureDigest
50c0: 5c 66 52 20 5c 66 49 76 65 72 73 69 6f 6e 5c 66 \fR \fIversion\f
50d0: 52 0a 43 65 72 74 69 66 69 63 61 74 65 20 73 69 R.Certificate si
50e0: 67 6e 69 6e 67 20 64 69 67 65 73 74 20 61 73 20 gning digest as
50f0: 61 20 68 65 78 20 73 74 72 69 6e 67 5c 26 2e 0a a hex string\&..
5100: 2e 54 50 0a 5c 66 42 70 75 62 6c 69 63 4b 65 79 .TP.\fBpublicKey
5110: 41 6c 67 6f 72 69 74 68 6d 5c 66 52 20 5c 66 49 Algorithm\fR \fI
5120: 61 6c 67 6f 72 69 74 68 6d 5c 66 52 0a 43 65 72 algorithm\fR.Cer
5130: 74 69 66 69 63 61 74 65 20 73 69 67 6e 61 74 75 tificate signatu
5140: 72 65 20 70 75 62 6c 69 63 20 6b 65 79 20 61 6c re public key al
5150: 67 6f 72 69 74 68 6d 5c 26 2e 0a 2e 54 50 0a 5c gorithm\&...TP.\
5160: 66 42 70 75 62 6c 69 63 4b 65 79 5c 66 52 20 5c fBpublicKey\fR \
5170: 66 49 73 74 72 69 6e 67 5c 66 52 0a 43 65 72 74 fIstring\fR.Cert
5180: 69 66 69 63 61 74 65 20 73 69 67 6e 61 74 75 72 ificate signatur
5190: 65 20 70 75 62 6c 69 63 20 6b 65 79 20 61 73 20 e public key as
51a0: 61 20 68 65 78 20 73 74 72 69 6e 67 5c 26 2e 0a a hex string\&..
51b0: 2e 54 50 0a 5c 66 42 62 69 74 73 5c 66 52 20 5c .TP.\fBbits\fR \
51c0: 66 49 6e 5c 66 52 0a 4e 75 6d 62 65 72 20 6f 66 fIn\fR.Number of
51d0: 20 62 69 74 73 20 75 73 65 64 20 66 6f 72 20 63 bits used for c
51e0: 65 72 74 69 66 69 63 61 74 65 20 73 69 67 6e 61 ertificate signa
51f0: 74 75 72 65 20 6b 65 79 5c 26 2e 0a 2e 54 50 0a ture key\&...TP.
5200: 5c 66 42 73 65 6c 66 5f 73 69 67 6e 65 64 5c 66 \fBself_signed\f
5210: 52 20 5c 66 49 62 6f 6f 6c 65 61 6e 5c 66 52 0a R \fIboolean\fR.
5220: 57 68 65 74 68 65 72 20 74 68 65 20 63 65 72 74 Whether the cert
5230: 69 66 69 63 61 74 65 20 73 69 67 6e 61 74 75 72 ificate signatur
5240: 65 20 69 73 20 73 65 6c 66 20 73 69 67 6e 65 64 e is self signed
5250: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 73 68 61 31 5f \&...TP.\fBsha1_
5260: 68 61 73 68 5c 66 52 20 5c 66 49 68 61 73 68 5c hash\fR \fIhash\
5270: 66 52 0a 54 68 65 20 53 48 41 31 20 68 61 73 68 fR.The SHA1 hash
5280: 20 6f 66 20 74 68 65 20 63 65 72 74 69 66 69 63 of the certific
5290: 61 74 65 20 61 73 20 61 20 68 65 78 20 73 74 72 ate as a hex str
52a0: 69 6e 67 5c 26 2e 0a 2e 54 50 0a 5c 66 42 73 68 ing\&...TP.\fBsh
52b0: 61 32 35 36 5f 68 61 73 68 5c 66 52 20 5c 66 49 a256_hash\fR \fI
52c0: 68 61 73 68 5c 66 52 0a 54 68 65 20 53 48 41 32 hash\fR.The SHA2
52d0: 35 36 20 68 61 73 68 20 6f 66 20 74 68 65 20 63 56 hash of the c
52e0: 65 72 74 69 66 69 63 61 74 65 20 61 73 20 61 20 ertificate as a
52f0: 68 65 78 20 73 74 72 69 6e 67 5c 26 2e 0a 2e 52 hex string\&...R
5300: 45 0a 2e 54 50 0a 5c 66 42 74 6c 73 3a 3a 63 6f E..TP.\fBtls::co
5310: 6e 6e 65 63 74 69 6f 6e 5c 66 52 20 5c 66 49 63 nnection\fR \fIc
5320: 68 61 6e 6e 65 6c 5c 66 52 0a 52 65 74 75 72 6e hannel\fR.Return
5330: 73 20 74 68 65 20 63 75 72 72 65 6e 74 20 63 6f s the current co
5340: 6e 6e 65 63 74 69 6f 6e 20 73 74 61 74 75 73 20 nnection status
5350: 6f 66 20 61 6e 20 53 53 4c 20 63 68 61 6e 6e 65 of an SSL channe
5360: 6c 5c 26 2e 20 54 68 65 20 72 65 73 75 6c 74 20 l\&. The result
5370: 69 73 20 61 20 6c 69 73 74 0a 6f 66 20 6b 65 79 is a list.of key
5380: 2d 76 61 6c 75 65 20 70 61 69 72 73 20 64 65 73 -value pairs des
5390: 63 72 69 62 69 6e 67 20 74 68 65 20 63 6f 6e 6e cribing the conn
53a0: 65 63 74 69 6f 6e 5c 26 2e 20 52 65 74 75 72 6e ection\&. Return
53b0: 65 64 20 76 61 6c 75 65 73 20 69 6e 63 6c 75 64 ed values includ
53c0: 65 3a 0a 2e 73 70 0a 53 53 4c 20 53 74 61 74 75 e:..sp.SSL Statu
53d0: 73 0a 2e 52 53 0a 2e 54 50 0a 5c 66 42 73 74 61 s..RS..TP.\fBsta
53e0: 74 65 5c 66 52 20 5c 66 49 73 74 61 74 65 5c 66 te\fR \fIstate\f
53f0: 52 0a 53 74 61 74 65 20 6f 66 20 74 68 65 20 63 R.State of the c
5400: 6f 6e 6e 65 63 74 69 6f 6e 5c 26 2e 0a 2e 54 50 onnection\&...TP
5410: 0a 5c 66 42 73 65 72 76 65 72 6e 61 6d 65 5c 66 .\fBservername\f
5420: 52 20 5c 66 49 6e 61 6d 65 5c 66 52 0a 54 68 65 R \fIname\fR.The
5430: 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 63 6f 6e name of the con
5440: 6e 65 63 74 65 64 20 74 6f 20 73 65 72 76 65 72 nected to server
5450: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 70 72 6f 74 6f \&...TP.\fBproto
5460: 63 6f 6c 5c 66 52 20 5c 66 49 76 65 72 73 69 6f col\fR \fIversio
5470: 6e 5c 66 52 0a 54 68 65 20 70 72 6f 74 6f 63 6f n\fR.The protoco
5480: 6c 20 76 65 72 73 69 6f 6e 20 75 73 65 64 20 66 l version used f
5490: 6f 72 20 74 68 65 20 63 6f 6e 6e 65 63 74 69 6f or the connectio
54a0: 6e 3a 20 53 53 4c 32 2c 20 53 53 4c 33 2c 20 54 n: SSL2, SSL3, T
54b0: 4c 53 31 2c 20 54 4c 53 31 5c 26 2e 31 2c 20 54 LS1, TLS1\&.1, T
54c0: 4c 53 31 5c 26 2e 32 2c 20 54 4c 53 31 5c 26 2e LS1\&.2, TLS1\&.
54d0: 33 2c 20 6f 72 20 75 6e 6b 6e 6f 77 6e 5c 26 2e 3, or unknown\&.
54e0: 0a 2e 54 50 0a 5c 66 42 72 65 6e 65 67 6f 74 69 ..TP.\fBrenegoti
54f0: 61 74 69 6f 6e 5f 61 6c 6c 6f 77 65 64 5c 66 52 ation_allowed\fR
5500: 20 5c 66 49 62 6f 6f 6c 65 61 6e 5c 66 52 0a 57 \fIboolean\fR.W
5510: 68 65 74 68 65 72 20 70 72 6f 74 6f 63 6f 6c 20 hether protocol
5520: 72 65 6e 65 67 6f 74 69 61 74 69 6f 6e 20 69 73 renegotiation is
5530: 20 73 75 70 70 6f 72 74 65 64 20 6f 72 20 6e 6f supported or no
5540: 74 5c 26 2e 0a 2e 54 50 0a 5c 66 42 73 65 63 75 t\&...TP.\fBsecu
5550: 72 69 74 79 5f 6c 65 76 65 6c 5c 66 52 20 5c 66 rity_level\fR \f
5560: 49 6c 65 76 65 6c 5c 66 52 0a 54 68 65 20 73 65 Ilevel\fR.The se
5570: 63 75 72 69 74 79 20 6c 65 76 65 6c 20 75 73 65 curity level use
5580: 64 20 66 6f 72 20 73 65 6c 65 63 74 69 6f 6e 20 d for selection
5590: 6f 66 20 63 69 70 68 65 72 73 2c 20 6b 65 79 20 of ciphers, key
55a0: 73 69 7a 65 2c 20 65 74 63 5c 26 2e 0a 2e 54 50 size, etc\&...TP
55b0: 0a 5c 66 42 73 65 73 73 69 6f 6e 5f 72 65 75 73 .\fBsession_reus
55c0: 65 64 5c 66 52 20 5c 66 49 62 6f 6f 6c 65 61 6e ed\fR \fIboolean
55d0: 5c 66 52 0a 57 68 65 74 68 65 72 20 74 68 65 20 \fR.Whether the
55e0: 73 65 73 73 69 6f 6e 20 68 61 73 20 62 65 65 6e session has been
55f0: 20 72 65 75 73 65 64 20 6f 72 20 6e 6f 74 5c 26 reused or not\&
5600: 2e 0a 2e 54 50 0a 5c 66 42 69 73 5f 73 65 72 76 ...TP.\fBis_serv
5610: 65 72 5c 66 52 20 5c 66 49 62 6f 6f 6c 65 61 6e er\fR \fIboolean
5620: 5c 66 52 0a 57 68 65 74 68 65 72 20 74 68 65 20 \fR.Whether the
5630: 63 6f 6e 6e 65 63 74 69 6f 6e 20 69 73 20 63 6f connection is co
5640: 6e 66 69 67 75 72 65 64 20 61 73 20 61 20 73 65 nfigured as a se
5650: 72 76 65 72 20 28 31 29 20 6f 72 20 63 6c 69 65 rver (1) or clie
5660: 6e 74 20 28 30 29 5c 26 2e 0a 2e 54 50 0a 5c 66 nt (0)\&...TP.\f
5670: 42 63 6f 6d 70 72 65 73 73 69 6f 6e 5c 66 52 20 Bcompression\fR
5680: 5c 66 49 6d 6f 64 65 5c 66 52 0a 43 6f 6d 70 72 \fImode\fR.Compr
5690: 65 73 73 69 6f 6e 20 6d 65 74 68 6f 64 5c 26 2e ession method\&.
56a0: 0a 2e 54 50 0a 5c 66 42 65 78 70 61 6e 73 69 6f ..TP.\fBexpansio
56b0: 6e 5c 66 52 20 5c 66 49 6d 6f 64 65 5c 66 52 0a n\fR \fImode\fR.
56c0: 45 78 70 61 6e 73 69 6f 6e 20 6d 65 74 68 6f 64 Expansion method
56d0: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 63 61 4c 69 73 \&...TP.\fBcaLis
56e0: 74 5c 66 52 20 5c 66 49 6c 69 73 74 5c 66 52 0a t\fR \fIlist\fR.
56f0: 4c 69 73 74 20 6f 66 20 43 65 72 74 69 66 69 63 List of Certific
5700: 61 74 65 20 41 75 74 68 6f 72 69 74 69 65 73 20 ate Authorities
5710: 28 43 41 29 20 66 6f 72 20 58 5c 26 2e 35 30 39 (CA) for X\&.509
5720: 20 63 65 72 74 69 66 69 63 61 74 65 5c 26 2e 0a certificate\&..
5730: 2e 52 45 0a 2e 49 50 0a 43 69 70 68 65 72 20 49 .RE..IP.Cipher I
5740: 6e 66 6f 0a 2e 52 53 0a 2e 54 50 0a 5c 66 42 63 nfo..RS..TP.\fBc
5750: 69 70 68 65 72 5c 66 52 20 5c 66 49 63 69 70 68 ipher\fR \fIciph
5760: 65 72 5c 66 52 0a 54 68 65 20 63 75 72 72 65 6e er\fR.The curren
5770: 74 20 63 69 70 68 65 72 20 69 6e 20 75 73 65 20 t cipher in use
5780: 66 6f 72 20 74 68 65 20 63 6f 6e 6e 65 63 74 69 for the connecti
5790: 6f 6e 5c 26 2e 0a 2e 54 50 0a 5c 66 42 73 74 61 on\&...TP.\fBsta
57a0: 6e 64 61 72 64 5f 6e 61 6d 65 5c 66 52 20 5c 66 ndard_name\fR \f
57b0: 49 6e 61 6d 65 5c 66 52 0a 54 68 65 20 73 74 61 Iname\fR.The sta
57c0: 6e 64 61 72 64 20 52 46 43 20 6e 61 6d 65 20 6f ndard RFC name o
57d0: 66 20 63 69 70 68 65 72 5c 26 2e 0a 2e 54 50 0a f cipher\&...TP.
57e0: 5c 66 42 61 6c 67 6f 72 69 74 68 6d 5f 62 69 74 \fBalgorithm_bit
57f0: 73 5c 66 52 20 5c 66 49 6e 5c 66 52 0a 54 68 65 s\fR \fIn\fR.The
5800: 20 6e 75 6d 62 65 72 20 6f 66 20 70 72 6f 63 65 number of proce
5810: 73 73 65 64 20 62 69 74 73 20 75 73 65 64 20 66 ssed bits used f
5820: 6f 72 20 63 69 70 68 65 72 5c 26 2e 0a 2e 54 50 or cipher\&...TP
5830: 0a 5c 66 42 73 65 63 72 65 74 5f 62 69 74 73 5c .\fBsecret_bits\
5840: 66 52 20 5c 66 49 6e 5c 66 52 0a 54 68 65 20 6e fR \fIn\fR.The n
5850: 75 6d 62 65 72 20 6f 66 20 73 65 63 72 65 74 20 umber of secret
5860: 62 69 74 73 20 75 73 65 64 20 66 6f 72 20 63 69 bits used for ci
5870: 70 68 65 72 5c 26 2e 0a 2e 54 50 0a 5c 66 42 6d pher\&...TP.\fBm
5880: 69 6e 5f 76 65 72 73 69 6f 6e 5c 66 52 20 5c 66 in_version\fR \f
5890: 49 76 65 72 73 69 6f 6e 5c 66 52 0a 54 68 65 20 Iversion\fR.The
58a0: 6d 69 6e 69 6d 75 6d 20 70 72 6f 74 6f 63 6f 6c minimum protocol
58b0: 20 76 65 72 73 69 6f 6e 20 66 6f 72 20 63 69 70 version for cip
58c0: 68 65 72 5c 26 2e 0a 2e 54 50 0a 5c 66 42 63 69 her\&...TP.\fBci
58d0: 70 68 65 72 5f 69 73 5f 61 65 61 64 5c 66 52 20 pher_is_aead\fR
58e0: 5c 66 49 62 6f 6f 6c 65 61 6e 5c 66 52 0a 57 68 \fIboolean\fR.Wh
58f0: 65 74 68 65 72 20 74 68 65 20 63 69 70 68 65 72 ether the cipher
5900: 20 69 73 20 41 75 74 68 65 6e 74 69 63 61 74 65 is Authenticate
5910: 64 20 45 6e 63 72 79 70 74 69 6f 6e 20 77 69 74 d Encryption wit
5920: 68 20 41 73 73 6f 63 69 61 74 65 64 20 44 61 74 h Associated Dat
5930: 61 20 28 41 45 41 44 29 5c 26 2e 0a 2e 54 50 0a a (AEAD)\&...TP.
5940: 5c 66 42 63 69 70 68 65 72 5f 69 64 5c 66 52 20 \fBcipher_id\fR
5950: 5c 66 49 69 64 5c 66 52 0a 54 68 65 20 4f 70 65 \fIid\fR.The Ope
5960: 6e 53 53 4c 20 63 69 70 68 65 72 20 69 64 5c 26 nSSL cipher id\&
5970: 2e 0a 2e 54 50 0a 5c 66 42 64 65 73 63 72 69 70 ...TP.\fBdescrip
5980: 74 69 6f 6e 5c 66 52 20 5c 66 49 73 74 72 69 6e tion\fR \fIstrin
5990: 67 5c 66 52 0a 41 20 74 65 78 74 20 64 65 73 63 g\fR.A text desc
59a0: 72 69 70 74 69 6f 6e 20 6f 66 20 74 68 65 20 63 ription of the c
59b0: 69 70 68 65 72 5c 26 2e 0a 2e 54 50 0a 5c 66 42 ipher\&...TP.\fB
59c0: 68 61 6e 64 73 68 61 6b 65 5f 64 69 67 65 73 74 handshake_digest
59d0: 5c 66 52 20 5c 66 49 62 6f 6f 6c 65 61 6e 5c 66 \fR \fIboolean\f
59e0: 52 0a 44 69 67 65 73 74 20 75 73 65 64 20 64 75 R.Digest used du
59f0: 72 69 6e 67 20 68 61 6e 64 73 68 61 6b 65 5c 26 ring handshake\&
5a00: 2e 0a 2e 52 45 0a 2e 49 50 0a 53 65 73 73 69 6f ...RE..IP.Sessio
5a10: 6e 20 49 6e 66 6f 0a 2e 52 53 0a 2e 54 50 0a 5c n Info..RS..TP.\
5a20: 66 42 61 6c 70 6e 5c 66 52 20 5c 66 49 70 72 6f fBalpn\fR \fIpro
5a30: 74 6f 63 6f 6c 5c 66 52 0a 54 68 65 20 70 72 6f tocol\fR.The pro
5a40: 74 6f 63 6f 6c 20 73 65 6c 65 63 74 65 64 20 61 tocol selected a
5a50: 66 74 65 72 20 41 70 70 6c 69 63 61 74 69 6f 6e fter Application
5a60: 2d 4c 61 79 65 72 20 50 72 6f 74 6f 63 6f 6c 20 -Layer Protocol
5a70: 4e 65 67 6f 74 69 61 74 69 6f 6e 20 28 41 4c 50 Negotiation (ALP
5a80: 4e 29 5c 26 2e 0a 2e 54 50 0a 5c 66 42 72 65 73 N)\&...TP.\fBres
5a90: 75 6d 61 62 6c 65 5c 66 52 20 5c 66 49 62 6f 6f umable\fR \fIboo
5aa0: 6c 65 61 6e 5c 66 52 0a 57 68 65 74 68 65 72 20 lean\fR.Whether
5ab0: 74 68 65 20 73 65 73 73 69 6f 6e 20 63 61 6e 20 the session can
5ac0: 62 65 20 72 65 73 75 6d 65 64 20 6f 72 20 6e 6f be resumed or no
5ad0: 74 5c 26 2e 0a 2e 54 50 0a 5c 66 42 73 74 61 72 t\&...TP.\fBstar
5ae0: 74 5f 74 69 6d 65 5c 66 52 20 5c 66 49 73 65 63 t_time\fR \fIsec
5af0: 6f 6e 64 73 5c 66 52 0a 54 69 6d 65 20 73 69 6e onds\fR.Time sin
5b00: 63 65 20 73 65 73 73 69 6f 6e 20 73 74 61 72 74 ce session start
5b10: 65 64 20 69 6e 20 73 65 63 6f 6e 64 73 20 73 69 ed in seconds si
5b20: 6e 63 65 20 65 70 6f 63 68 5c 26 2e 0a 2e 54 50 nce epoch\&...TP
5b30: 0a 5c 66 42 74 69 6d 65 6f 75 74 5c 66 52 20 5c .\fBtimeout\fR \
5b40: 66 49 73 65 63 6f 6e 64 73 5c 66 52 0a 4d 61 78 fIseconds\fR.Max
5b50: 20 64 75 72 61 74 69 6f 6e 20 6f 66 20 73 65 73 duration of ses
5b60: 73 69 6f 6e 20 69 6e 20 73 65 63 6f 6e 64 73 20 sion in seconds
5b70: 62 65 66 6f 72 65 20 74 69 6d 65 2d 6f 75 74 5c before time-out\
5b80: 26 2e 0a 2e 54 50 0a 5c 66 42 6c 69 66 65 74 69 &...TP.\fBlifeti
5b90: 6d 65 5c 66 52 20 5c 66 49 73 65 63 6f 6e 64 73 me\fR \fIseconds
5ba0: 5c 66 52 0a 53 65 73 73 69 6f 6e 20 74 69 63 6b \fR.Session tick
5bb0: 65 74 20 6c 69 66 65 74 69 6d 65 20 68 69 6e 74 et lifetime hint
5bc0: 20 69 6e 20 73 65 63 6f 6e 64 73 5c 26 2e 0a 2e in seconds\&...
5bd0: 54 50 0a 5c 66 42 73 65 73 73 69 6f 6e 5f 69 64 TP.\fBsession_id
5be0: 5c 66 52 20 5c 66 49 62 69 6e 61 72 79 5f 73 74 \fR \fIbinary_st
5bf0: 72 69 6e 67 5c 66 52 0a 55 6e 69 71 75 65 20 73 ring\fR.Unique s
5c00: 65 73 73 69 6f 6e 20 69 64 20 66 6f 72 20 75 73 ession id for us
5c10: 65 20 69 6e 20 72 65 73 75 6d 69 6e 67 20 74 68 e in resuming th
5c20: 65 20 73 65 73 73 69 6f 6e 5c 26 2e 0a 2e 54 50 e session\&...TP
5c30: 0a 5c 66 42 73 65 73 73 69 6f 6e 5f 74 69 63 6b .\fBsession_tick
5c40: 65 74 5c 66 52 20 5c 66 49 62 69 6e 61 72 79 5f et\fR \fIbinary_
5c50: 73 74 72 69 6e 67 5c 66 52 0a 55 6e 69 71 75 65 string\fR.Unique
5c60: 20 73 65 73 73 69 6f 6e 20 74 69 63 6b 65 74 20 session ticket
5c70: 66 6f 72 20 75 73 65 20 69 6e 20 72 65 73 75 6d for use in resum
5c80: 69 6e 67 20 74 68 65 20 73 65 73 73 69 6f 6e 5c ing the session\
5c90: 26 2e 0a 2e 54 50 0a 5c 66 42 74 69 63 6b 65 74 &...TP.\fBticket
5ca0: 5f 61 70 70 5f 64 61 74 61 5c 66 52 20 5c 66 49 _app_data\fR \fI
5cb0: 62 69 6e 61 72 79 5f 73 74 72 69 6e 67 5c 66 52 binary_string\fR
5cc0: 0a 55 6e 69 71 75 65 20 73 65 73 73 69 6f 6e 20 .Unique session
5cd0: 74 69 63 6b 65 74 20 61 70 70 6c 69 63 61 74 69 ticket applicati
5ce0: 6f 6e 20 64 61 74 61 5c 26 2e 0a 2e 54 50 0a 5c on data\&...TP.\
5cf0: 66 42 6d 61 73 74 65 72 5f 6b 65 79 5c 66 52 20 fBmaster_key\fR
5d00: 5c 66 49 62 69 6e 61 72 79 5f 73 74 72 69 6e 67 \fIbinary_string
5d10: 5c 66 52 0a 55 6e 69 71 75 65 20 73 65 73 73 69 \fR.Unique sessi
5d20: 6f 6e 20 6d 61 73 74 65 72 20 6b 65 79 5c 26 2e on master key\&.
5d30: 0a 2e 54 50 0a 5c 66 42 73 65 73 73 69 6f 6e 5f ..TP.\fBsession_
5d40: 63 61 63 68 65 5f 6d 6f 64 65 5c 66 52 20 5c 66 cache_mode\fR \f
5d50: 49 6d 6f 64 65 5c 66 52 0a 53 65 72 76 65 72 20 Imode\fR.Server
5d60: 63 61 63 68 65 20 6d 6f 64 65 20 28 63 6c 69 65 cache mode (clie
5d70: 6e 74 2c 20 73 65 72 76 65 72 2c 20 6f 72 20 62 nt, server, or b
5d80: 6f 74 68 29 5c 26 2e 0a 2e 52 45 0a 2e 54 50 0a oth)\&...RE..TP.
5d90: 5c 66 42 74 6c 73 3a 3a 63 69 70 68 65 72 73 5c \fBtls::ciphers\
5da0: 66 52 20 3f 5c 66 49 70 72 6f 74 6f 63 6f 6c 5c fR ?\fIprotocol\
5db0: 66 52 3f 20 3f 5c 66 49 76 65 72 62 6f 73 65 5c fR? ?\fIverbose\
5dc0: 66 52 3f 20 3f 5c 66 49 73 75 70 70 6f 72 74 65 fR? ?\fIsupporte
5dd0: 64 5c 66 52 3f 0a 57 69 74 68 6f 75 74 20 61 6e d\fR?.Without an
5de0: 79 20 61 72 67 73 2c 20 72 65 74 75 72 6e 73 20 y args, returns
5df0: 61 20 6c 69 73 74 20 6f 66 20 61 6c 6c 20 73 79 a list of all sy
5e00: 6d 6d 65 74 72 69 63 20 63 69 70 68 65 72 73 20 mmetric ciphers
5e10: 66 6f 72 20 75 73 65 20 77 69 74 68 20 74 68 65 for use with the
5e20: 0a 5c 66 49 2d 63 69 70 68 65 72 5c 66 52 20 6f .\fI-cipher\fR o
5e30: 70 74 69 6f 6e 5c 26 2e 20 57 69 74 68 20 5c 66 ption\&. With \f
5e40: 49 70 72 6f 74 6f 63 6f 6c 5c 66 52 2c 20 6f 6e Iprotocol\fR, on
5e50: 6c 79 20 74 68 65 20 63 69 70 68 65 72 73 20 73 ly the ciphers s
5e60: 75 70 70 6f 72 74 65 64 20 66 6f 72 20 74 68 61 upported for tha
5e70: 74 0a 70 72 6f 74 6f 63 6f 6c 20 61 72 65 20 72 t.protocol are r
5e80: 65 74 75 72 6e 65 64 5c 26 2e 20 53 65 65 20 74 eturned\&. See t
5e90: 68 65 20 5c 66 42 74 6c 73 3a 3a 70 72 6f 74 6f he \fBtls::proto
5ea0: 63 6f 6c 73 5c 66 52 20 63 6f 6d 6d 61 6e 64 20 cols\fR command
5eb0: 66 6f 72 20 74 68 65 20 73 75 70 70 6f 72 74 65 for the supporte
5ec0: 64 0a 70 72 6f 74 6f 63 6f 6c 73 5c 26 2e 20 49 d.protocols\&. I
5ed0: 66 20 5c 66 49 76 65 72 62 6f 73 65 5c 66 52 20 f \fIverbose\fR
5ee0: 69 73 20 73 70 65 63 69 66 69 65 64 20 61 73 20 is specified as
5ef0: 74 72 75 65 20 74 68 65 6e 20 61 20 76 65 72 62 true then a verb
5f00: 6f 73 65 2c 20 68 75 6d 61 6e 20 72 65 61 64 61 ose, human reada
5f10: 62 6c 65 0a 6c 69 73 74 20 69 73 20 72 65 74 75 ble.list is retu
5f20: 72 6e 65 64 20 77 69 74 68 20 61 64 64 69 74 69 rned with additi
5f30: 6f 6e 61 6c 20 69 6e 66 6f 72 6d 61 74 69 6f 6e onal information
5f40: 20 6f 6e 20 74 68 65 20 63 69 70 68 65 72 5c 26 on the cipher\&
5f50: 2e 20 49 66 20 5c 66 49 73 75 70 70 6f 72 74 65 . If \fIsupporte
5f60: 64 5c 66 52 0a 69 73 20 73 70 65 63 69 66 69 65 d\fR.is specifie
5f70: 64 20 61 73 20 74 72 75 65 2c 20 74 68 65 6e 20 d as true, then
5f80: 6f 6e 6c 79 20 74 68 65 20 63 69 70 68 65 72 73 only the ciphers
5f90: 20 73 75 70 70 6f 72 74 65 64 20 66 6f 72 20 70 supported for p
5fa0: 72 6f 74 6f 63 6f 6c 20 77 69 6c 6c 20 62 65 20 rotocol will be
5fb0: 6c 69 73 74 65 64 5c 26 2e 0a 2e 54 50 0a 5c 66 listed\&...TP.\f
5fc0: 42 74 6c 73 3a 3a 70 72 6f 74 6f 63 6f 6c 73 5c Btls::protocols\
5fd0: 66 52 0a 52 65 74 75 72 6e 73 20 61 20 6c 69 73 fR.Returns a lis
5fe0: 74 20 6f 66 20 74 68 65 20 73 75 70 70 6f 72 74 t of the support
5ff0: 65 64 20 53 53 4c 2f 54 4c 53 20 70 72 6f 74 6f ed SSL/TLS proto
6000: 63 6f 6c 73 5c 26 2e 20 56 61 6c 69 64 20 76 61 cols\&. Valid va
6010: 6c 75 65 73 20 61 72 65 3a 0a 5c 66 42 73 73 6c lues are:.\fBssl
6020: 32 5c 66 52 2c 20 5c 66 42 73 73 6c 33 5c 66 52 2\fR, \fBssl3\fR
6030: 2c 20 5c 66 42 74 6c 73 31 5c 66 52 2c 20 5c 66 , \fBtls1\fR, \f
6040: 42 74 6c 73 31 5c 26 2e 31 5c 66 52 2c 20 5c 66 Btls1\&.1\fR, \f
6050: 42 74 6c 73 31 5c 26 2e 32 5c 66 52 2c 20 61 6e Btls1\&.2\fR, an
6060: 64 0a 5c 66 42 74 6c 73 31 5c 26 2e 33 5c 66 52 d.\fBtls1\&.3\fR
6070: 5c 26 2e 20 45 78 61 63 74 20 6c 69 73 74 20 64 \&. Exact list d
6080: 65 70 65 6e 64 73 20 6f 6e 20 4f 70 65 6e 53 53 epends on OpenSS
6090: 4c 20 76 65 72 73 69 6f 6e 20 61 6e 64 20 63 6f L version and co
60a0: 6d 70 69 6c 65 20 74 69 6d 65 20 66 6c 61 67 73 mpile time flags
60b0: 5c 26 2e 0a 2e 54 50 0a 5c 66 42 74 6c 73 3a 3a \&...TP.\fBtls::
60c0: 76 65 72 73 69 6f 6e 5c 66 52 0a 52 65 74 75 72 version\fR.Retur
60d0: 6e 73 20 74 68 65 20 4f 70 65 6e 53 53 4c 20 76 ns the OpenSSL v
60e0: 65 72 73 69 6f 6e 20 73 74 72 69 6e 67 5c 26 2e ersion string\&.
60f0: 0a 2e 50 50 0a 2e 53 48 20 22 43 45 52 54 49 46 ..PP..SH "CERTIF
6100: 49 43 41 54 45 20 56 41 4c 49 44 41 54 49 4f 4e ICATE VALIDATION
6110: 22 0a 2e 53 53 20 22 50 4b 49 20 41 4e 44 20 43 "..SS "PKI AND C
6120: 45 52 54 49 46 49 43 41 54 45 53 22 0a 55 73 69 ERTIFICATES".Usi
6130: 6e 67 20 74 68 65 20 50 75 62 6c 69 63 20 4b 65 ng the Public Ke
6140: 79 20 49 6e 66 72 61 73 74 72 75 63 74 75 72 65 y Infrastructure
6150: 20 28 50 4b 49 29 2c 20 65 61 63 68 20 75 73 65 (PKI), each use
6160: 72 20 63 72 65 61 74 65 73 20 61 20 70 72 69 76 r creates a priv
6170: 61 74 65 20 6b 65 79 20 74 68 61 74 0a 6f 6e 6c ate key that.onl
6180: 79 20 74 68 65 79 20 6b 6e 6f 77 20 61 62 6f 75 y they know abou
6190: 74 20 61 6e 64 20 61 20 70 75 62 6c 69 63 20 6b t and a public k
61a0: 65 79 20 74 68 65 79 20 63 61 6e 20 65 78 63 68 ey they can exch
61b0: 61 6e 67 65 20 77 69 74 68 20 6f 74 68 65 72 73 ange with others
61c0: 20 66 6f 72 20 75 73 65 20 69 6e 0a 65 6e 63 72 for use in.encr
61d0: 79 70 74 69 6e 67 20 61 6e 64 20 64 65 63 72 79 ypting and decry
61e0: 70 74 69 6e 67 20 64 61 74 61 5c 26 2e 20 54 68 pting data\&. Th
61f0: 65 20 70 72 6f 63 65 73 73 20 69 73 20 74 68 65 e process is the
6200: 20 73 65 6e 64 65 72 20 65 6e 63 72 79 70 74 73 sender encrypts
6210: 20 74 68 65 69 72 20 64 61 74 61 0a 75 73 69 6e their data.usin
6220: 67 20 74 68 65 69 72 20 70 72 69 76 61 74 65 20 g their private
6230: 6b 65 79 20 61 6e 64 20 74 68 65 20 72 65 63 65 key and the rece
6240: 69 76 65 72 27 73 20 70 75 62 6c 69 63 20 6b 65 iver's public ke
6250: 79 5c 26 2e 20 54 68 65 20 64 61 74 61 20 69 73 y\&. The data is
6260: 20 74 68 65 6e 20 73 65 6e 74 0a 74 6f 20 74 68 then sent.to th
6270: 65 20 72 65 63 65 69 76 65 72 5c 26 2e 20 49 6e e receiver\&. In
6280: 20 61 20 73 69 6d 69 6c 61 72 20 6d 61 6e 6e 65 a similar manne
6290: 72 2c 20 74 68 65 20 72 65 63 65 69 76 65 72 20 r, the receiver
62a0: 75 73 65 73 20 74 68 65 69 72 20 70 72 69 76 61 uses their priva
62b0: 74 65 20 6b 65 79 20 61 6e 64 0a 74 68 65 20 73 te key and.the s
62c0: 65 6e 64 65 72 27 73 20 70 75 62 6c 69 63 20 6b ender's public k
62d0: 65 79 20 74 6f 20 64 65 63 72 79 70 74 20 74 68 ey to decrypt th
62e0: 65 20 64 61 74 61 5c 26 2e 20 54 68 69 73 20 70 e data\&. This p
62f0: 72 6f 76 69 64 65 73 20 64 61 74 61 20 69 6e 74 rovides data int
6300: 65 67 72 69 74 79 2c 20 74 6f 0a 65 6e 73 75 72 egrity, to.ensur
6310: 65 20 74 68 65 20 64 61 74 61 20 63 61 6e 27 74 e the data can't
6320: 20 62 65 20 76 69 65 77 65 64 20 6f 72 20 61 6c be viewed or al
6330: 74 65 72 65 64 20 64 75 72 69 6e 67 20 74 72 61 tered during tra
6340: 6e 73 70 6f 72 74 5c 26 2e 20 53 65 65 20 74 68 nsport\&. See th
6350: 65 0a 5c 66 42 2d 6b 65 79 5c 66 52 20 61 6e 64 e.\fB-key\fR and
6360: 20 5c 66 42 2d 6b 65 79 66 69 6c 65 5c 66 52 20 \fB-keyfile\fR
6370: 6f 70 74 69 6f 6e 73 20 66 6f 72 20 68 6f 77 20 options for how
6380: 74 6f 20 73 70 65 63 69 66 79 20 74 68 65 20 70 to specify the p
6390: 72 69 76 61 74 65 20 6b 65 79 5c 26 2e 0a 41 6c rivate key\&..Al
63a0: 73 6f 20 73 65 65 20 74 68 65 20 5c 66 42 2d 70 so see the \fB-p
63b0: 61 73 73 77 6f 72 64 5c 66 52 20 6f 70 74 69 6f assword\fR optio
63c0: 6e 20 66 6f 72 20 68 6f 77 20 74 6f 20 70 72 6f n for how to pro
63d0: 76 69 64 65 20 74 68 65 20 70 61 73 73 77 6f 72 vide the passwor
63e0: 64 5c 26 2e 0a 2e 50 50 0a 49 6e 20 6f 72 64 65 d\&...PP.In orde
63f0: 72 20 74 6f 20 70 72 6f 76 69 64 65 20 61 75 74 r to provide aut
6400: 68 65 6e 74 69 63 61 74 69 6f 6e 2c 20 69 5c 26 hentication, i\&
6410: 2e 65 5c 26 2e 20 65 6e 73 75 72 69 6e 67 20 73 .e\&. ensuring s
6420: 6f 6d 65 6f 6e 65 20 69 73 20 77 68 6f 20 74 68 omeone is who th
6430: 65 79 20 73 61 79 20 74 68 65 79 0a 61 72 65 2c ey say they.are,
6440: 20 74 68 65 20 70 75 62 6c 69 63 20 6b 65 79 20 the public key
6450: 61 6e 64 20 75 73 65 72 20 69 64 65 6e 74 69 66 and user identif
6460: 69 63 61 74 69 6f 6e 20 69 6e 66 6f 20 69 73 20 ication info is
6470: 73 74 6f 72 65 64 20 69 6e 20 61 20 58 5c 26 2e stored in a X\&.
6480: 35 30 39 0a 63 65 72 74 69 66 69 63 61 74 65 20 509.certificate
6490: 61 6e 64 20 74 68 61 74 20 63 65 72 74 69 66 69 and that certifi
64a0: 63 61 74 65 20 69 73 20 61 75 74 68 65 6e 74 69 cate is authenti
64b0: 63 61 74 65 64 20 28 69 5c 26 2e 65 5c 26 2e 20 cated (i\&.e\&.
64c0: 73 69 67 6e 65 64 29 20 62 79 20 61 20 43 65 72 signed) by a Cer
64d0: 74 69 66 69 63 61 74 65 0a 41 75 74 68 6f 72 69 tificate.Authori
64e0: 74 79 20 28 43 41 29 5c 26 2e 20 55 73 65 72 73 ty (CA)\&. Users
64f0: 20 63 61 6e 20 74 68 65 6e 20 65 78 63 68 61 6e can then exchan
6500: 67 65 20 74 68 65 73 65 20 63 65 72 74 69 66 69 ge these certifi
6510: 63 61 74 65 73 20 64 75 72 69 6e 67 20 74 68 65 cates during the
6520: 20 54 4c 53 0a 69 6e 69 74 69 61 6c 69 7a 61 74 TLS.initializat
6530: 69 6f 6e 20 70 72 6f 63 65 73 73 20 61 6e 64 20 ion process and
6540: 63 68 65 63 6b 20 74 68 65 6d 20 61 67 61 69 6e check them again
6550: 73 74 20 74 68 65 20 72 6f 6f 74 20 43 41 20 63 st the root CA c
6560: 65 72 74 69 66 69 63 61 74 65 73 20 74 6f 20 65 ertificates to e
6570: 6e 73 75 72 65 0a 74 68 65 79 20 61 72 65 20 76 nsure.they are v
6580: 61 6c 69 64 5c 26 2e 20 54 68 69 73 20 69 73 20 alid\&. This is
6590: 68 61 6e 64 6c 65 64 20 62 79 20 4f 70 65 6e 53 handled by OpenS
65a0: 53 4c 20 76 69 61 20 74 68 65 20 5c 66 42 2d 72 SL via the \fB-r
65b0: 65 71 75 65 73 74 5c 66 52 20 61 6e 64 0a 5c 66 equest\fR and.\f
65c0: 42 2d 72 65 71 75 69 72 65 5c 66 52 20 6f 70 74 B-require\fR opt
65d0: 69 6f 6e 73 5c 26 2e 20 53 65 65 20 74 68 65 20 ions\&. See the
65e0: 5c 66 42 2d 63 61 64 69 72 5c 66 52 2c 20 5c 66 \fB-cadir\fR, \f
65f0: 42 2d 63 61 64 69 72 5c 66 52 2c 20 61 6e 64 0a B-cadir\fR, and.
6600: 5c 66 42 2d 63 61 73 74 6f 72 65 5c 66 52 20 6f \fB-castore\fR o
6610: 70 74 69 6f 6e 73 20 66 6f 72 20 68 6f 77 20 74 ptions for how t
6620: 70 20 73 70 65 63 69 66 79 20 77 68 65 72 65 20 p specify where
6630: 74 6f 20 66 69 6e 64 20 74 68 65 20 43 41 20 63 to find the CA c
6640: 65 72 74 69 66 69 63 61 74 65 73 5c 26 2e 0a 4f ertificates\&..O
6650: 70 74 69 6f 6e 61 6c 6c 79 2c 20 69 6e 20 61 20 ptionally, in a
6660: 66 75 74 75 72 65 20 72 65 6c 65 61 73 65 2c 20 future release,
6670: 74 68 65 79 20 63 61 6e 20 61 6c 73 6f 20 62 65 they can also be
6680: 20 63 68 65 63 6b 65 64 20 61 67 61 69 6e 73 74 checked against
6690: 20 74 68 65 20 43 65 72 74 69 66 69 63 61 74 65 the Certificate
66a0: 0a 52 65 76 6f 63 61 74 69 6f 6e 20 4c 69 73 74 .Revocation List
66b0: 20 28 43 52 4c 29 20 6f 66 20 72 65 76 6f 6b 65 (CRL) of revoke
66c0: 64 20 63 65 72 74 69 66 69 63 61 74 65 73 5c 26 d certificates\&
66d0: 2e 20 43 65 72 74 69 66 69 63 61 74 65 73 20 63 . Certificates c
66e0: 61 6e 20 61 6c 73 6f 20 62 65 0a 73 65 6c 66 2d an also be.self-
66f0: 73 69 67 6e 65 64 2c 20 62 75 74 20 74 68 65 79 signed, but they
6700: 20 61 72 65 20 62 79 20 64 65 66 61 75 6c 74 20 are by default
6710: 6e 6f 74 20 74 72 75 73 74 65 64 20 75 6e 6c 65 not trusted unle
6720: 73 73 20 79 6f 75 20 61 64 64 20 74 68 65 6d 20 ss you add them
6730: 74 6f 20 79 6f 75 72 0a 63 65 72 74 69 66 69 63 to your.certific
6740: 61 74 65 20 73 74 6f 72 65 5c 26 2e 0a 2e 50 50 ate store\&...PP
6750: 0a 54 79 70 69 63 61 6c 6c 79 20 77 68 65 6e 20 .Typically when
6760: 76 69 73 69 74 69 6e 67 20 77 65 62 20 73 69 74 visiting web sit
6770: 65 73 2c 20 6f 6e 6c 79 20 74 68 65 20 63 6c 69 es, only the cli
6780: 65 6e 74 20 6e 65 65 64 73 20 74 6f 20 63 68 65 ent needs to che
6790: 63 6b 20 74 68 65 20 73 65 72 76 65 72 27 73 0a ck the server's.
67a0: 63 65 72 74 69 66 69 63 61 74 65 20 74 6f 20 65 certificate to e
67b0: 6e 73 75 72 65 20 69 74 20 69 73 20 76 61 6c 69 nsure it is vali
67c0: 64 5c 26 2e 20 54 68 65 20 73 65 72 76 65 72 20 d\&. The server
67d0: 64 6f 65 73 6e 27 74 20 6e 65 65 64 20 74 6f 20 doesn't need to
67e0: 63 68 65 63 6b 20 74 68 65 20 63 6c 69 65 6e 74 check the client
67f0: 0a 63 65 72 74 69 66 69 63 61 74 65 20 75 6e 6c .certificate unl
6800: 65 73 73 20 79 6f 75 20 6e 65 65 64 20 74 6f 20 ess you need to
6810: 61 75 74 68 65 6e 74 69 63 61 74 65 20 77 69 74 authenticate wit
6820: 68 20 74 68 65 6d 20 74 6f 20 6c 6f 67 69 6e 2c h them to login,
6830: 20 65 74 63 5c 26 2e 20 53 65 65 20 74 68 65 0a etc\&. See the.
6840: 5c 66 42 2d 63 65 72 74 5c 66 52 20 61 6e 64 20 \fB-cert\fR and
6850: 5c 66 42 2d 63 65 72 74 66 69 6c 65 5c 66 52 20 \fB-certfile\fR
6860: 6f 70 74 69 6f 6e 73 20 69 66 20 79 6f 75 20 6e options if you n
6870: 65 65 64 20 74 6f 20 70 72 6f 76 69 64 65 20 61 eed to provide a
6880: 20 63 65 72 74 69 66 69 63 61 74 65 5c 26 2e 0a certificate\&..
6890: 2e 53 53 20 22 53 55 4d 4d 41 52 59 20 4f 46 20 .SS "SUMMARY OF
68a0: 43 4f 4d 4d 41 4e 44 20 4c 49 4e 45 20 4f 50 54 COMMAND LINE OPT
68b0: 49 4f 4e 53 22 0a 54 68 65 20 66 6f 6c 6c 6f 77 IONS".The follow
68c0: 69 6e 67 20 6f 70 74 69 6f 6e 73 20 61 72 65 20 ing options are
68d0: 75 73 65 64 20 66 6f 72 20 70 65 65 72 20 63 65 used for peer ce
68e0: 72 74 69 66 69 63 61 74 65 20 76 61 6c 69 64 61 rtificate valida
68f0: 74 69 6f 6e 3a 0a 2e 54 50 0a 5c 66 42 2d 63 61 tion:..TP.\fB-ca
6900: 64 69 72 5c 66 52 20 5c 66 49 64 69 72 65 63 74 dir\fR \fIdirect
6910: 6f 72 79 5c 66 52 0a 53 70 65 63 69 66 69 65 73 ory\fR.Specifies
6920: 20 74 68 65 20 64 69 72 65 63 74 6f 72 79 20 77 the directory w
6930: 68 65 72 65 20 74 68 65 20 43 65 72 74 69 66 69 here the Certifi
6940: 63 61 74 65 20 41 75 74 68 6f 72 69 74 79 20 28 cate Authority (
6950: 43 41 29 20 63 65 72 74 69 66 69 63 61 74 65 73 CA) certificates
6960: 20 61 72 65 0a 73 74 6f 72 65 64 5c 26 2e 20 54 are.stored\&. T
6970: 68 65 20 64 65 66 61 75 6c 74 20 69 73 20 70 6c he default is pl
6980: 61 74 66 6f 72 6d 20 73 70 65 63 69 66 69 63 2c atform specific,
6990: 20 62 75 74 20 69 73 20 75 73 75 61 6c 6c 79 20 but is usually
69a0: 22 5c 66 49 2f 65 74 63 2f 73 73 6c 2f 63 65 72 "\fI/etc/ssl/cer
69b0: 74 73 5c 66 52 22 20 6f 6e 0a 4c 69 6e 75 78 2f ts\fR" on.Linux/
69c0: 55 6e 69 78 20 73 79 73 74 65 6d 73 5c 26 2e 20 Unix systems\&.
69d0: 54 68 65 20 64 65 66 61 75 6c 74 20 6c 6f 63 61 The default loca
69e0: 74 69 6f 6e 20 63 61 6e 20 62 65 20 6f 76 65 72 tion can be over
69f0: 72 69 64 64 65 6e 20 62 79 20 74 68 65 0a 5c 66 ridden by the.\f
6a00: 42 53 53 4c 5f 43 45 52 54 5f 44 49 52 5c 66 52 BSSL_CERT_DIR\fR
6a10: 20 65 6e 76 69 72 6f 6e 6d 65 6e 74 20 76 61 72 environment var
6a20: 69 61 62 6c 65 5c 26 2e 0a 2e 54 50 0a 5c 66 42 iable\&...TP.\fB
6a30: 2d 63 61 66 69 6c 65 5c 66 52 20 5c 66 49 66 69 -cafile\fR \fIfi
6a40: 6c 65 6e 61 6d 65 5c 66 52 0a 53 70 65 63 69 66 lename\fR.Specif
6a50: 69 65 73 20 74 68 65 20 66 69 6c 65 20 77 69 74 ies the file wit
6a60: 68 20 74 68 65 20 43 65 72 74 69 66 69 63 61 74 h the Certificat
6a70: 65 20 41 75 74 68 6f 72 69 74 79 20 28 43 41 29 e Authority (CA)
6a80: 20 63 65 72 74 69 66 69 63 61 74 65 73 20 74 6f certificates to
6a90: 20 75 73 65 20 69 6e 0a 5c 66 42 50 45 4d 5c 66 use in.\fBPEM\f
6aa0: 52 20 66 69 6c 65 20 66 6f 72 6d 61 74 5c 26 2e R file format\&.
6ab0: 20 54 68 65 20 64 65 66 61 75 6c 74 20 69 73 20 The default is
6ac0: 22 5c 66 49 63 65 72 74 5c 26 2e 70 65 6d 5c 66 "\fIcert\&.pem\f
6ad0: 52 22 2c 20 69 6e 20 74 68 65 20 4f 70 65 6e 53 R", in the OpenS
6ae0: 53 4c 0a 64 69 72 65 63 74 6f 72 79 5c 26 2e 20 SL.directory\&.
6af0: 4f 6e 20 4c 69 6e 75 78 2f 55 6e 69 78 20 73 79 On Linux/Unix sy
6b00: 73 74 65 6d 73 2c 20 74 68 69 73 20 69 73 20 75 stems, this is u
6b10: 73 75 61 6c 6c 79 20 22 5c 66 49 2f 65 74 63 2f sually "\fI/etc/
6b20: 73 73 6c 2f 63 61 2d 62 75 6e 64 6c 65 5c 26 2e ssl/ca-bundle\&.
6b30: 70 65 6d 5c 66 52 22 5c 26 2e 0a 54 68 65 20 64 pem\fR"\&..The d
6b40: 65 66 61 75 6c 74 20 66 69 6c 65 20 63 61 6e 20 efault file can
6b50: 62 65 20 6f 76 65 72 72 69 64 64 65 6e 20 62 79 be overridden by
6b60: 20 74 68 65 20 5c 66 42 53 53 4c 5f 43 45 52 54 the \fBSSL_CERT
6b70: 5f 46 49 4c 45 5c 66 52 20 65 6e 76 69 72 6f 6e _FILE\fR environ
6b80: 6d 65 6e 74 0a 76 61 72 69 61 62 6c 65 5c 26 2e ment.variable\&.
6b90: 0a 2e 54 50 0a 5c 66 42 2d 63 61 73 74 6f 72 65 ..TP.\fB-castore
6ba0: 5c 66 52 20 5c 66 49 55 52 49 5c 66 52 0a 53 70 \fR \fIURI\fR.Sp
6bb0: 65 63 69 66 69 65 73 20 74 68 65 20 55 6e 69 66 ecifies the Unif
6bc0: 6f 72 6d 20 52 65 73 6f 75 72 63 65 20 49 64 65 orm Resource Ide
6bd0: 6e 74 69 66 69 65 72 20 28 55 52 49 29 20 66 6f ntifier (URI) fo
6be0: 72 20 74 68 65 20 43 65 72 74 69 66 69 63 61 74 r the Certificat
6bf0: 65 20 41 75 74 68 6f 72 69 74 79 0a 28 43 41 29 e Authority.(CA)
6c00: 20 73 74 6f 72 65 2c 20 77 68 69 63 68 20 6d 61 store, which ma
6c10: 79 20 62 65 20 61 20 73 69 6e 67 6c 65 20 63 6f y be a single co
6c20: 6e 74 61 69 6e 65 72 20 6f 72 20 61 20 63 61 74 ntainer or a cat
6c30: 61 6c 6f 67 20 6f 66 20 63 6f 6e 74 61 69 6e 65 alog of containe
6c40: 72 73 5c 26 2e 0a 53 74 61 72 74 69 6e 67 20 77 rs\&..Starting w
6c50: 69 74 68 20 4f 70 65 6e 53 53 4c 20 33 5c 26 2e ith OpenSSL 3\&.
6c60: 32 20 6f 6e 20 4d 53 20 57 69 6e 64 6f 77 73 2c 2 on MS Windows,
6c70: 20 73 65 74 20 74 6f 20 22 5c 66 42 6f 72 67 5c set to "\fBorg\
6c80: 26 2e 6f 70 65 6e 73 73 6c 5c 26 2e 77 69 6e 73 &.openssl\&.wins
6c90: 74 6f 72 65 3a 2f 2f 5c 66 52 22 0a 74 6f 20 75 tore://\fR".to u
6ca0: 73 65 20 74 68 65 20 62 75 69 6c 74 2d 69 6e 20 se the built-in
6cb0: 4d 53 20 57 69 6e 64 6f 77 73 20 43 65 72 74 69 MS Windows Certi
6cc0: 66 69 63 61 74 65 20 53 74 6f 72 65 5c 26 2e 0a ficate Store\&..
6cd0: 54 68 69 73 20 73 74 6f 72 65 20 6f 6e 6c 79 20 This store only
6ce0: 73 75 70 70 6f 72 74 73 20 72 6f 6f 74 20 63 65 supports root ce
6cf0: 72 74 69 66 69 63 61 74 65 20 73 74 6f 72 65 73 rtificate stores
6d00: 5c 26 2e 20 53 65 65 0a 5c 66 42 43 65 72 74 69 \&. See.\fBCerti
6d10: 66 69 63 61 74 65 20 56 61 6c 69 64 61 74 69 6f ficate Validatio
6d20: 6e 5c 66 52 20 66 6f 72 20 6d 6f 72 65 20 64 65 n\fR for more de
6d30: 74 61 69 6c 73 5c 26 2e 0a 2e 54 50 0a 5c 66 42 tails\&...TP.\fB
6d40: 2d 72 65 71 75 65 73 74 5c 66 52 20 5c 66 49 62 -request\fR \fIb
6d50: 6f 6f 6c 5c 66 52 0a 52 65 71 75 65 73 74 20 61 ool\fR.Request a
6d60: 20 63 65 72 74 69 66 69 63 61 74 65 20 66 72 6f certificate fro
6d70: 6d 20 74 68 65 20 70 65 65 72 20 64 75 72 69 6e m the peer durin
6d80: 67 20 74 68 65 20 53 53 4c 20 68 61 6e 64 73 68 g the SSL handsh
6d90: 61 6b 65 5c 26 2e 20 54 68 69 73 20 69 73 20 6e ake\&. This is n
6da0: 65 65 64 65 64 0a 74 6f 20 64 6f 20 43 65 72 74 eeded.to do Cert
6db0: 69 66 69 63 61 74 65 20 56 61 6c 69 64 61 74 69 ificate Validati
6dc0: 6f 6e 5c 26 2e 20 53 74 61 72 74 69 6e 67 20 69 on\&. Starting i
6dd0: 6e 20 54 63 6c 54 4c 53 20 31 5c 26 2e 38 2c 20 n TclTLS 1\&.8,
6de0: 74 68 65 20 64 65 66 61 75 6c 74 20 69 73 0a 5c the default is.\
6df0: 66 42 74 72 75 65 5c 66 52 5c 26 2e 20 53 74 61 fBtrue\fR\&. Sta
6e00: 72 74 69 6e 67 20 69 6e 20 54 63 6c 54 4c 53 20 rting in TclTLS
6e10: 32 5c 26 2e 30 2c 20 49 66 20 73 65 74 20 74 6f 2\&.0, If set to
6e20: 20 5c 66 42 66 61 6c 73 65 5c 66 52 20 61 6e 64 \fBfalse\fR and
6e30: 0a 5c 66 42 2d 72 65 71 75 69 72 65 5c 66 52 20 .\fB-require\fR
6e40: 69 73 20 5c 66 42 74 72 75 65 5c 66 52 2c 20 74 is \fBtrue\fR, t
6e50: 68 65 6e 20 74 68 69 73 20 77 69 6c 6c 20 62 65 hen this will be
6e60: 20 6f 76 65 72 72 69 64 64 65 6e 20 74 6f 20 5c overridden to \
6e70: 66 42 74 72 75 65 5c 66 52 5c 26 2e 0a 49 6e 20 fBtrue\fR\&..In
6e80: 61 64 64 69 74 69 6f 6e 2c 20 74 68 65 20 63 6c addition, the cl
6e90: 69 65 6e 74 20 63 61 6e 20 6d 61 6e 75 61 6c 6c ient can manuall
6ea0: 79 20 69 6e 73 70 65 63 74 20 61 6e 64 20 61 63 y inspect and ac
6eb0: 63 65 70 74 20 6f 72 20 72 65 6a 65 63 74 0a 65 cept or reject.e
6ec0: 61 63 68 20 63 65 72 74 69 66 69 63 61 74 65 20 ach certificate
6ed0: 75 73 69 6e 67 20 74 68 65 20 5c 66 49 2d 76 61 using the \fI-va
6ee0: 6c 69 64 61 74 65 63 6f 6d 6d 61 6e 64 5c 66 52 lidatecommand\fR
6ef0: 20 6f 70 74 69 6f 6e 5c 26 2e 0a 2e 54 50 0a 5c option\&...TP.\
6f00: 66 42 2d 72 65 71 75 69 72 65 5c 66 52 20 5c 66 fB-require\fR \f
6f10: 49 62 6f 6f 6c 5c 66 52 0a 52 65 71 75 69 72 65 Ibool\fR.Require
6f20: 20 61 20 76 61 6c 69 64 20 63 65 72 74 69 66 69 a valid certifi
6f30: 63 61 74 65 20 66 72 6f 6d 20 74 68 65 20 70 65 cate from the pe
6f40: 65 72 20 64 75 72 69 6e 67 20 74 68 65 20 53 53 er during the SS
6f50: 4c 20 68 61 6e 64 73 68 61 6b 65 5c 26 2e 20 49 L handshake\&. I
6f60: 66 20 74 68 69 73 20 69 73 0a 73 65 74 20 74 6f f this is.set to
6f70: 20 74 72 75 65 2c 20 74 68 65 6e 20 5c 66 42 2d true, then \fB-
6f80: 72 65 71 75 65 73 74 5c 66 52 20 6d 75 73 74 20 request\fR must
6f90: 61 6c 73 6f 20 62 65 20 73 65 74 20 74 6f 20 74 also be set to t
6fa0: 72 75 65 20 61 6e 64 20 61 20 65 69 74 68 65 72 rue and a either
6fb0: 0a 5c 66 42 2d 63 61 64 69 72 5c 66 52 2c 20 5c .\fB-cadir\fR, \
6fc0: 66 42 2d 63 61 66 69 6c 65 5c 66 52 2c 20 5c 66 fB-cafile\fR, \f
6fd0: 42 2d 63 61 73 74 6f 72 65 5c 66 52 2c 20 6f 72 B-castore\fR, or
6fe0: 20 61 20 70 6c 61 74 66 6f 72 6d 20 64 65 66 61 a platform defa
6ff0: 75 6c 74 0a 6d 75 73 74 20 62 65 20 70 72 6f 76 ult.must be prov
7000: 69 64 65 64 20 69 6e 20 6f 72 64 65 72 20 74 6f ided in order to
7010: 20 76 61 6c 69 64 61 74 65 20 61 67 61 69 6e 73 validate agains
7020: 74 5c 26 2e 20 54 68 65 20 64 65 66 61 75 6c 74 t\&. The default
7030: 20 69 6e 20 54 63 6c 54 4c 53 20 31 5c 26 2e 38 in TclTLS 1\&.8
7040: 20 61 6e 64 0a 65 61 72 6c 69 65 72 20 76 65 72 and.earlier ver
7050: 73 69 6f 6e 73 20 69 73 20 5c 66 42 66 61 6c 73 sions is \fBfals
7060: 65 5c 66 52 20 73 69 6e 63 65 20 6e 6f 74 20 61 e\fR since not a
7070: 6c 6c 20 70 6c 61 74 66 6f 72 6d 73 20 68 61 76 ll platforms hav
7080: 65 20 63 65 72 74 69 66 69 63 61 74 65 73 20 74 e certificates t
7090: 6f 0a 76 61 6c 69 64 61 74 65 20 61 67 61 69 6e o.validate again
70a0: 73 74 20 69 6e 20 61 20 66 6f 72 6d 20 63 6f 6d st in a form com
70b0: 70 61 74 69 62 6c 65 20 77 69 74 68 20 4f 70 65 patible with Ope
70c0: 6e 53 53 4c 5c 26 2e 20 53 74 61 72 74 69 6e 67 nSSL\&. Starting
70d0: 20 69 6e 20 54 63 6c 54 4c 53 20 32 5c 26 2e 30 in TclTLS 2\&.0
70e0: 2c 0a 74 68 65 20 64 65 66 61 75 6c 74 20 69 73 ,.the default is
70f0: 20 5c 66 42 74 72 75 65 5c 66 52 5c 26 2e 0a 2e \fBtrue\fR\&...
7100: 50 50 0a 2e 53 53 20 22 57 48 45 4e 20 41 52 45 PP..SS "WHEN ARE
7110: 20 43 4f 4d 4d 41 4e 44 20 4c 49 4e 45 20 4f 50 COMMAND LINE OP
7120: 54 49 4f 4e 53 20 4e 45 45 44 45 44 3f 22 0a 49 TIONS NEEDED?".I
7130: 6e 20 54 63 6c 54 4c 53 20 31 5c 26 2e 38 20 61 n TclTLS 1\&.8 a
7140: 6e 64 20 65 61 72 6c 69 65 72 20 76 65 72 73 69 nd earlier versi
7150: 6f 6e 73 2c 20 63 65 72 74 69 66 69 63 61 74 65 ons, certificate
7160: 20 76 61 6c 69 64 61 74 69 6f 6e 20 69 73 0a 5c validation is.\
7170: 66 49 4e 4f 54 5c 66 52 20 65 6e 61 62 6c 65 64 fINOT\fR enabled
7180: 20 62 79 20 64 65 66 61 75 6c 74 5c 26 2e 20 54 by default\&. T
7190: 68 69 73 20 6c 69 6d 69 74 61 74 69 6f 6e 20 69 his limitation i
71a0: 73 20 64 75 65 20 74 6f 20 74 68 65 20 6c 61 63 s due to the lac
71b0: 6b 20 6f 66 20 61 20 63 6f 6d 6d 6f 6e 0a 63 72 k of a common.cr
71c0: 6f 73 73 20 70 6c 61 74 66 6f 72 6d 20 64 61 74 oss platform dat
71d0: 61 62 61 73 65 20 6f 66 20 43 65 72 74 69 66 69 abase of Certifi
71e0: 63 61 74 65 20 41 75 74 68 6f 72 69 74 79 20 28 cate Authority (
71f0: 43 41 29 20 70 72 6f 76 69 64 65 64 20 63 65 72 CA) provided cer
7200: 74 69 66 69 63 61 74 65 73 20 74 6f 0a 76 61 6c tificates to.val
7210: 69 64 61 74 65 20 61 67 61 69 6e 73 74 5c 26 2e idate against\&.
7220: 20 4d 61 6e 79 20 4c 69 6e 75 78 20 73 79 73 74 Many Linux syst
7230: 65 6d 73 20 6e 61 74 69 76 65 6c 79 20 73 75 70 ems natively sup
7240: 70 6f 72 74 20 4f 70 65 6e 53 53 4c 20 61 6e 64 port OpenSSL and
7250: 20 74 68 75 73 20 68 61 76 65 0a 74 68 65 73 65 thus have.these
7260: 20 63 65 72 74 69 66 69 63 61 74 65 73 20 69 6e certificates in
7270: 73 74 61 6c 6c 65 64 20 61 73 20 70 61 72 74 20 stalled as part
7280: 6f 66 20 74 68 65 20 4f 53 2c 20 62 75 74 20 4d of the OS, but M
7290: 61 63 4f 53 20 61 6e 64 20 4d 53 20 57 69 6e 64 acOS and MS Wind
72a0: 6f 77 73 20 64 6f 20 6e 6f 74 5c 26 2e 0a 53 74 ows do not\&..St
72b0: 61 72 69 6e 67 20 69 6e 20 54 63 6c 54 4c 53 20 aring in TclTLS
72c0: 32 5c 26 2e 30 2c 20 74 68 69 73 20 68 61 73 20 2\&.0, this has
72d0: 62 65 65 6e 20 63 68 61 6e 67 65 64 20 74 6f 20 been changed to
72e0: 72 65 71 75 69 72 65 20 63 65 72 74 69 66 69 63 require certific
72f0: 61 74 65 20 76 61 6c 69 64 61 74 69 6f 6e 0a 62 ate validation.b
7300: 79 20 64 65 66 61 75 6c 74 5c 26 2e 20 49 6e 20 y default\&. In
7310: 6f 72 64 65 72 20 74 6f 20 75 73 65 20 74 68 65 order to use the
7320: 20 5c 66 42 2d 72 65 71 75 69 72 65 5c 66 52 20 \fB-require\fR
7330: 6f 70 74 69 6f 6e 2c 20 6f 6e 65 20 6f 66 20 74 option, one of t
7340: 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 0a 6d 75 73 he following.mus
7350: 74 20 62 65 20 74 72 75 65 3a 0a 2e 49 50 20 5c t be true:..IP \
7360: 28 62 75 0a 4f 6e 20 4c 69 6e 75 78 20 61 6e 64 (bu.On Linux and
7370: 20 55 6e 69 78 20 73 79 73 74 65 6d 73 20 77 69 Unix systems wi
7380: 74 68 20 4f 70 65 6e 53 53 4c 20 61 6c 72 65 61 th OpenSSL alrea
7390: 64 79 20 69 6e 73 74 61 6c 6c 65 64 20 6f 72 20 dy installed or
73a0: 69 66 20 74 68 65 20 43 41 0a 63 65 72 74 69 66 if the CA.certif
73b0: 69 63 61 74 65 73 20 61 72 65 20 61 76 61 69 6c icates are avail
73c0: 61 62 6c 65 20 69 6e 20 50 45 4d 20 66 6f 72 6d able in PEM form
73d0: 61 74 2c 20 61 6e 64 20 69 66 20 74 68 65 79 20 at, and if they
73e0: 61 72 65 20 73 74 6f 72 65 64 20 69 6e 20 74 68 are stored in th
73f0: 65 0a 73 74 61 6e 64 61 72 64 20 6c 6f 63 61 74 e.standard locat
7400: 69 6f 6e 73 2c 20 6f 72 20 69 66 20 74 68 65 20 ions, or if the
7410: 5c 66 42 53 53 4c 5f 43 45 52 54 5f 44 49 52 5c \fBSSL_CERT_DIR\
7420: 66 52 20 6f 72 20 5c 66 42 53 53 4c 5f 43 45 52 fR or \fBSSL_CER
7430: 54 5f 46 49 4c 45 5c 66 52 0a 65 6e 76 69 72 6f T_FILE\fR.enviro
7440: 6e 6d 65 6e 74 20 76 61 72 69 61 62 6c 65 73 20 nment variables
7450: 61 72 65 20 73 65 74 2c 20 74 68 65 6e 20 5c 66 are set, then \f
7460: 42 2d 63 61 64 69 72 5c 66 52 2c 20 5c 66 42 2d B-cadir\fR, \fB-
7470: 63 61 64 69 72 5c 66 52 2c 0a 61 6e 64 20 5c 66 cadir\fR,.and \f
7480: 42 2d 63 61 73 74 6f 72 65 5c 66 52 20 61 72 65 B-castore\fR are
7490: 6e 27 74 20 6e 65 65 64 65 64 5c 26 2e 0a 2e 49 n't needed\&...I
74a0: 50 20 5c 28 62 75 0a 49 66 20 4f 70 65 6e 53 53 P \(bu.If OpenSS
74b0: 4c 20 69 73 20 6e 6f 74 20 69 6e 73 74 61 6c 6c L is not install
74c0: 65 64 20 69 6e 20 74 68 65 20 64 65 66 61 75 6c ed in the defaul
74d0: 74 20 6c 6f 63 61 74 69 6f 6e 2c 20 6f 72 20 77 t location, or w
74e0: 68 65 6e 20 75 73 69 6e 67 20 4d 61 63 20 4f 53 hen using Mac OS
74f0: 0a 6f 72 20 4d 53 20 57 69 6e 64 6f 77 73 20 61 .or MS Windows a
7500: 6e 64 20 4f 70 65 6e 53 53 4c 20 69 73 20 69 6e nd OpenSSL is in
7510: 73 74 61 6c 6c 65 64 2c 20 74 68 65 20 5c 66 42 stalled, the \fB
7520: 53 53 4c 5f 43 45 52 54 5f 44 49 52 5c 66 52 20 SSL_CERT_DIR\fR
7530: 61 6e 64 2f 6f 72 0a 5c 66 42 53 53 4c 5f 43 45 and/or.\fBSSL_CE
7540: 52 54 5f 46 49 4c 45 5c 66 52 20 65 6e 76 69 72 RT_FILE\fR envir
7550: 6f 6e 6d 65 6e 74 20 76 61 72 69 61 62 6c 65 73 onment variables
7560: 20 6f 72 20 74 68 65 20 6f 6e 65 20 6f 66 20 74 or the one of t
7570: 68 65 20 5c 66 42 2d 63 61 64 69 72 5c 66 52 2c he \fB-cadir\fR,
7580: 0a 5c 66 42 2d 63 61 64 69 72 5c 66 52 2c 20 6f .\fB-cadir\fR, o
7590: 72 20 5c 66 42 2d 63 61 73 74 6f 72 65 5c 66 52 r \fB-castore\fR
75a0: 20 6f 70 74 69 6f 6e 73 20 6d 75 73 74 20 62 65 options must be
75b0: 20 64 65 66 69 6e 65 64 5c 26 2e 0a 2e 49 50 20 defined\&...IP
75c0: 5c 28 62 75 0a 4f 6e 20 4d 53 20 57 69 6e 64 6f \(bu.On MS Windo
75d0: 77 73 2c 20 73 74 61 72 74 69 6e 67 20 69 6e 20 ws, starting in
75e0: 4f 70 65 6e 53 53 4c 20 33 5c 26 2e 32 2c 20 69 OpenSSL 3\&.2, i
75f0: 74 20 69 73 20 6e 6f 77 20 70 6f 73 73 69 62 6c t is now possibl
7600: 65 20 74 6f 20 61 63 63 65 73 73 20 74 68 65 0a e to access the.
7610: 62 75 69 6c 74 2d 69 6e 20 57 69 6e 64 6f 77 73 built-in Windows
7620: 20 43 65 72 74 69 66 69 63 61 74 65 20 53 74 6f Certificate Sto
7630: 72 65 20 66 72 6f 6d 20 4f 70 65 6e 53 53 4c 5c re from OpenSSL\
7640: 26 2e 20 54 68 69 73 20 63 61 6e 20 75 74 69 6c &. This can util
7650: 69 7a 65 64 20 62 79 0a 73 65 74 74 69 6e 67 20 ized by.setting
7660: 74 68 65 20 5c 66 42 2d 63 61 73 74 6f 72 65 5c the \fB-castore\
7670: 66 52 20 6f 70 74 69 6f 6e 20 74 6f 20 22 5c 66 fR option to "\f
7680: 42 6f 72 67 5c 26 2e 6f 70 65 6e 73 73 6c 5c 26 Borg\&.openssl\&
7690: 2e 77 69 6e 73 74 6f 72 65 3a 2f 2f 5c 66 52 22 .winstore://\fR"
76a0: 5c 26 2e 0a 2e 49 50 20 5c 28 62 75 0a 49 66 20 \&...IP \(bu.If
76b0: 4f 70 65 6e 53 53 4c 20 69 73 20 6e 6f 74 20 69 OpenSSL is not i
76c0: 6e 73 74 61 6c 6c 65 64 20 6f 72 20 74 68 65 20 nstalled or the
76d0: 43 41 20 63 65 72 74 69 66 69 63 61 74 65 73 20 CA certificates
76e0: 61 72 65 20 6e 6f 74 20 61 76 61 69 6c 61 62 6c are not availabl
76f0: 65 20 69 6e 20 50 45 4d 0a 66 6f 72 6d 61 74 2c e in PEM.format,
7700: 20 74 68 65 20 43 41 20 63 65 72 74 69 66 69 63 the CA certific
7710: 61 74 65 73 20 6d 75 73 74 20 62 65 20 64 6f 77 ates must be dow
7720: 6e 6c 6f 61 64 65 64 20 61 6e 64 20 69 6e 73 74 nloaded and inst
7730: 61 6c 6c 65 64 20 77 69 74 68 20 74 68 65 20 75 alled with the u
7740: 73 65 72 0a 73 6f 66 74 77 61 72 65 5c 26 2e 20 ser.software\&.
7750: 54 68 65 20 43 55 52 4c 20 74 65 61 6d 20 6d 61 The CURL team ma
7760: 6b 65 73 20 74 68 65 6d 20 61 76 61 69 6c 61 62 kes them availab
7770: 6c 65 20 61 74 0a 5c 66 49 43 41 20 63 65 72 74 le at.\fICA cert
7780: 69 66 69 63 61 74 65 73 20 65 78 74 72 61 63 74 ificates extract
7790: 65 64 0a 66 72 6f 6d 20 4d 6f 7a 69 6c 6c 61 5c ed.from Mozilla\
77a0: 66 52 20 5b 68 74 74 70 73 3a 2f 2f 63 75 72 6c fR [https://curl
77b0: 5c 26 2e 73 65 2f 64 6f 63 73 2f 63 61 65 78 74 \&.se/docs/caext
77c0: 72 61 63 74 5c 26 2e 68 74 6d 6c 5d 20 69 6e 20 ract\&.html] in
77d0: 74 68 65 20 22 5c 66 49 63 61 63 65 72 74 5c 26 the "\fIcacert\&
77e0: 2e 70 65 6d 5c 66 52 22 20 66 69 6c 65 5c 26 2e .pem\fR" file\&.
77f0: 20 59 6f 75 20 6d 75 73 74 20 74 68 65 6e 20 65 You must then e
7800: 69 74 68 65 72 20 73 65 74 20 74 68 65 0a 5c 66 ither set the.\f
7810: 42 53 53 4c 5f 43 45 52 54 5f 44 49 52 5c 66 52 BSSL_CERT_DIR\fR
7820: 20 61 6e 64 2f 6f 72 20 5c 66 42 53 53 4c 5f 43 and/or \fBSSL_C
7830: 45 52 54 5f 46 49 4c 45 5c 66 52 20 65 6e 76 69 ERT_FILE\fR envi
7840: 72 6f 6e 6d 65 6e 74 20 76 61 72 69 61 62 6c 65 ronment variable
7850: 73 20 6f 72 20 74 68 65 0a 5c 66 42 2d 63 61 64 s or the.\fB-cad
7860: 69 72 5c 66 52 20 6f 72 20 5c 66 42 2d 63 61 66 ir\fR or \fB-caf
7870: 69 6c 65 5c 66 52 20 6f 70 74 69 6f 6e 73 20 74 ile\fR options t
7880: 6f 20 74 68 65 20 43 41 20 63 65 72 74 20 66 69 o the CA cert fi
7890: 6c 65 27 73 20 69 6e 73 74 61 6c 6c 0a 6c 6f 63 le's install.loc
78a0: 61 74 69 6f 6e 5c 26 2e 20 49 74 20 69 73 20 79 ation\&. It is y
78b0: 6f 75 72 20 72 65 73 70 6f 6e 73 69 62 69 6c 69 our responsibili
78c0: 74 79 20 74 6f 20 6b 65 65 70 20 74 68 69 73 20 ty to keep this
78d0: 66 69 6c 65 20 75 70 20 74 6f 20 64 61 74 65 5c file up to date\
78e0: 26 2e 0a 2e 50 50 0a 2e 53 48 20 22 43 41 4c 4c &...PP..SH "CALL
78f0: 42 41 43 4b 20 4f 50 54 49 4f 4e 53 22 0a 41 73 BACK OPTIONS".As
7900: 20 70 72 65 76 69 6f 75 73 6c 79 20 64 65 73 63 previously desc
7910: 72 69 62 65 64 2c 20 65 61 63 68 20 63 68 61 6e ribed, each chan
7920: 6e 65 6c 20 63 61 6e 20 62 65 20 67 69 76 65 6e nel can be given
7930: 20 74 68 65 69 72 20 6f 77 6e 20 63 61 6c 6c 62 their own callb
7940: 61 63 6b 73 0a 74 6f 20 68 61 6e 64 6c 65 20 69 acks.to handle i
7950: 6e 74 65 72 6d 65 64 69 61 74 65 20 70 72 6f 63 ntermediate proc
7960: 65 73 73 69 6e 67 20 62 79 20 74 68 65 20 4f 70 essing by the Op
7970: 65 6e 53 53 4c 20 6c 69 62 72 61 72 79 2c 20 75 enSSL library, u
7980: 73 69 6e 67 20 74 68 65 0a 5c 66 42 2d 63 6f 6d sing the.\fB-com
7990: 6d 61 6e 64 5c 66 52 2c 20 5c 66 42 2d 70 61 73 mand\fR, \fB-pas
79a0: 73 77 6f 72 64 5c 66 52 2c 20 61 6e 64 20 5c 66 sword\fR, and \f
79b0: 42 2d 76 61 6c 69 64 61 74 65 5f 63 6f 6d 6d 61 B-validate_comma
79c0: 6e 64 5c 66 52 20 6f 70 74 69 6f 6e 73 0a 70 61 nd\fR options.pa
79d0: 73 73 65 64 20 74 6f 20 65 69 74 68 65 72 20 6f ssed to either o
79e0: 66 20 5c 66 42 74 6c 73 3a 3a 73 6f 63 6b 65 74 f \fBtls::socket
79f0: 5c 66 52 20 6f 72 20 5c 66 42 74 6c 73 3a 3a 69 \fR or \fBtls::i
7a00: 6d 70 6f 72 74 5c 66 52 5c 26 2e 0a 55 6e 6c 69 mport\fR\&..Unli
7a10: 6b 65 20 70 72 65 76 69 6f 75 73 20 76 65 72 73 ke previous vers
7a20: 69 6f 6e 73 20 6f 66 20 54 63 6c 54 4c 53 2c 20 ions of TclTLS,
7a30: 6f 6e 6c 79 20 69 66 20 74 68 65 20 63 61 6c 6c only if the call
7a40: 62 61 63 6b 20 67 65 6e 65 72 61 74 65 73 20 61 back generates a
7a50: 6e 20 65 72 72 6f 72 2c 0a 77 69 6c 6c 20 74 68 n error,.will th
7a60: 65 20 5c 66 42 62 67 65 72 72 6f 72 5c 66 52 20 e \fBbgerror\fR
7a70: 63 6f 6d 6d 61 6e 64 20 62 65 20 69 6e 76 6f 6b command be invok
7a80: 65 64 20 77 69 74 68 20 74 68 65 20 65 72 72 6f ed with the erro
7a90: 72 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 5c 26 2e r information\&.
7aa0: 0a 2e 53 53 20 22 56 41 4c 55 45 53 20 46 4f 52 ..SS "VALUES FOR
7ab0: 20 43 4f 4d 4d 41 4e 44 20 43 41 4c 4c 42 41 43 COMMAND CALLBAC
7ac0: 4b 22 0a 54 68 65 20 63 61 6c 6c 62 61 63 6b 20 K".The callback
7ad0: 66 6f 72 20 74 68 65 20 5c 66 42 2d 63 6f 6d 6d for the \fB-comm
7ae0: 61 6e 64 5c 66 52 20 6f 70 74 69 6f 6e 20 69 73 and\fR option is
7af0: 20 69 6e 76 6f 6b 65 64 20 61 74 20 73 65 76 65 invoked at seve
7b00: 72 61 6c 20 70 6f 69 6e 74 73 20 64 75 72 69 6e ral points durin
7b10: 67 20 74 68 65 0a 4f 70 65 6e 53 53 4c 20 68 61 g the.OpenSSL ha
7b20: 6e 64 73 68 61 6b 65 20 61 6e 64 20 64 75 72 69 ndshake and duri
7b30: 6e 67 20 72 6f 75 74 69 6e 65 20 6f 70 65 72 61 ng routine opera
7b40: 74 69 6f 6e 73 5c 26 2e 20 53 65 65 20 62 65 6c tions\&. See bel
7b50: 6f 77 20 66 6f 72 20 74 68 65 20 70 6f 73 73 69 ow for the possi
7b60: 62 6c 65 0a 61 72 67 75 6d 65 6e 74 73 20 70 61 ble.arguments pa
7b70: 73 73 65 64 20 74 6f 20 74 68 65 20 63 61 6c 6c ssed to the call
7b80: 62 61 63 6b 20 73 63 72 69 70 74 5c 26 2e 20 56 back script\&. V
7b90: 61 6c 75 65 73 20 72 65 74 75 72 6e 65 64 20 66 alues returned f
7ba0: 72 6f 6d 20 74 68 65 20 63 61 6c 6c 62 61 63 6b rom the callback
7bb0: 20 61 72 65 0a 69 67 6e 6f 72 65 64 5c 26 2e 0a are.ignored\&..
7bc0: 2e 54 50 0a 5c 66 42 65 72 72 6f 72 5c 66 52 20 .TP.\fBerror\fR
7bd0: 5c 66 49 63 68 61 6e 6e 65 6c 49 64 20 6d 65 73 \fIchannelId mes
7be0: 73 61 67 65 5c 66 52 0a 54 68 69 73 20 66 6f 72 sage\fR.This for
7bf0: 6d 20 6f 66 20 63 61 6c 6c 62 61 63 6b 20 69 73 m of callback is
7c00: 20 69 6e 76 6f 6b 65 64 20 77 68 65 6e 65 76 65 invoked wheneve
7c10: 72 20 61 6e 20 65 72 72 6f 72 20 6f 63 63 75 72 r an error occur
7c20: 73 20 64 75 72 69 6e 67 20 74 68 65 20 69 6e 69 s during the ini
7c30: 74 69 61 6c 0a 63 6f 6e 6e 65 63 74 69 6f 6e 2c tial.connection,
7c40: 20 68 61 6e 64 73 68 61 6b 65 2c 20 6f 72 20 49 handshake, or I
7c50: 2f 4f 20 6f 70 65 72 61 74 69 6f 6e 73 5c 26 2e /O operations\&.
7c60: 20 54 68 65 20 5c 66 49 6d 65 73 73 61 67 65 5c The \fImessage\
7c70: 66 52 20 61 72 67 75 6d 65 6e 74 20 63 61 6e 20 fR argument can
7c80: 62 65 0a 66 72 6f 6d 20 74 68 65 20 54 63 6c 5f be.from the Tcl_
7c90: 45 72 72 6e 6f 4d 73 67 2c 20 4f 70 65 6e 53 53 ErrnoMsg, OpenSS
7ca0: 4c 20 66 75 6e 63 74 69 6f 6e 20 5c 66 42 45 52 L function \fBER
7cb0: 52 5f 72 65 61 73 6f 6e 5f 65 72 72 6f 72 5f 73 R_reason_error_s
7cc0: 74 72 69 6e 67 28 29 5c 66 52 2c 0a 6f 72 20 61 tring()\fR,.or a
7cd0: 20 63 75 73 74 6f 6d 20 6d 65 73 73 61 67 65 5c custom message\
7ce0: 26 2e 20 54 68 69 73 20 63 61 6c 6c 62 61 63 6b &. This callback
7cf0: 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54 is new for TclT
7d00: 4c 53 20 31 5c 26 2e 38 5c 26 2e 0a 2e 54 50 0a LS 1\&.8\&...TP.
7d10: 5c 66 42 69 6e 66 6f 5c 66 52 20 5c 66 49 63 68 \fBinfo\fR \fIch
7d20: 61 6e 6e 65 6c 49 64 20 6d 61 6a 6f 72 20 6d 69 annelId major mi
7d30: 6e 6f 72 20 6d 65 73 73 61 67 65 20 74 79 70 65 nor message type
7d40: 5c 66 52 0a 54 68 69 73 20 66 6f 72 6d 20 6f 66 \fR.This form of
7d50: 20 63 61 6c 6c 62 61 63 6b 20 69 73 20 69 6e 76 callback is inv
7d60: 6f 6b 65 64 20 62 79 20 74 68 65 20 4f 70 65 6e oked by the Open
7d70: 53 53 4c 20 66 75 6e 63 74 69 6f 6e 0a 5c 66 42 SSL function.\fB
7d80: 53 53 4c 5f 73 65 74 5f 69 6e 66 6f 5f 63 61 6c SSL_set_info_cal
7d90: 6c 62 61 63 6b 28 29 5c 66 52 20 64 75 72 69 6e lback()\fR durin
7da0: 67 20 74 68 65 20 69 6e 69 74 69 61 6c 20 63 6f g the initial co
7db0: 6e 6e 65 63 74 69 6f 6e 20 61 6e 64 20 68 61 6e nnection and han
7dc0: 64 73 68 61 6b 65 0a 6f 70 65 72 61 74 69 6f 6e dshake.operation
7dd0: 73 5c 26 2e 20 54 68 65 20 61 72 67 75 6d 65 6e s\&. The argumen
7de0: 74 73 20 61 72 65 3a 0a 2e 52 53 0a 2e 54 50 0a ts are:..RS..TP.
7df0: 5c 66 49 6d 61 6a 6f 72 5c 66 52 0a 4d 61 6a 6f \fImajor\fR.Majo
7e00: 72 20 63 61 74 65 67 6f 72 79 20 66 6f 72 20 65 r category for e
7e10: 72 72 6f 72 5c 26 2e 20 56 61 6c 69 64 20 65 6e rror\&. Valid en
7e20: 75 6d 73 20 61 72 65 3a 20 5c 66 42 68 61 6e 64 ums are: \fBhand
7e30: 73 68 61 6b 65 5c 66 52 2c 20 5c 66 42 61 6c 65 shake\fR, \fBale
7e40: 72 74 5c 66 52 2c 0a 5c 66 42 63 6f 6e 6e 65 63 rt\fR,.\fBconnec
7e50: 74 5c 66 52 2c 20 5c 66 42 61 63 63 65 70 74 5c t\fR, \fBaccept\
7e60: 66 52 5c 26 2e 0a 2e 54 50 0a 5c 66 49 6d 69 6e fR\&...TP.\fImin
7e70: 6f 72 5c 66 52 0a 4d 69 6e 6f 72 20 63 61 74 65 or\fR.Minor cate
7e80: 67 6f 72 79 20 66 6f 72 20 65 72 72 6f 72 5c 26 gory for error\&
7e90: 2e 20 56 61 6c 69 64 20 65 6e 75 6d 73 20 61 72 . Valid enums ar
7ea0: 65 3a 20 5c 66 42 73 74 61 72 74 5c 66 52 2c 20 e: \fBstart\fR,
7eb0: 5c 66 42 64 6f 6e 65 5c 66 52 2c 20 5c 66 42 72 \fBdone\fR, \fBr
7ec0: 65 61 64 5c 66 52 2c 0a 5c 66 42 77 72 69 74 65 ead\fR,.\fBwrite
7ed0: 5c 66 52 2c 20 5c 66 42 6c 6f 6f 70 5c 66 52 2c \fR, \fBloop\fR,
7ee0: 20 5c 66 42 65 78 69 74 5c 66 52 5c 26 2e 0a 2e \fBexit\fR\&...
7ef0: 54 50 0a 5c 66 49 6d 65 73 73 61 67 65 5c 66 52 TP.\fImessage\fR
7f00: 0a 44 65 73 63 72 69 70 74 69 76 65 20 6d 65 73 .Descriptive mes
7f10: 73 61 67 65 20 73 74 72 69 6e 67 20 77 68 69 63 sage string whic
7f20: 68 20 6d 61 79 20 62 65 20 67 65 6e 65 72 61 74 h may be generat
7f30: 65 64 20 65 69 74 68 65 72 20 62 79 0a 5c 66 42 ed either by.\fB
7f40: 53 53 4c 5f 73 74 61 74 65 5f 73 74 72 69 6e 67 SSL_state_string
7f50: 5f 6c 6f 6e 67 28 29 5c 66 52 20 6f 72 20 5c 66 _long()\fR or \f
7f60: 42 53 53 4c 5f 61 6c 65 72 74 5f 64 65 73 63 5f BSSL_alert_desc_
7f70: 73 74 72 69 6e 67 5f 6c 6f 6e 67 28 29 5c 66 52 string_long()\fR
7f80: 2c 0a 64 65 70 65 6e 64 69 6e 67 20 6f 6e 20 74 ,.depending on t
7f90: 68 65 20 63 6f 6e 74 65 78 74 5c 26 2e 0a 2e 54 he context\&...T
7fa0: 50 0a 5c 66 49 74 79 70 65 5c 66 52 0a 46 6f 72 P.\fItype\fR.For
7fb0: 20 61 6c 65 72 74 73 2c 20 74 68 65 20 70 6f 73 alerts, the pos
7fc0: 73 69 62 6c 65 20 76 61 6c 75 65 73 20 61 72 65 sible values are
7fd0: 3a 20 5c 66 42 77 61 72 6e 69 6e 67 5c 66 52 2c : \fBwarning\fR,
7fe0: 0a 5c 66 42 66 61 74 61 6c 5c 66 52 2c 20 61 6e .\fBfatal\fR, an
7ff0: 64 20 5c 66 42 75 6e 6b 6e 6f 77 6e 5c 66 52 5c d \fBunknown\fR\
8000: 26 2e 20 46 6f 72 20 6f 74 68 65 72 73 2c 20 5c &. For others, \
8010: 66 42 69 6e 66 6f 5c 66 52 20 69 73 20 75 73 65 fBinfo\fR is use
8020: 64 5c 26 2e 0a 54 68 69 73 20 61 72 67 75 6d 65 d\&..This argume
8030: 6e 74 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 nt is new for Tc
8040: 6c 54 4c 53 20 31 5c 26 2e 38 5c 26 2e 0a 2e 52 lTLS 1\&.8\&...R
8050: 45 0a 2e 54 50 0a 5c 66 42 6d 65 73 73 61 67 65 E..TP.\fBmessage
8060: 5c 66 52 20 5c 66 49 63 68 61 6e 6e 65 6c 49 64 \fR \fIchannelId
8070: 20 64 69 72 65 63 74 69 6f 6e 20 76 65 72 73 69 direction versi
8080: 6f 6e 20 63 6f 6e 74 65 6e 74 5f 74 79 70 65 20 on content_type
8090: 6d 65 73 73 61 67 65 5c 66 52 0a 54 68 69 73 20 message\fR.This
80a0: 66 6f 72 6d 20 6f 66 20 63 61 6c 6c 62 61 63 6b form of callback
80b0: 20 69 73 20 69 6e 76 6f 6b 65 64 20 62 79 20 74 is invoked by t
80c0: 68 65 20 4f 70 65 6e 53 53 4c 20 66 75 6e 63 74 he OpenSSL funct
80d0: 69 6f 6e 0a 5c 66 42 53 53 4c 5f 73 65 74 5f 6d ion.\fBSSL_set_m
80e0: 73 67 5f 63 61 6c 6c 62 61 63 6b 28 29 5c 66 52 sg_callback()\fR
80f0: 20 77 68 65 6e 65 76 65 72 20 61 20 6d 65 73 73 whenever a mess
8100: 61 67 65 20 69 73 20 73 65 6e 74 20 6f 72 20 72 age is sent or r
8110: 65 63 65 69 76 65 64 20 64 75 72 69 6e 67 20 74 eceived during t
8120: 68 65 0a 69 6e 69 74 69 61 6c 20 63 6f 6e 6e 65 he.initial conne
8130: 63 74 69 6f 6e 2c 20 68 61 6e 64 73 68 61 6b 65 ction, handshake
8140: 2c 20 6f 72 20 49 2f 4f 20 6f 70 65 72 61 74 69 , or I/O operati
8150: 6f 6e 73 5c 26 2e 20 49 74 20 69 73 20 6f 6e 6c ons\&. It is onl
8160: 79 20 61 76 61 69 6c 61 62 6c 65 20 77 68 65 6e y available when
8170: 0a 4f 70 65 6e 53 53 4c 20 69 73 20 63 6f 6d 70 .OpenSSL is comp
8180: 6c 69 65 64 20 77 69 74 68 20 74 68 65 20 5c 66 lied with the \f
8190: 42 65 6e 61 62 6c 65 2d 73 73 6c 2d 74 72 61 63 Benable-ssl-trac
81a0: 65 5c 66 52 20 6f 70 74 69 6f 6e 5c 26 2e 20 54 e\fR option\&. T
81b0: 68 69 73 20 63 61 6c 6c 62 61 63 6b 20 69 73 0a his callback is.
81c0: 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c 53 20 31 new for TclTLS 1
81d0: 5c 26 2e 38 5c 26 2e 20 54 68 65 20 61 72 67 75 \&.8\&. The argu
81e0: 6d 65 6e 74 73 20 61 72 65 3a 0a 2e 52 53 0a 2e ments are:..RS..
81f0: 54 50 0a 5c 66 49 64 69 72 65 63 74 69 6f 6e 5c TP.\fIdirection\
8200: 66 52 0a 44 69 72 65 63 74 69 6f 6e 20 69 73 20 fR.Direction is
8210: 65 69 74 68 65 72 20 5c 66 42 53 65 6e 74 5c 66 either \fBSent\f
8220: 52 20 6f 72 20 5c 66 42 52 65 63 65 69 76 65 64 R or \fBReceived
8230: 5c 66 52 5c 26 2e 0a 2e 54 50 0a 5c 66 49 76 65 \fR\&...TP.\fIve
8240: 72 73 69 6f 6e 5c 66 52 0a 56 65 72 73 69 6f 6e rsion\fR.Version
8250: 20 69 73 20 74 68 65 20 70 72 6f 74 6f 63 6f 6c is the protocol
8260: 20 76 65 72 73 69 6f 6e 5c 26 2e 0a 2e 54 50 0a version\&...TP.
8270: 5c 66 49 63 6f 6e 74 65 6e 74 5f 74 79 70 65 5c \fIcontent_type\
8280: 66 52 0a 43 6f 6e 74 65 6e 74 20 74 79 70 65 20 fR.Content type
8290: 69 73 20 74 68 65 20 6d 65 73 73 61 67 65 20 63 is the message c
82a0: 6f 6e 74 65 6e 74 20 74 79 70 65 5c 26 2e 0a 2e ontent type\&...
82b0: 54 50 0a 5c 66 49 6d 65 73 73 61 67 65 5c 66 52 TP.\fImessage\fR
82c0: 0a 4d 65 73 73 61 67 65 20 69 73 20 6d 6f 72 65 .Message is more
82d0: 20 69 6e 66 6f 20 66 72 6f 6d 20 74 68 65 20 5c info from the \
82e0: 66 42 53 53 4c 5f 74 72 61 63 65 5c 66 52 20 41 fBSSL_trace\fR A
82f0: 50 49 5c 26 2e 0a 2e 52 45 0a 2e 54 50 0a 5c 66 PI\&...RE..TP.\f
8300: 42 73 65 73 73 69 6f 6e 5c 66 52 20 5c 66 49 63 Bsession\fR \fIc
8310: 68 61 6e 6e 65 6c 49 64 20 73 65 73 73 69 6f 6e hannelId session
8320: 5f 69 64 20 73 65 73 73 69 6f 6e 5f 74 69 63 6b _id session_tick
8330: 65 74 20 6c 69 66 65 74 69 6d 65 5c 66 52 0a 54 et lifetime\fR.T
8340: 68 69 73 20 66 6f 72 6d 20 6f 66 20 63 61 6c 6c his form of call
8350: 62 61 63 6b 20 69 73 20 69 6e 76 6f 6b 65 64 20 back is invoked
8360: 62 79 20 74 68 65 20 4f 70 65 6e 53 53 4c 20 66 by the OpenSSL f
8370: 75 6e 63 74 69 6f 6e 0a 5c 66 42 53 53 4c 5f 43 unction.\fBSSL_C
8380: 54 58 5f 73 65 73 73 5f 73 65 74 5f 6e 65 77 5f TX_sess_set_new_
8390: 63 62 28 29 5c 66 52 20 77 68 65 6e 65 76 65 72 cb()\fR whenever
83a0: 20 61 20 6e 65 77 20 73 65 73 73 69 6f 6e 20 69 a new session i
83b0: 64 20 69 73 20 73 65 6e 74 20 62 79 20 74 68 65 d is sent by the
83c0: 0a 73 65 72 76 65 72 20 64 75 72 69 6e 67 20 74 .server during t
83d0: 68 65 20 69 6e 69 74 69 61 6c 20 63 6f 6e 6e 65 he initial conne
83e0: 63 74 69 6f 6e 20 61 6e 64 20 68 61 6e 64 73 68 ction and handsh
83f0: 61 6b 65 20 61 6e 64 20 61 6c 73 6f 20 64 75 72 ake and also dur
8400: 69 6e 67 20 74 68 65 20 73 65 73 73 69 6f 6e 0a ing the session.
8410: 69 66 20 74 68 65 20 5c 66 42 2d 70 6f 73 74 5f if the \fB-post_
8420: 68 61 6e 64 73 68 61 6b 65 5c 66 52 20 6f 70 74 handshake\fR opt
8430: 69 6f 6e 20 69 73 20 73 65 74 20 74 6f 20 74 72 ion is set to tr
8440: 75 65 5c 26 2e 20 54 68 69 73 20 63 61 6c 6c 62 ue\&. This callb
8450: 61 63 6b 20 69 73 20 6e 65 77 20 66 6f 72 0a 54 ack is new for.T
8460: 63 6c 54 4c 53 20 31 5c 26 2e 38 5c 26 2e 20 54 clTLS 1\&.8\&. T
8470: 68 65 20 61 72 67 75 6d 65 6e 74 73 20 61 72 65 he arguments are
8480: 3a 0a 2e 52 53 0a 2e 54 50 0a 5c 66 49 73 65 73 :..RS..TP.\fIses
8490: 73 69 6f 6e 5f 69 64 5c 66 52 0a 53 65 73 73 69 sion_id\fR.Sessi
84a0: 6f 6e 20 49 64 20 69 73 20 74 68 65 20 63 75 72 on Id is the cur
84b0: 72 65 6e 74 20 73 65 73 73 69 6f 6e 20 69 64 65 rent session ide
84c0: 6e 74 69 66 69 65 72 0a 2e 54 50 0a 5c 66 49 73 ntifier..TP.\fIs
84d0: 65 73 73 69 6f 6e 5f 74 69 63 6b 65 74 5c 66 52 ession_ticket\fR
84e0: 0a 54 69 63 6b 65 74 20 69 73 20 74 68 65 20 73 .Ticket is the s
84f0: 65 73 73 69 6f 6e 20 74 69 63 6b 65 74 20 69 6e ession ticket in
8500: 66 6f 0a 2e 54 50 0a 5c 66 49 6c 69 66 65 74 69 fo..TP.\fIlifeti
8510: 6d 65 5c 66 52 0a 4c 69 66 65 74 69 6d 65 20 69 me\fR.Lifetime i
8520: 73 20 74 68 65 20 74 69 63 6b 65 74 20 6c 69 66 s the ticket lif
8530: 65 74 69 6d 65 20 69 6e 20 73 65 63 6f 6e 64 73 etime in seconds
8540: 5c 26 2e 0a 2e 52 45 0a 2e 54 50 0a 5c 66 42 76 \&...RE..TP.\fBv
8550: 65 72 69 66 79 5c 66 52 20 5c 66 49 63 68 61 6e erify\fR \fIchan
8560: 6e 65 6c 49 64 20 64 65 70 74 68 20 63 65 72 74 nelId depth cert
8570: 20 73 74 61 74 75 73 20 65 72 72 6f 72 5c 66 52 status error\fR
8580: 0a 54 68 69 73 20 63 61 6c 6c 62 61 63 6b 20 77 .This callback w
8590: 61 73 20 6d 6f 76 65 64 20 74 6f 20 5c 66 42 2d as moved to \fB-
85a0: 76 61 6c 69 64 61 74 65 63 6f 6d 6d 61 6e 64 5c validatecommand\
85b0: 66 52 20 69 6e 20 54 63 6c 54 4c 53 20 31 5c 26 fR in TclTLS 1\&
85c0: 2e 38 5c 26 2e 0a 2e 50 50 0a 2e 53 53 20 22 56 .8\&...PP..SS "V
85d0: 41 4c 55 45 53 20 46 4f 52 20 50 41 53 53 57 4f ALUES FOR PASSWO
85e0: 52 44 20 43 41 4c 4c 42 41 43 4b 22 0a 54 68 65 RD CALLBACK".The
85f0: 20 63 61 6c 6c 62 61 63 6b 20 66 6f 72 20 74 68 callback for th
8600: 65 20 5c 66 42 2d 70 61 73 73 77 6f 72 64 5c 66 e \fB-password\f
8610: 52 20 6f 70 74 69 6f 6e 20 69 73 20 69 6e 76 6f R option is invo
8620: 6b 65 64 20 62 79 20 54 63 6c 54 4c 53 20 77 68 ked by TclTLS wh
8630: 65 6e 65 76 65 72 20 4f 70 65 6e 53 53 4c 20 6e enever OpenSSL n
8640: 65 65 64 73 0a 74 6f 20 6f 62 74 61 69 6e 20 61 eeds.to obtain a
8650: 20 70 61 73 73 77 6f 72 64 5c 26 2e 20 53 65 65 password\&. See
8660: 20 62 65 6c 6f 77 20 66 6f 72 20 74 68 65 20 70 below for the p
8670: 6f 73 73 69 62 6c 65 20 61 72 67 75 6d 65 6e 74 ossible argument
8680: 73 20 70 61 73 73 65 64 20 74 6f 20 74 68 65 0a s passed to the.
8690: 63 61 6c 6c 62 61 63 6b 20 73 63 72 69 70 74 5c callback script\
86a0: 26 2e 20 54 68 65 20 75 73 65 72 20 70 72 6f 76 &. The user prov
86b0: 69 64 65 64 20 70 61 73 73 77 6f 72 64 20 69 73 ided password is
86c0: 20 65 78 70 65 63 74 65 64 20 74 6f 20 62 65 20 expected to be
86d0: 72 65 74 75 72 6e 65 64 20 62 79 20 74 68 65 0a returned by the.
86e0: 63 61 6c 6c 62 61 63 6b 5c 26 2e 0a 2e 54 50 0a callback\&...TP.
86f0: 5c 66 42 70 61 73 73 77 6f 72 64 5c 66 52 20 5c \fBpassword\fR \
8700: 66 49 72 77 66 6c 61 67 20 73 69 7a 65 5c 66 52 fIrwflag size\fR
8710: 0a 49 6e 76 6f 6b 65 64 20 77 68 65 6e 20 6c 6f .Invoked when lo
8720: 61 64 69 6e 67 20 6f 72 20 73 74 6f 72 69 6e 67 ading or storing
8730: 20 61 6e 20 65 6e 63 72 79 70 74 65 64 20 50 45 an encrypted PE
8740: 4d 20 63 65 72 74 69 66 69 63 61 74 65 5c 26 2e M certificate\&.
8750: 20 54 68 65 20 61 72 67 75 6d 65 6e 74 73 20 61 The arguments a
8760: 72 65 3a 0a 2e 52 53 0a 2e 54 50 0a 5c 66 49 72 re:..RS..TP.\fIr
8770: 77 66 6c 61 67 5c 66 52 0a 54 68 65 20 72 65 61 wflag\fR.The rea
8780: 64 2f 77 72 69 74 65 20 66 6c 61 67 20 69 73 20 d/write flag is
8790: 30 20 66 6f 72 20 72 65 61 64 69 6e 67 2f 64 65 0 for reading/de
87a0: 63 72 79 70 74 69 6f 6e 20 6f 72 20 31 20 66 6f cryption or 1 fo
87b0: 72 20 77 72 69 74 69 6e 67 2f 65 6e 63 72 79 70 r writing/encryp
87c0: 74 69 6f 6e 5c 26 2e 0a 54 68 65 20 6c 61 74 74 tion\&..The latt
87d0: 65 72 20 63 61 6e 20 62 65 20 75 73 65 64 20 74 er can be used t
87e0: 6f 20 64 65 74 65 72 6d 69 6e 65 20 77 68 65 6e o determine when
87f0: 20 74 6f 20 70 72 6f 6d 70 74 20 74 68 65 20 75 to prompt the u
8800: 73 65 72 20 74 6f 20 63 6f 6e 66 69 72 6d 5c 26 ser to confirm\&
8810: 2e 0a 54 68 69 73 20 61 72 67 75 6d 65 6e 74 20 ..This argument
8820: 69 73 20 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c is new for TclTL
8830: 53 20 31 5c 26 2e 38 5c 26 2e 0a 2e 54 50 0a 5c S 1\&.8\&...TP.\
8840: 66 49 73 69 7a 65 5c 66 52 0a 54 68 65 20 73 69 fIsize\fR.The si
8850: 7a 65 20 69 73 20 74 68 65 20 6d 61 78 69 6d 75 ze is the maximu
8860: 6d 20 6c 65 6e 67 74 68 20 6f 66 20 74 68 65 20 m length of the
8870: 70 61 73 73 77 6f 72 64 20 69 6e 20 62 79 74 65 password in byte
8880: 73 5c 26 2e 0a 54 68 69 73 20 61 72 67 75 6d 65 s\&..This argume
8890: 6e 74 20 69 73 20 6e 65 77 20 66 6f 72 20 54 63 nt is new for Tc
88a0: 6c 54 4c 53 20 31 5c 26 2e 38 5c 26 2e 0a 2e 52 lTLS 1\&.8\&...R
88b0: 45 0a 2e 50 50 0a 2e 53 53 20 22 56 41 4c 55 45 E..PP..SS "VALUE
88c0: 53 20 46 4f 52 20 56 41 4c 49 44 41 54 45 20 43 S FOR VALIDATE C
88d0: 4f 4d 4d 41 4e 44 20 43 41 4c 4c 42 41 43 4b 22 OMMAND CALLBACK"
88e0: 0a 54 68 65 20 63 61 6c 6c 62 61 63 6b 20 66 6f .The callback fo
88f0: 72 20 74 68 65 20 5c 66 42 2d 76 61 6c 69 64 61 r the \fB-valida
8900: 74 65 63 6f 6d 6d 61 6e 64 5c 66 52 20 6f 70 74 tecommand\fR opt
8910: 69 6f 6e 20 69 73 20 69 6e 76 6f 6b 65 64 20 64 ion is invoked d
8920: 75 72 69 6e 67 20 74 68 65 20 68 61 6e 64 73 68 uring the handsh
8930: 61 6b 65 0a 70 72 6f 63 65 73 73 20 69 6e 20 6f ake.process in o
8940: 72 64 65 72 20 66 6f 72 20 74 68 65 20 61 70 70 rder for the app
8950: 6c 69 63 61 74 69 6f 6e 20 74 6f 20 76 61 6c 69 lication to vali
8960: 64 61 74 65 20 74 68 65 20 70 72 6f 76 69 64 65 date the provide
8970: 64 20 76 61 6c 75 65 28 73 29 5c 26 2e 20 53 65 d value(s)\&. Se
8980: 65 0a 62 65 6c 6f 77 20 66 6f 72 20 74 68 65 20 e.below for the
8990: 70 6f 73 73 69 62 6c 65 20 61 72 67 75 6d 65 6e possible argumen
89a0: 74 73 20 70 61 73 73 65 64 20 74 6f 20 74 68 65 ts passed to the
89b0: 20 63 61 6c 6c 62 61 63 6b 20 73 63 72 69 70 74 callback script
89c0: 5c 26 2e 20 49 66 20 6e 6f 74 0a 73 70 65 63 69 \&. If not.speci
89d0: 66 69 65 64 2c 20 4f 70 65 6e 53 53 4c 20 77 69 fied, OpenSSL wi
89e0: 6c 6c 20 61 63 63 65 70 74 20 61 6c 6c 20 76 61 ll accept all va
89f0: 6c 69 64 20 63 65 72 74 69 66 69 63 61 74 65 73 lid certificates
8a00: 20 61 6e 64 20 65 78 74 65 6e 73 69 6f 6e 73 5c and extensions\
8a10: 26 2e 20 54 6f 20 72 65 6a 65 63 74 0a 74 68 65 &. To reject.the
8a20: 20 76 61 6c 75 65 20 61 6e 64 20 61 62 6f 72 74 value and abort
8a30: 20 74 68 65 20 63 6f 6e 6e 65 63 74 69 6f 6e 2c the connection,
8a40: 20 74 68 65 20 63 61 6c 6c 62 61 63 6b 20 73 68 the callback sh
8a50: 6f 75 6c 64 20 72 65 74 75 72 6e 20 30 5c 26 2e ould return 0\&.
8a60: 20 54 6f 20 61 63 63 65 70 74 20 74 68 65 0a 76 To accept the.v
8a70: 61 6c 75 65 20 61 6e 64 20 63 6f 6e 74 69 6e 75 alue and continu
8a80: 65 20 74 68 65 20 63 6f 6e 6e 65 63 74 69 6f 6e e the connection
8a90: 2c 20 69 74 20 73 68 6f 75 6c 64 20 72 65 74 75 , it should retu
8aa0: 72 6e 20 31 5c 26 2e 20 54 6f 20 72 65 6a 65 63 rn 1\&. To rejec
8ab0: 74 20 74 68 65 20 76 61 6c 75 65 2c 20 62 75 74 t the value, but
8ac0: 0a 63 6f 6e 74 69 6e 75 65 20 74 68 65 20 63 6f .continue the co
8ad0: 6e 6e 65 63 74 69 6f 6e 2c 20 69 74 20 73 68 6f nnection, it sho
8ae0: 75 6c 64 20 72 65 74 75 72 6e 20 32 5c 26 2e 20 uld return 2\&.
8af0: 54 68 69 73 20 63 61 6c 6c 62 61 63 6b 20 69 73 This callback is
8b00: 20 6e 65 77 20 66 6f 72 20 54 63 6c 54 4c 53 20 new for TclTLS
8b10: 31 5c 26 2e 38 5c 26 2e 0a 2e 54 50 0a 5c 66 42 1\&.8\&...TP.\fB
8b20: 61 6c 70 6e 5c 66 52 20 5c 66 49 63 68 61 6e 6e alpn\fR \fIchann
8b30: 65 6c 49 64 20 70 72 6f 74 6f 63 6f 6c 20 6d 61 elId protocol ma
8b40: 74 63 68 5c 66 52 0a 46 6f 72 20 73 65 72 76 65 tch\fR.For serve
8b50: 72 73 2c 20 74 68 69 73 20 66 6f 72 6d 20 6f 66 rs, this form of
8b60: 20 63 61 6c 6c 62 61 63 6b 20 69 73 20 69 6e 76 callback is inv
8b70: 6f 6b 65 64 20 77 68 65 6e 20 74 68 65 20 63 6c oked when the cl
8b80: 69 65 6e 74 20 41 4c 50 4e 20 65 78 74 65 6e 73 ient ALPN extens
8b90: 69 6f 6e 20 69 73 0a 72 65 63 65 69 76 65 64 5c ion is.received\
8ba0: 26 2e 20 49 66 20 5c 66 49 6d 61 74 63 68 5c 66 &. If \fImatch\f
8bb0: 52 20 69 73 20 74 72 75 65 2c 20 74 68 65 6e 20 R is true, then
8bc0: 5c 66 49 70 72 6f 74 6f 63 6f 6c 5c 66 52 20 69 \fIprotocol\fR i
8bd0: 73 20 74 68 65 20 66 69 72 73 74 0a 5c 66 42 2d s the first.\fB-
8be0: 61 6c 70 6e 5c 66 52 20 70 72 6f 74 6f 63 6f 6c alpn\fR protocol
8bf0: 20 6f 70 74 69 6f 6e 20 69 6e 20 63 6f 6d 6d 6f option in commo
8c00: 6e 20 74 6f 20 62 6f 74 68 20 74 68 65 20 63 6c n to both the cl
8c10: 69 65 6e 74 20 61 6e 64 20 73 65 72 76 65 72 5c ient and server\
8c20: 26 2e 0a 49 66 20 6e 6f 74 2c 20 74 68 65 20 66 &..If not, the f
8c30: 69 72 73 74 20 63 6c 69 65 6e 74 20 73 70 65 63 irst client spec
8c40: 69 66 69 65 64 20 70 72 6f 74 6f 63 6f 6c 20 69 ified protocol i
8c50: 73 20 75 73 65 64 5c 26 2e 20 54 68 69 73 20 63 s used\&. This c
8c60: 61 6c 6c 62 61 63 6b 20 69 73 20 63 61 6c 6c 65 allback is calle
8c70: 64 0a 61 66 74 65 72 20 74 68 65 20 48 65 6c 6c d.after the Hell
8c80: 6f 20 61 6e 64 20 41 4c 50 4e 20 63 61 6c 6c 62 o and ALPN callb
8c90: 61 63 6b 73 5c 26 2e 0a 2e 54 50 0a 5c 66 42 68 acks\&...TP.\fBh
8ca0: 65 6c 6c 6f 5c 66 52 20 5c 66 49 63 68 61 6e 6e ello\fR \fIchann
8cb0: 65 6c 49 64 20 73 65 72 76 65 72 6e 61 6d 65 5c elId servername\
8cc0: 66 52 0a 46 6f 72 20 73 65 72 76 65 72 73 2c 20 fR.For servers,
8cd0: 74 68 69 73 20 66 6f 72 6d 20 6f 66 20 63 61 6c this form of cal
8ce0: 6c 62 61 63 6b 20 69 73 20 69 6e 76 6f 6b 65 64 lback is invoked
8cf0: 20 64 75 72 69 6e 67 20 63 6c 69 65 6e 74 20 68 during client h
8d00: 65 6c 6c 6f 20 6d 65 73 73 61 67 65 0a 70 72 6f ello message.pro
8d10: 63 65 73 73 69 6e 67 5c 26 2e 20 54 68 65 20 70 cessing\&. The p
8d20: 75 72 70 6f 73 65 20 69 73 20 73 6f 20 74 68 65 urpose is so the
8d30: 20 73 65 72 76 65 72 20 63 61 6e 20 73 65 6c 65 server can sele
8d40: 63 74 20 74 68 65 20 61 70 70 72 6f 70 72 69 61 ct the appropria
8d50: 74 65 20 63 65 72 74 69 66 69 63 61 74 65 0a 74 te certificate.t
8d60: 6f 20 70 72 65 73 65 6e 74 20 74 6f 20 74 68 65 o present to the
8d70: 20 63 6c 69 65 6e 74 2c 20 61 6e 64 20 74 6f 20 client, and to
8d80: 6d 61 6b 65 20 6f 74 68 65 72 20 63 6f 6e 66 69 make other confi
8d90: 67 75 72 61 74 69 6f 6e 20 61 64 6a 75 73 74 6d guration adjustm
8da0: 65 6e 74 73 20 72 65 6c 65 76 61 6e 74 0a 74 6f ents relevant.to
8db0: 20 74 68 61 74 20 73 65 72 76 65 72 20 6e 61 6d that server nam
8dc0: 65 20 61 6e 64 20 69 74 73 20 63 6f 6e 66 69 67 e and its config
8dd0: 75 72 61 74 69 6f 6e 5c 26 2e 20 49 74 20 69 73 uration\&. It is
8de0: 20 63 61 6c 6c 65 64 20 62 65 66 6f 72 65 20 74 called before t
8df0: 68 65 20 53 4e 49 20 61 6e 64 20 41 4c 50 4e 0a he SNI and ALPN.
8e00: 63 61 6c 6c 62 61 63 6b 73 5c 26 2e 0a 2e 54 50 callbacks\&...TP
8e10: 0a 5c 66 42 73 6e 69 5c 66 52 20 5c 66 49 63 68 .\fBsni\fR \fIch
8e20: 61 6e 6e 65 6c 49 64 20 73 65 72 76 65 72 6e 61 annelId serverna
8e30: 6d 65 5c 66 52 0a 46 6f 72 20 73 65 72 76 65 72 me\fR.For server
8e40: 73 2c 20 74 68 69 73 20 66 6f 72 6d 20 6f 66 20 s, this form of
8e50: 63 61 6c 6c 62 61 63 6b 20 69 73 20 69 6e 76 6f callback is invo
8e60: 6b 65 64 20 77 68 65 6e 20 74 68 65 20 53 65 72 ked when the Ser
8e70: 76 65 72 20 4e 61 6d 65 20 49 6e 64 69 63 61 74 ver Name Indicat
8e80: 69 6f 6e 0a 28 53 4e 49 29 20 65 78 74 65 6e 73 ion.(SNI) extens
8e90: 69 6f 6e 20 69 73 20 72 65 63 65 69 76 65 64 5c ion is received\
8ea0: 26 2e 20 54 68 65 20 5c 66 49 73 65 72 76 65 72 &. The \fIserver
8eb0: 6e 61 6d 65 5c 66 52 20 61 72 67 75 6d 65 6e 74 name\fR argument
8ec0: 20 69 73 20 74 68 65 20 63 6c 69 65 6e 74 0a 70 is the client.p
8ed0: 72 6f 76 69 64 65 64 20 73 65 72 76 65 72 20 6e rovided server n
8ee0: 61 6d 65 20 73 70 65 63 69 66 69 65 64 20 69 6e ame specified in
8ef0: 20 74 68 65 20 5c 66 42 2d 73 65 72 76 65 72 6e the \fB-servern
8f00: 61 6d 65 3c 2f 62 3e 5c 66 52 20 6f 70 74 69 6f ame</b>\fR optio
8f10: 6e 5c 26 2e 20 54 68 65 0a 70 75 72 70 6f 73 65 n\&. The.purpose
8f20: 20 69 73 20 73 6f 20 77 68 65 6e 20 61 20 73 65 is so when a se
8f30: 72 76 65 72 20 73 75 70 70 6f 72 74 73 20 6d 75 rver supports mu
8f40: 6c 74 69 70 6c 65 20 6e 61 6d 65 73 2c 20 74 68 ltiple names, th
8f50: 65 20 72 69 67 68 74 20 63 65 72 74 69 66 69 63 e right certific
8f60: 61 74 65 0a 63 61 6e 20 62 65 20 75 73 65 64 5c ate.can be used\
8f70: 26 2e 20 49 74 20 69 73 20 63 61 6c 6c 65 64 20 &. It is called
8f80: 61 66 74 65 72 20 74 68 65 20 68 65 6c 6c 6f 20 after the hello
8f90: 63 61 6c 6c 62 61 63 6b 20 62 75 74 20 62 65 66 callback but bef
8fa0: 6f 72 65 20 74 68 65 20 41 4c 50 4e 0a 63 61 6c ore the ALPN.cal
8fb0: 6c 62 61 63 6b 5c 26 2e 0a 2e 54 50 0a 5c 66 42 lback\&...TP.\fB
8fc0: 76 65 72 69 66 79 5c 66 52 20 5c 66 49 63 68 61 verify\fR \fIcha
8fd0: 6e 6e 65 6c 49 64 20 64 65 70 74 68 20 63 65 72 nnelId depth cer
8fe0: 74 20 73 74 61 74 75 73 20 65 72 72 6f 72 5c 66 t status error\f
8ff0: 52 0a 54 68 69 73 20 66 6f 72 6d 20 6f 66 20 63 R.This form of c
9000: 61 6c 6c 62 61 63 6b 20 69 73 20 69 6e 76 6f 6b allback is invok
9010: 65 64 20 62 79 20 4f 70 65 6e 53 53 4c 20 77 68 ed by OpenSSL wh
9020: 65 6e 20 61 20 6e 65 77 20 63 65 72 74 69 66 69 en a new certifi
9030: 63 61 74 65 20 69 73 20 72 65 63 65 69 76 65 64 cate is received
9040: 0a 66 72 6f 6d 20 74 68 65 20 70 65 65 72 5c 26 .from the peer\&
9050: 2e 20 49 74 20 61 6c 6c 6f 77 73 20 74 68 65 20 . It allows the
9060: 63 6c 69 65 6e 74 20 74 6f 20 63 68 65 63 6b 20 client to check
9070: 74 68 65 20 63 65 72 74 69 66 69 63 61 74 65 20 the certificate
9080: 76 65 72 69 66 69 63 61 74 69 6f 6e 0a 72 65 73 verification.res
9090: 75 6c 74 73 20 61 6e 64 20 63 68 6f 6f 73 65 20 ults and choose
90a0: 77 68 65 74 68 65 72 20 74 6f 20 63 6f 6e 74 69 whether to conti
90b0: 6e 75 65 20 6f 72 20 6e 6f 74 5c 26 2e 20 49 74 nue or not\&. It
90c0: 20 69 73 20 63 61 6c 6c 65 64 20 66 6f 72 20 65 is called for e
90d0: 61 63 68 0a 63 65 72 74 69 66 69 63 61 74 65 20 ach.certificate
90e0: 69 6e 20 74 68 65 20 63 65 72 74 69 66 69 63 61 in the certifica
90f0: 74 65 20 63 68 61 69 6e 5c 26 2e 20 54 68 69 73 te chain\&. This
9100: 20 63 61 6c 6c 62 61 63 6b 20 77 61 73 20 6d 6f callback was mo
9110: 76 65 64 20 66 72 6f 6d 0a 5c 66 42 2d 63 6f 6d ved from.\fB-com
9120: 6d 61 6e 64 5c 66 52 20 69 6e 20 54 63 6c 54 4c mand\fR in TclTL
9130: 53 20 31 5c 26 2e 38 5c 26 2e 20 54 68 65 20 61 S 1\&.8\&. The a
9140: 72 67 75 6d 65 6e 74 73 20 61 72 65 3a 0a 2e 52 rguments are:..R
9150: 53 0a 2e 54 50 0a 5c 66 49 64 65 70 74 68 5c 66 S..TP.\fIdepth\f
9160: 52 0a 54 68 65 20 64 65 70 74 68 20 69 73 20 74 R.The depth is t
9170: 68 65 20 69 6e 74 65 67 65 72 20 64 65 70 74 68 he integer depth
9180: 20 6f 66 20 74 68 65 20 63 65 72 74 69 66 69 63 of the certific
9190: 61 74 65 20 69 6e 20 74 68 65 20 63 65 72 74 69 ate in the certi
91a0: 66 69 63 61 74 65 20 63 68 61 69 6e 2c 0a 77 68 ficate chain,.wh
91b0: 65 72 65 20 30 20 69 73 20 74 68 65 20 70 65 65 ere 0 is the pee
91c0: 72 20 63 65 72 74 69 66 69 63 61 74 65 20 61 6e r certificate an
91d0: 64 20 68 69 67 68 65 72 20 76 61 6c 75 65 73 20 d higher values
91e0: 67 6f 69 6e 67 20 75 70 20 74 6f 20 74 68 65 20 going up to the
91f0: 43 65 72 74 69 66 69 63 61 74 65 0a 41 75 74 68 Certificate.Auth
9200: 6f 72 69 74 79 20 28 43 41 29 5c 26 2e 0a 2e 54 ority (CA)\&...T
9210: 50 0a 5c 66 49 63 65 72 74 5c 66 52 0a 54 68 65 P.\fIcert\fR.The
9220: 20 63 65 72 74 20 61 72 67 75 6d 65 6e 74 20 69 cert argument i
9230: 73 20 61 20 6c 69 73 74 20 6f 66 20 6b 65 79 2d s a list of key-
9240: 76 61 6c 75 65 20 70 61 69 72 73 20 73 69 6d 69 value pairs simi
9250: 6c 61 72 20 74 6f 20 74 68 6f 73 65 20 72 65 74 lar to those ret
9260: 75 72 6e 65 64 20 62 79 0a 5c 66 42 74 6c 73 3a urned by.\fBtls:
9270: 3a 73 74 61 74 75 73 5c 66 52 5c 26 2e 0a 2e 54 :status\fR\&...T
9280: 50 0a 5c 66 49 73 74 61 74 75 73 5c 66 52 0a 54 P.\fIstatus\fR.T
9290: 68 65 20 73 74 61 74 75 73 20 61 72 67 75 6d 65 he status argume
92a0: 6e 74 20 69 73 20 74 68 65 20 62 6f 6f 6c 65 61 nt is the boolea
92b0: 6e 20 76 61 6c 69 64 69 74 79 20 6f 66 20 74 68 n validity of th
92c0: 65 20 63 75 72 72 65 6e 74 20 63 65 72 74 69 66 e current certif
92d0: 69 63 61 74 65 20 77 68 65 72 65 20 30 0a 69 73 icate where 0.is
92e0: 20 69 6e 76 61 6c 69 64 20 61 6e 64 20 31 20 69 invalid and 1 i
92f0: 73 20 76 61 6c 69 64 5c 26 2e 0a 2e 54 50 0a 5c s valid\&...TP.\
9300: 66 49 65 72 72 6f 72 5c 66 52 0a 54 68 65 20 65 fIerror\fR.The e
9310: 72 72 6f 72 20 61 72 67 75 6d 65 6e 74 20 69 73 rror argument is
9320: 20 74 68 65 20 65 72 72 6f 72 20 6d 65 73 73 61 the error messa
9330: 67 65 2c 20 69 66 20 61 6e 79 2c 20 67 65 6e 65 ge, if any, gene
9340: 72 61 74 65 64 20 62 79 0a 5c 66 42 58 35 30 39 rated by.\fBX509
9350: 5f 53 54 4f 52 45 5f 43 54 58 5f 67 65 74 5f 65 _STORE_CTX_get_e
9360: 72 72 6f 72 28 29 5c 66 52 5c 26 2e 0a 2e 52 45 rror()\fR\&...RE
9370: 0a 2e 50 50 0a 52 65 66 65 72 65 6e 63 65 20 69 ..PP.Reference i
9380: 6d 70 6c 65 6d 65 6e 74 61 74 69 6f 6e 73 20 6f mplementations o
9390: 66 20 74 68 65 73 65 20 63 61 6c 6c 62 61 63 6b f these callback
93a0: 73 20 61 72 65 20 70 72 6f 76 69 64 65 64 20 69 s are provided i
93b0: 6e 20 22 5c 66 49 74 6c 73 5c 26 2e 74 63 6c 5c n "\fItls\&.tcl\
93c0: 66 52 22 0a 61 73 20 5c 66 42 74 6c 73 3a 3a 63 fR".as \fBtls::c
93d0: 61 6c 6c 62 61 63 6b 5c 66 52 2c 20 5c 66 42 74 allback\fR, \fBt
93e0: 6c 73 3a 3a 70 61 73 73 77 6f 72 64 5c 66 52 2c ls::password\fR,
93f0: 20 61 6e 64 20 5c 66 42 74 6c 73 3a 3a 76 61 6c and \fBtls::val
9400: 69 64 61 74 65 5f 63 6f 6d 6d 61 6e 64 5c 66 52 idate_command\fR
9410: 0a 72 65 73 70 65 63 74 69 76 65 6c 79 5c 26 2e .respectively\&.
9420: 20 4e 6f 74 65 20 74 68 61 74 20 74 68 65 73 65 Note that these
9430: 20 61 72 65 20 6f 6e 6c 79 20 5c 66 49 73 61 6d are only \fIsam
9440: 70 6c 65 5c 66 52 20 69 6d 70 6c 65 6d 65 6e 74 ple\fR implement
9450: 61 74 69 6f 6e 73 5c 26 2e 20 49 6e 20 61 20 6d ations\&. In a m
9460: 6f 72 65 0a 72 65 61 6c 69 73 74 69 63 20 64 65 ore.realistic de
9470: 70 6c 6f 79 6d 65 6e 74 20 79 6f 75 20 77 6f 75 ployment you wou
9480: 6c 64 20 73 70 65 63 69 66 79 20 79 6f 75 72 20 ld specify your
9490: 6f 77 6e 20 63 61 6c 6c 62 61 63 6b 20 73 63 72 own callback scr
94a0: 69 70 74 73 20 6f 6e 20 65 61 63 68 20 54 4c 53 ipts on each TLS
94b0: 0a 63 68 61 6e 6e 65 6c 20 75 73 69 6e 67 20 74 .channel using t
94c0: 68 65 20 5c 66 42 2d 63 6f 6d 6d 61 6e 64 5c 66 he \fB-command\f
94d0: 52 2c 20 5c 66 42 2d 70 61 73 73 77 6f 72 64 5c R, \fB-password\
94e0: 66 52 2c 20 61 6e 64 0a 5c 66 42 2d 76 61 6c 69 fR, and.\fB-vali
94f0: 64 61 74 65 5f 63 6f 6d 6d 61 6e 64 5c 66 52 20 date_command\fR
9500: 6f 70 74 69 6f 6e 73 5c 26 2e 0a 2e 50 50 0a 54 options\&...PP.T
9510: 68 65 20 64 65 66 61 75 6c 74 20 62 65 68 61 76 he default behav
9520: 69 6f 72 20 77 68 65 6e 20 74 68 65 20 5c 66 42 ior when the \fB
9530: 2d 63 6f 6d 6d 61 6e 64 5c 66 52 20 61 6e 64 20 -command\fR and
9540: 5c 66 42 2d 76 61 6c 69 64 61 74 65 5f 63 6f 6d \fB-validate_com
9550: 6d 61 6e 64 5c 66 52 0a 6f 70 74 69 6f 6e 73 20 mand\fR.options
9560: 61 72 65 20 6e 6f 74 20 73 70 65 63 69 66 69 65 are not specifie
9570: 64 2c 20 69 73 20 66 6f 72 20 54 63 6c 54 4c 53 d, is for TclTLS
9580: 20 74 6f 20 70 72 6f 63 65 73 73 20 74 68 65 20 to process the
9590: 61 73 73 6f 63 69 61 74 65 64 20 6c 69 62 72 61 associated libra
95a0: 72 79 0a 63 61 6c 6c 62 61 63 6b 73 20 69 6e 74 ry.callbacks int
95b0: 65 72 6e 61 6c 6c 79 5c 26 2e 20 54 68 65 20 64 ernally\&. The d
95c0: 65 66 61 75 6c 74 20 62 65 68 61 76 69 6f 72 20 efault behavior
95d0: 77 68 65 6e 20 74 68 65 20 5c 66 42 2d 70 61 73 when the \fB-pas
95e0: 73 77 6f 72 64 5c 66 52 20 6f 70 74 69 6f 6e 0a sword\fR option.
95f0: 69 73 20 6e 6f 74 20 73 70 65 63 69 66 69 65 64 is not specified
9600: 20 69 73 20 66 6f 72 20 54 63 6c 54 4c 53 20 74 is for TclTLS t
9610: 6f 20 70 72 6f 63 65 73 73 20 74 68 65 20 61 73 o process the as
9620: 73 6f 63 69 61 74 65 64 20 6c 69 62 72 61 72 79 sociated library
9630: 20 63 61 6c 6c 62 61 63 6b 73 20 62 79 0a 61 74 callbacks by.at
9640: 74 65 6d 70 74 69 6e 67 20 74 6f 20 63 61 6c 6c tempting to call
9650: 20 5c 66 42 74 6c 73 3a 3a 70 61 73 73 77 6f 72 \fBtls::passwor
9660: 64 5c 66 52 5c 26 2e 20 54 68 65 20 64 69 66 66 d\fR\&. The diff
9670: 65 72 65 6e 63 65 20 62 65 74 77 65 65 6e 20 74 erence between t
9680: 68 65 73 65 20 74 77 6f 0a 62 65 68 61 76 69 6f hese two.behavio
9690: 72 73 20 69 73 20 61 20 63 6f 6e 73 65 71 75 65 rs is a conseque
96a0: 6e 63 65 20 6f 66 20 6d 61 69 6e 74 61 69 6e 69 nce of maintaini
96b0: 6e 67 20 63 6f 6d 70 61 74 69 62 69 6c 69 74 79 ng compatibility
96c0: 20 77 69 74 68 20 65 61 72 6c 69 65 72 0a 69 6d with earlier.im
96d0: 70 6c 65 6d 65 6e 74 61 74 69 6f 6e 73 5c 26 2e plementations\&.
96e0: 0a 2e 50 50 0a 5c 66 49 54 68 65 20 75 73 65 20 ..PP.\fIThe use
96f0: 6f 66 20 74 68 65 20 72 65 66 65 72 65 6e 63 65 of the reference
9700: 20 63 61 6c 6c 62 61 63 6b 73 20 5c 66 42 74 6c callbacks \fBtl
9710: 73 3a 3a 63 61 6c 6c 62 61 63 6b 5c 66 52 2c 20 s::callback\fR,
9720: 5c 66 42 74 6c 73 3a 3a 70 61 73 73 77 6f 72 64 \fBtls::password
9730: 5c 66 52 2c 0a 61 6e 64 20 5c 66 42 74 6c 73 3a \fR,.and \fBtls:
9740: 3a 76 61 6c 69 64 61 74 65 5f 63 6f 6d 6d 61 6e :validate_comman
9750: 64 5c 66 52 20 69 73 20 6e 6f 74 20 72 65 63 6f d\fR is not reco
9760: 6d 6d 65 6e 64 65 64 5c 26 2e 20 54 68 65 79 20 mmended\&. They
9770: 6d 61 79 20 62 65 20 72 65 6d 6f 76 65 64 20 66 may be removed f
9780: 72 6f 6d 20 66 75 74 75 72 65 20 72 65 6c 65 61 rom future relea
9790: 73 65 73 5c 26 2e 5c 66 52 0a 2e 53 48 20 44 45 ses\&.\fR..SH DE
97a0: 42 55 47 0a 46 6f 72 20 6d 6f 73 74 20 64 65 62 BUG.For most deb
97b0: 75 67 67 69 6e 67 20 6e 65 65 64 73 2c 20 74 68 ugging needs, th
97c0: 65 20 5c 66 42 2d 63 61 6c 6c 62 61 63 6b 5c 66 e \fB-callback\f
97d0: 52 20 6f 70 74 69 6f 6e 20 63 61 6e 20 62 65 20 R option can be
97e0: 75 73 65 64 20 74 6f 20 70 72 6f 76 69 64 65 0a used to provide.
97f0: 73 75 66 66 69 63 69 65 6e 74 20 69 6e 73 69 67 sufficient insig
9800: 68 74 20 61 6e 64 20 69 6e 66 6f 72 6d 61 74 69 ht and informati
9810: 6f 6e 20 6f 6e 20 74 68 65 20 54 4c 53 20 68 61 on on the TLS ha
9820: 6e 64 73 68 61 6b 65 20 61 6e 64 20 70 72 6f 67 ndshake and prog
9830: 72 65 73 73 5c 26 2e 20 49 66 0a 66 75 72 74 68 ress\&. If.furth
9840: 65 72 20 74 72 6f 75 62 6c 65 73 68 6f 6f 74 69 er troubleshooti
9850: 6e 67 20 69 6e 73 69 67 68 74 20 69 73 20 6e 65 ng insight is ne
9860: 65 64 65 64 2c 20 74 68 65 20 63 6f 6d 70 69 6c eded, the compil
9870: 65 20 74 69 6d 65 20 6f 70 74 69 6f 6e 0a 5c 66 e time option.\f
9880: 42 2d 2d 65 6e 61 62 6c 65 2d 64 65 62 75 67 5c B--enable-debug\
9890: 66 52 20 63 61 6e 20 62 65 20 75 73 65 64 20 74 fR can be used t
98a0: 6f 20 67 65 74 20 64 65 74 61 69 6c 65 64 20 65 o get detailed e
98b0: 78 65 63 75 74 69 6f 6e 20 66 6c 6f 77 20 73 74 xecution flow st
98c0: 61 74 75 73 5c 26 2e 0a 2e 50 50 0a 54 4c 53 20 atus\&...PP.TLS
98d0: 6b 65 79 20 6c 6f 67 67 69 6e 67 20 63 61 6e 20 key logging can
98e0: 62 65 20 65 6e 61 62 6c 65 64 20 62 79 20 73 65 be enabled by se
98f0: 74 74 69 6e 67 20 74 68 65 20 65 6e 76 69 72 6f tting the enviro
9900: 6e 6d 65 6e 74 20 76 61 72 69 61 62 6c 65 0a 5c nment variable.\
9910: 66 42 53 53 4c 4b 45 59 4c 4f 47 46 49 4c 45 5c fBSSLKEYLOGFILE\
9920: 66 52 20 74 6f 20 74 68 65 20 6e 61 6d 65 20 6f fR to the name o
9930: 66 20 74 68 65 20 66 69 6c 65 20 74 6f 20 6c 6f f the file to lo
9940: 67 20 74 6f 5c 26 2e 20 54 68 65 6e 20 77 68 65 g to\&. Then whe
9950: 6e 65 76 65 72 20 54 4c 53 20 6b 65 79 0a 6d 61 never TLS key.ma
9960: 74 65 72 69 61 6c 20 69 73 20 67 65 6e 65 72 61 terial is genera
9970: 74 65 64 20 6f 72 20 72 65 63 65 69 76 65 64 20 ted or received
9980: 69 74 20 77 69 6c 6c 20 62 65 20 6c 6f 67 67 65 it will be logge
9990: 64 20 74 6f 20 74 68 65 20 66 69 6c 65 5c 26 2e d to the file\&.
99a0: 20 54 68 69 73 20 69 73 20 75 73 65 66 75 6c 0a This is useful.
99b0: 66 6f 72 20 6c 6f 67 67 69 6e 67 20 6b 65 79 20 for logging key
99c0: 64 61 74 61 20 66 6f 72 20 6e 65 74 77 6f 72 6b data for network
99d0: 20 6c 6f 67 67 69 6e 67 20 74 6f 6f 6c 73 20 74 logging tools t
99e0: 6f 20 75 73 65 20 74 6f 20 64 65 63 72 79 70 74 o use to decrypt
99f0: 20 74 68 65 20 64 61 74 61 5c 26 2e 0a 2e 50 50 the data\&...PP
9a00: 0a 54 68 65 20 5c 66 42 74 6c 73 3a 3a 64 65 62 .The \fBtls::deb
9a10: 75 67 5c 66 52 20 76 61 72 69 61 62 6c 65 20 70 ug\fR variable p
9a20: 72 6f 76 69 64 65 73 20 73 6f 6d 65 20 61 64 64 rovides some add
9a30: 69 74 69 6f 6e 61 6c 20 63 6f 6e 74 72 6f 6c 20 itional control
9a40: 6f 76 65 72 20 74 68 65 0a 64 65 62 75 67 20 6c over the.debug l
9a50: 6f 67 67 69 6e 67 20 69 6e 20 74 68 65 20 5c 66 ogging in the \f
9a60: 42 74 6c 73 3a 3a 63 61 6c 6c 62 61 63 6b 5c 66 Btls::callback\f
9a70: 52 2c 20 5c 66 42 74 6c 73 3a 3a 70 61 73 73 77 R, \fBtls::passw
9a80: 6f 72 64 5c 66 52 2c 20 61 6e 64 0a 5c 66 42 74 ord\fR, and.\fBt
9a90: 6c 73 3a 3a 76 61 6c 69 64 61 74 65 5f 63 6f 6d ls::validate_com
9aa0: 6d 61 6e 64 5c 66 52 20 64 65 66 61 75 6c 74 20 mand\fR default
9ab0: 68 61 6e 64 6c 65 72 73 20 69 6e 20 22 5c 66 49 handlers in "\fI
9ac0: 74 6c 73 5c 26 2e 74 63 6c 5c 66 52 22 5c 26 2e tls\&.tcl\fR"\&.
9ad0: 0a 54 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c .The default val
9ae0: 75 65 20 69 73 20 30 20 77 69 74 68 20 68 69 67 ue is 0 with hig
9af0: 68 65 72 20 76 61 6c 75 65 73 20 70 72 6f 64 75 her values produ
9b00: 63 69 6e 67 20 6d 6f 72 65 20 64 69 61 67 6e 6f cing more diagno
9b10: 73 74 69 63 20 6f 75 74 70 75 74 2c 0a 61 6e 64 stic output,.and
9b20: 20 77 69 6c 6c 20 61 6c 73 6f 20 66 6f 72 63 65 will also force
9b30: 20 74 68 65 20 76 65 72 69 66 79 20 6d 65 74 68 the verify meth
9b40: 6f 64 20 69 6e 20 5c 66 42 74 6c 73 3a 3a 63 61 od in \fBtls::ca
9b50: 6c 6c 62 61 63 6b 5c 66 52 20 74 6f 20 61 63 63 llback\fR to acc
9b60: 65 70 74 20 74 68 65 0a 63 65 72 74 69 66 69 63 ept the.certific
9b70: 61 74 65 2c 20 65 76 65 6e 20 69 66 20 69 74 20 ate, even if it
9b80: 69 73 20 69 6e 76 61 6c 69 64 20 77 68 65 6e 20 is invalid when
9b90: 74 68 65 20 5c 66 42 2d 76 61 6c 69 64 61 74 65 the \fB-validate
9ba0: 63 6f 6d 6d 61 6e 64 5c 66 52 0a 6f 70 74 69 6f command\fR.optio
9bb0: 6e 20 69 73 20 73 65 74 20 74 6f 20 5c 66 42 74 n is set to \fBt
9bc0: 6c 73 3a 3a 76 61 6c 69 64 61 74 65 5f 63 6f 6d ls::validate_com
9bd0: 6d 61 6e 64 5c 66 52 5c 26 2e 0a 2e 50 50 0a 5c mand\fR\&...PP.\
9be0: 66 49 54 68 65 20 75 73 65 20 6f 66 20 74 68 65 fIThe use of the
9bf0: 20 76 61 72 69 61 62 6c 65 20 5c 66 42 74 6c 73 variable \fBtls
9c00: 3a 3a 64 65 62 75 67 5c 66 52 20 69 73 20 6e 6f ::debug\fR is no
9c10: 74 20 72 65 63 6f 6d 6d 65 6e 64 65 64 5c 26 2e t recommended\&.
9c20: 0a 49 74 20 6d 61 79 20 62 65 20 72 65 6d 6f 76 .It may be remov
9c30: 65 64 20 66 72 6f 6d 20 66 75 74 75 72 65 20 72 ed from future r
9c40: 65 6c 65 61 73 65 73 5c 26 2e 5c 66 52 0a 2e 53 eleases\&.\fR..S
9c50: 48 20 22 48 54 54 50 20 50 41 43 4b 41 47 45 20 H "HTTP PACKAGE
9c60: 45 58 41 4d 50 4c 45 53 22 0a 54 68 65 20 66 6f EXAMPLES".The fo
9c70: 6c 6c 6f 77 69 6e 67 20 61 72 65 20 65 78 61 6d llowing are exam
9c80: 70 6c 65 20 73 63 72 69 70 74 73 20 74 6f 20 64 ple scripts to d
9c90: 6f 77 6e 6c 6f 61 64 20 61 20 77 65 62 70 61 67 ownload a webpag
9ca0: 65 20 61 6e 64 20 66 69 6c 65 20 75 73 69 6e 67 e and file using
9cb0: 20 74 68 65 0a 68 74 74 70 20 70 61 63 6b 61 67 the.http packag
9cc0: 65 5c 26 2e 20 53 65 65 20 5c 66 42 43 65 72 74 e\&. See \fBCert
9cd0: 69 66 69 63 61 74 65 20 56 61 6c 69 64 61 74 69 ificate Validati
9ce0: 6f 6e 5c 66 52 20 66 6f 72 20 77 68 65 74 68 65 on\fR for whethe
9cf0: 72 20 74 68 65 0a 5c 66 42 2d 63 61 64 69 72 5c r the.\fB-cadir\
9d00: 66 52 2c 20 5c 66 42 2d 63 61 66 69 6c 65 5c 66 fR, \fB-cafile\f
9d10: 52 2c 20 61 6e 64 20 5c 66 42 2d 63 61 73 74 6f R, and \fB-casto
9d20: 72 65 5c 66 52 20 6f 70 74 69 6f 6e 73 20 61 72 re\fR options ar
9d30: 65 20 61 6c 73 6f 0a 6e 65 65 64 65 64 5c 26 2e e also.needed\&.
9d40: 20 53 65 65 20 74 68 65 20 64 65 6d 6f 73 20 64 See the demos d
9d50: 69 72 65 63 74 6f 72 79 20 66 6f 72 20 6d 6f 72 irectory for mor
9d60: 65 20 65 78 61 6d 70 6c 65 20 73 63 72 69 70 74 e example script
9d70: 73 5c 26 2e 0a 2e 50 50 0a 45 78 61 6d 70 6c 65 s\&...PP.Example
9d80: 20 23 31 3a 20 44 6f 77 6e 6c 6f 61 64 20 61 20 #1: Download a
9d90: 77 65 62 20 70 61 67 65 0a 2e 43 53 0a 0a 0a 0a web page..CS....
9da0: 70 61 63 6b 61 67 65 20 72 65 71 75 69 72 65 20 package require
9db0: 68 74 74 70 0a 70 61 63 6b 61 67 65 20 72 65 71 http.package req
9dc0: 75 69 72 65 20 74 6c 73 0a 0a 73 65 74 20 75 72 uire tls..set ur
9dd0: 6c 20 22 68 74 74 70 73 3a 2f 2f 77 77 77 5c 26 l "https://www\&
9de0: 2e 74 63 6c 5c 26 2e 74 6b 2f 22 0a 68 74 74 70 .tcl\&.tk/".http
9df0: 3a 3a 72 65 67 69 73 74 65 72 20 68 74 74 70 73 ::register https
9e00: 20 34 34 33 20 5b 6c 69 73 74 20 3a 3a 74 6c 73 443 [list ::tls
9e10: 3a 3a 73 6f 63 6b 65 74 20 2d 61 75 74 6f 73 65 ::socket -autose
9e20: 72 76 65 72 6e 61 6d 65 20 31 20 2d 72 65 71 75 rvername 1 -requ
9e30: 69 72 65 20 31 5d 0a 0a 23 20 47 65 74 20 55 52 ire 1]..# Get UR
9e40: 4c 0a 73 65 74 20 74 6f 6b 65 6e 20 5b 68 74 74 L.set token [htt
9e50: 70 3a 3a 67 65 74 75 72 6c 20 24 75 72 6c 5d 0a p::geturl $url].
9e60: 0a 23 20 43 68 65 63 6b 20 66 6f 72 20 65 72 72 .# Check for err
9e70: 6f 72 0a 69 66 20 7b 5b 68 74 74 70 3a 3a 73 74 or.if {[http::st
9e80: 61 74 75 73 20 24 74 6f 6b 65 6e 5d 20 6e 65 20 atus $token] ne
9e90: 22 6f 6b 22 7d 20 7b 0a 20 20 20 20 70 75 74 73 "ok"} {. puts
9ea0: 20 5b 66 6f 72 6d 61 74 20 22 45 72 72 6f 72 20 [format "Error
9eb0: 25 73 22 20 5b 68 74 74 70 3a 3a 73 74 61 74 75 %s" [http::statu
9ec0: 73 20 24 74 6f 6b 65 6e 5d 5d 0a 7d 0a 0a 23 20 s $token]].}..#
9ed0: 53 61 76 65 20 77 65 62 20 70 61 67 65 20 74 6f Save web page to
9ee0: 20 66 69 6c 65 0a 73 65 74 20 63 68 20 5b 6f 70 file.set ch [op
9ef0: 65 6e 20 65 78 61 6d 70 6c 65 5c 26 2e 68 74 6d en example\&.htm
9f00: 6c 20 77 62 5d 0a 70 75 74 73 20 24 63 68 20 5b l wb].puts $ch [
9f10: 68 74 74 70 3a 3a 64 61 74 61 20 24 74 6f 6b 65 http::data $toke
9f20: 6e 5d 0a 63 6c 6f 73 65 20 24 63 68 0a 0a 23 20 n].close $ch..#
9f30: 43 6c 65 61 6e 75 70 0a 3a 3a 68 74 74 70 3a 3a Cleanup.::http::
9f40: 63 6c 65 61 6e 75 70 20 24 74 6f 6b 65 6e 0a 0a cleanup $token..
9f50: 2e 43 45 0a 45 78 61 6d 70 6c 65 20 23 32 3a 20 .CE.Example #2:
9f60: 44 6f 77 6e 6c 6f 61 64 20 61 20 66 69 6c 65 0a Download a file.
9f70: 2e 43 53 0a 0a 0a 0a 70 61 63 6b 61 67 65 20 72 .CS....package r
9f80: 65 71 75 69 72 65 20 68 74 74 70 0a 70 61 63 6b equire http.pack
9f90: 61 67 65 20 72 65 71 75 69 72 65 20 74 6c 73 0a age require tls.
9fa0: 0a 73 65 74 20 75 72 6c 20 22 68 74 74 70 73 3a .set url "https:
9fb0: 2f 2f 77 69 6b 69 5c 26 2e 74 63 6c 2d 6c 61 6e //wiki\&.tcl-lan
9fc0: 67 5c 26 2e 6f 72 67 2f 73 69 74 65 6d 61 70 5c g\&.org/sitemap\
9fd0: 26 2e 78 6d 6c 22 0a 68 74 74 70 3a 3a 72 65 67 &.xml".http::reg
9fe0: 69 73 74 65 72 20 68 74 74 70 73 20 34 34 33 20 ister https 443
9ff0: 5b 6c 69 73 74 20 3a 3a 74 6c 73 3a 3a 73 6f 63 [list ::tls::soc
a000: 6b 65 74 20 2d 61 75 74 6f 73 65 72 76 65 72 6e ket -autoservern
a010: 61 6d 65 20 31 20 2d 72 65 71 75 69 72 65 20 31 ame 1 -require 1
a020: 5d 0a 0a 23 20 4f 70 65 6e 20 6f 75 74 70 75 74 ]..# Open output
a030: 20 66 69 6c 65 0a 73 65 74 20 66 69 6c 65 6e 61 file.set filena
a040: 6d 65 20 5b 66 69 6c 65 20 74 61 69 6c 20 24 75 me [file tail $u
a050: 72 6c 5d 0a 73 65 74 20 63 68 20 5b 6f 70 65 6e rl].set ch [open
a060: 20 24 66 69 6c 65 6e 61 6d 65 20 77 62 5d 0a 0a $filename wb]..
a070: 23 20 47 65 74 20 66 69 6c 65 0a 73 65 74 20 74 # Get file.set t
a080: 6f 6b 65 6e 20 5b 3a 3a 68 74 74 70 3a 3a 67 65 oken [::http::ge
a090: 74 75 72 6c 20 24 75 72 6c 20 2d 62 6c 6f 63 6b turl $url -block
a0a0: 73 69 7a 65 20 36 35 35 33 36 20 2d 63 68 61 6e size 65536 -chan
a0b0: 6e 65 6c 20 24 63 68 5d 0a 0a 23 20 43 68 65 63 nel $ch]..# Chec
a0c0: 6b 20 66 6f 72 20 65 72 72 6f 72 0a 69 66 20 7b k for error.if {
a0d0: 5b 68 74 74 70 3a 3a 73 74 61 74 75 73 20 24 74 [http::status $t
a0e0: 6f 6b 65 6e 5d 20 6e 65 20 22 6f 6b 22 7d 20 7b oken] ne "ok"} {
a0f0: 0a 20 20 20 20 70 75 74 73 20 5b 66 6f 72 6d 61 . puts [forma
a100: 74 20 22 45 72 72 6f 72 20 25 73 22 20 5b 68 74 t "Error %s" [ht
a110: 74 70 3a 3a 73 74 61 74 75 73 20 24 74 6f 6b 65 tp::status $toke
a120: 6e 5d 5d 0a 7d 0a 0a 23 20 43 6c 65 61 6e 75 70 n]].}..# Cleanup
a130: 0a 63 6c 6f 73 65 20 24 63 68 0a 3a 3a 68 74 74 .close $ch.::htt
a140: 70 3a 3a 63 6c 65 61 6e 75 70 20 24 74 6f 6b 65 p::cleanup $toke
a150: 6e 0a 0a 2e 43 45 0a 2e 53 48 20 22 53 50 45 43 n...CE..SH "SPEC
a160: 49 41 4c 20 43 4f 4e 53 49 44 45 52 41 54 49 4f IAL CONSIDERATIO
a170: 4e 53 22 0a 54 68 65 20 63 61 70 61 62 69 6c 69 NS".The capabili
a180: 74 69 65 73 20 6f 66 20 74 68 69 73 20 70 61 63 ties of this pac
a190: 6b 61 67 65 20 63 61 6e 20 76 61 72 79 20 65 6e kage can vary en
a1a0: 6f 72 6d 6f 75 73 6c 79 20 62 61 73 65 64 20 75 ormously based u
a1b0: 70 6f 6e 20 68 6f 77 20 74 68 65 0a 6c 69 6e 6b pon how the.link
a1c0: 65 64 20 74 6f 20 4f 70 65 6e 53 53 4c 20 6c 69 ed to OpenSSL li
a1d0: 62 72 61 72 79 20 77 61 73 20 63 6f 6e 66 69 67 brary was config
a1e0: 75 72 65 64 20 61 6e 64 20 62 75 69 6c 74 5c 26 ured and built\&
a1f0: 2e 20 4e 65 77 20 76 65 72 73 69 6f 6e 73 20 6d . New versions m
a200: 61 79 20 6f 62 73 6f 6c 65 74 65 0a 6f 6c 64 65 ay obsolete.olde
a210: 72 20 70 72 6f 74 6f 63 6f 6c 20 76 65 72 73 69 r protocol versi
a220: 6f 6e 73 2c 20 61 64 64 20 6f 72 20 72 65 6d 6f ons, add or remo
a230: 76 65 20 63 69 70 68 65 72 73 2c 20 63 68 61 6e ve ciphers, chan
a240: 67 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 ge default value
a250: 73 2c 20 65 74 63 5c 26 2e 0a 55 73 65 20 74 68 s, etc\&..Use th
a260: 65 20 5c 66 42 74 6c 73 3a 3a 70 72 6f 74 6f 63 e \fBtls::protoc
a270: 6f 6c 73 5c 66 52 20 63 6f 6d 6d 61 6e 64 73 20 ols\fR commands
a280: 74 6f 20 6f 62 74 61 69 6e 20 74 68 65 20 73 75 to obtain the su
a290: 70 70 6f 72 74 65 64 0a 70 72 6f 74 6f 63 6f 6c pported.protocol
a2a0: 20 76 65 72 73 69 6f 6e 73 5c 26 2e 0a 2e 53 48 versions\&...SH
a2b0: 20 22 53 45 45 20 41 4c 53 4f 22 0a 5c 66 49 4f "SEE ALSO".\fIO
a2c0: 70 65 6e 53 53 4c 5c 66 52 20 5b 68 74 74 70 73 penSSL\fR [https
a2d0: 3a 2f 2f 77 77 77 5c 26 2e 6f 70 65 6e 73 73 6c ://www\&.openssl
a2e0: 5c 26 2e 6f 72 67 2f 5d 2c 20 68 74 74 70 2c 20 \&.org/], http,
a2f0: 73 6f 63 6b 65 74 0a 2e 53 48 20 4b 45 59 57 4f socket..SH KEYWO
a300: 52 44 53 0a 49 2f 4f 2c 20 49 50 20 41 64 64 72 RDS.I/O, IP Addr
a310: 65 73 73 2c 20 4f 70 65 6e 53 53 4c 2c 20 53 53 ess, OpenSSL, SS
a320: 4c 2c 20 54 43 50 2c 20 54 4c 53 2c 20 54 63 6c L, TCP, TLS, Tcl
a330: 54 4c 53 2c 20 61 73 79 6e 63 68 72 6f 6e 6f 75 TLS, asynchronou
a340: 73 20 49 2f 4f 2c 20 62 69 6e 64 2c 20 63 65 72 s I/O, bind, cer
a350: 74 69 66 69 63 61 74 65 2c 20 63 68 61 6e 6e 65 tificate, channe
a360: 6c 2c 20 63 6f 6e 6e 65 63 74 69 6f 6e 2c 20 64 l, connection, d
a370: 6f 6d 61 69 6e 20 6e 61 6d 65 2c 20 68 6f 73 74 omain name, host
a380: 2c 20 68 74 74 70 73 2c 20 6e 65 74 77 6f 72 6b , https, network
a390: 2c 20 6e 65 74 77 6f 72 6b 20 61 64 64 72 65 73 , network addres
a3a0: 73 2c 20 73 6f 63 6b 65 74 2c 20 74 6c 73 0a 2e s, socket, tls..
a3b0: 53 48 20 43 41 54 45 47 4f 52 59 0a 74 6c 73 0a SH CATEGORY.tls.
a3c0: 2e 53 48 20 43 4f 50 59 52 49 47 48 54 0a 2e 6e .SH COPYRIGHT..n
a3d0: 66 0a 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 f.Copyright (c)
a3e0: 31 39 39 39 20 4d 61 74 74 20 4e 65 77 6d 61 6e 1999 Matt Newman
a3f0: 0a 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 .Copyright (c) 2
a400: 30 30 34 20 53 74 61 72 66 69 73 68 20 53 79 73 004 Starfish Sys
a410: 74 65 6d 73 0a 43 6f 70 79 72 69 67 68 74 20 28 tems.Copyright (
a420: 63 29 20 32 30 32 34 20 42 72 69 61 6e 20 4f 27 c) 2024 Brian O'
a430: 48 61 67 61 6e 0a 0a 2e 66 69 0a Hagan...fi.