Hex Artifact Content

Artifact bfc5627b80617e387648c308bf54771710927489:


0000: 32 30 30 34 2d 30 33 2d 31 37 20 20 44 61 6e 20  2004-03-17  Dan 
0010: 52 61 7a 7a 65 6c 6c 20 3c 72 65 73 65 61 72 63  Razzell <researc
0020: 68 40 73 74 61 72 66 69 73 68 73 79 73 74 65 6d  h@starfishsystem
0030: 73 2e 63 61 3e 0a 0a 09 2a 20 74 6c 73 58 35 30  s.ca>...* tlsX50
0040: 39 2e 63 3a 09 41 64 64 20 73 75 70 70 6f 72 74  9.c:.Add support
0050: 20 66 6f 72 20 6c 6f 6e 67 20 73 65 72 69 61 6c   for long serial
0060: 20 6e 75 6d 62 65 72 73 20 70 65 72 20 52 46 43   numbers per RFC
0070: 20 33 32 38 30 2e 0a 09 09 09 46 6f 72 6d 61 74   3280.....Format
0080: 20 69 73 20 6e 6f 77 20 68 65 78 61 64 65 63 69   is now hexadeci
0090: 6d 61 6c 2e 20 0a 09 09 09 5b 52 65 71 75 65 73  mal. ....[Reques
00a0: 74 20 23 39 31 35 33 31 33 5d 0a 09 09 09 43 6f  t #915313]....Co
00b0: 72 72 65 63 74 6c 79 20 63 6f 6e 76 65 72 74 20  rrectly convert 
00c0: 63 65 72 74 69 66 69 63 61 74 65 20 44 69 73 74  certificate Dist
00d0: 69 6e 67 75 69 73 68 65 64 20 4e 61 6d 65 73 0a  inguished Names.
00e0: 09 09 09 74 6f 20 54 63 6c 20 73 74 72 69 6e 67  ...to Tcl string
00f0: 20 72 65 70 72 65 73 65 6e 74 61 74 69 6f 6e 2e   representation.
0100: 20 20 45 6c 69 6d 69 6e 61 74 65 73 20 75 73 65    Eliminates use
0110: 20 6f 66 0a 09 09 09 64 65 70 72 65 63 61 74 65   of....deprecate
0120: 64 20 4f 70 65 6e 53 53 4c 20 66 75 6e 63 74 69  d OpenSSL functi
0130: 6f 6e 2e 20 20 46 6f 72 6d 61 74 20 69 73 20 6e  on.  Format is n
0140: 6f 77 20 63 6f 6d 70 6c 69 61 6e 74 0a 09 09 09  ow compliant....
0150: 77 69 74 68 20 52 46 43 20 32 32 35 33 2e 20 20  with RFC 2253.  
0160: 5b 52 65 71 75 65 73 74 20 23 39 31 35 33 31 35  [Request #915315
0170: 5d 0a 0a 32 30 30 34 2d 30 32 2d 31 37 20 20 44  ]..2004-02-17  D
0180: 61 6e 20 52 61 7a 7a 65 6c 6c 20 3c 72 65 73 65  an Razzell <rese
0190: 61 72 63 68 40 73 74 61 72 66 69 73 68 73 79 73  arch@starfishsys
01a0: 74 65 6d 73 2e 63 61 3e 0a 0a 09 54 4c 53 20 31  tems.ca>...TLS 1
01b0: 2e 35 2e 30 20 52 45 4c 45 41 53 45 0a 0a 32 30  .5.0 RELEASE..20
01c0: 30 34 2d 30 32 2d 31 32 20 20 44 61 6e 20 52 61  04-02-12  Dan Ra
01d0: 7a 7a 65 6c 6c 09 3c 72 65 73 65 61 72 63 68 40  zzell.<research@
01e0: 73 74 61 72 66 69 73 68 73 79 73 74 65 6d 73 2e  starfishsystems.
01f0: 63 61 3e 0a 0a 09 2a 20 74 6c 73 2e 63 3a 09 41  ca>...* tls.c:.A
0200: 6c 6c 6f 77 20 76 65 72 69 66 79 20 63 61 6c 6c  llow verify call
0210: 62 61 63 6b 20 74 6f 20 72 65 74 75 72 6e 20 65  back to return e
0220: 6d 70 74 79 20 72 65 73 75 6c 74 2e 0a 09 2a 20  mpty result...* 
0230: 74 6c 73 2e 68 74 6d 3a 09 44 6f 63 75 6d 65 6e  tls.htm:.Documen
0240: 74 20 63 61 6c 6c 62 61 63 6b 20 62 65 68 61 76  t callback behav
0250: 69 6f 72 73 2e 0a 0a 32 30 30 34 2d 30 32 2d 31  iors...2004-02-1
0260: 31 20 20 44 61 6e 20 52 61 7a 7a 65 6c 6c 09 3c  1  Dan Razzell.<
0270: 72 65 73 65 61 72 63 68 40 73 74 61 72 66 69 73  research@starfis
0280: 68 73 79 73 74 65 6d 73 2e 63 61 3e 0a 0a 09 2a  hsystems.ca>...*
0290: 20 74 65 73 74 73 2f 74 6c 73 49 4f 2e 74 65 73   tests/tlsIO.tes
02a0: 74 3a 0a 09 2a 20 72 65 6d 6f 74 65 2e 74 63 6c  t:..* remote.tcl
02b0: 3a 09 43 6f 6d 70 6c 65 74 65 20 70 72 69 76 61  :.Complete priva
02c0: 74 65 20 6b 65 79 20 6e 61 6d 65 20 63 68 61 6e  te key name chan
02d0: 67 65 73 20 66 72 6f 6d 20 32 30 30 31 2d 30 36  ges from 2001-06
02e0: 2d 32 31 2e 0a 0a 32 30 30 34 2d 30 32 2d 30 33  -21...2004-02-03
02f0: 20 20 44 61 6e 20 52 61 7a 7a 65 6c 6c 20 3c 72    Dan Razzell <r
0300: 65 73 65 61 72 63 68 40 73 74 61 72 66 69 73 68  esearch@starfish
0310: 73 79 73 74 65 6d 73 2e 63 61 3e 0a 0a 09 2a 20  systems.ca>...* 
0320: 4d 61 6b 65 66 69 6c 65 2e 69 6e 3a 09 52 65 6d  Makefile.in:.Rem
0330: 6f 76 65 64 20 63 69 72 63 75 6c 61 72 20 64 65  oved circular de
0340: 70 65 6e 64 65 6e 63 79 2e 0a 09 2a 20 74 6c 73  pendency...* tls
0350: 49 6e 74 2e 68 3a 09 4d 61 6b 65 20 66 75 6e 63  Int.h:.Make func
0360: 74 69 6f 6e 20 64 65 63 6c 61 72 61 74 69 6f 6e  tion declaration
0370: 73 20 65 78 70 6c 69 63 69 74 2e 0a 09 2a 20 74  s explicit...* t
0380: 6c 73 2e 63 3a 09 46 69 78 20 74 79 70 65 20 6d  ls.c:.Fix type m
0390: 61 74 63 68 20 61 6e 64 20 75 6e 75 73 65 64 20  atch and unused 
03a0: 76 61 72 69 61 62 6c 65 20 77 61 72 6e 69 6e 67  variable warning
03b0: 73 2e 0a 09 2a 20 74 6c 73 42 49 4f 2e 63 3a 09  s...* tlsBIO.c:.
03c0: 46 69 78 20 74 79 70 65 20 6d 61 74 63 68 20 77  Fix type match w
03d0: 61 72 6e 69 6e 67 2e 0a 0a 32 30 30 33 2d 31 32  arning...2003-12
03e0: 2d 31 35 20 20 44 61 6e 20 52 61 7a 7a 65 6c 6c  -15  Dan Razzell
03f0: 09 3c 72 65 73 65 61 72 63 68 40 73 74 61 72 66  .<research@starf
0400: 69 73 68 73 79 73 74 65 6d 73 2e 63 61 3e 0a 0a  ishsystems.ca>..
0410: 09 2a 20 70 6b 67 49 6e 64 65 78 2e 74 63 6c 2e  .* pkgIndex.tcl.
0420: 69 6e 3a 0a 09 2a 20 74 6c 73 2e 68 74 6d 3a 0a  in:..* tls.htm:.
0430: 09 2a 20 74 65 73 74 73 2f 74 6c 73 49 4f 2e 74  .* tests/tlsIO.t
0440: 65 73 74 3a 20 75 70 64 61 74 65 64 20 76 65 72  est: updated ver
0450: 73 69 6f 6e 20 74 6f 20 31 2e 35 2e 0a 0a 32 30  sion to 1.5...20
0460: 30 33 2d 31 30 2d 30 37 20 20 44 61 6e 20 52 61  03-10-07  Dan Ra
0470: 7a 7a 65 6c 6c 09 3c 72 65 73 65 61 72 63 68 40  zzell.<research@
0480: 73 74 61 72 66 69 73 68 73 79 73 74 65 6d 73 2e  starfishsystems.
0490: 63 61 3e 0a 0a 09 2a 20 74 65 73 74 73 2f 63 69  ca>...* tests/ci
04a0: 70 68 65 72 73 2e 74 65 73 74 3a 20 75 70 64 61  phers.test: upda
04b0: 74 65 64 20 6c 69 73 74 20 6f 66 20 74 65 73 74  ted list of test
04c0: 65 64 20 63 69 70 68 65 72 73 20 74 6f 20 63 6f  ed ciphers to co
04d0: 72 72 65 73 70 6f 6e 64 0a 09 2a 20 77 69 74 68  rrespond..* with
04e0: 20 74 68 6f 73 65 20 61 76 61 69 6c 61 62 6c 65   those available
04f0: 20 66 72 6f 6d 20 4f 70 65 6e 53 53 4c 2e 20 5b   from OpenSSL. [
0500: 52 65 71 75 65 73 74 20 23 38 31 31 39 38 31 5d  Request #811981]
0510: 0a 0a 32 30 30 33 2d 31 30 2d 30 37 20 20 44 61  ..2003-10-07  Da
0520: 6e 20 52 61 7a 7a 65 6c 6c 20 3c 72 65 73 65 61  n Razzell <resea
0530: 72 63 68 40 73 74 61 72 66 69 73 68 73 79 73 74  rch@starfishsyst
0540: 65 6d 73 2e 63 61 3e 0a 0a 09 2a 20 74 6c 73 2e  ems.ca>...* tls.
0550: 63 3a 20 61 64 64 65 64 20 43 4f 4e 53 54 20 77  c: added CONST w
0560: 69 74 68 20 69 6e 74 65 6e 74 20 73 69 6d 69 6c  ith intent simil
0570: 61 72 20 74 6f 20 74 68 6f 73 65 20 66 72 6f 6d  ar to those from
0580: 20 32 30 30 32 2d 30 32 2d 30 34 2e 0a 09 5b 52   2002-02-04...[R
0590: 65 71 75 65 73 74 20 23 38 31 31 39 31 31 5d 0a  equest #811911].
05a0: 0a 32 30 30 33 2d 30 37 2d 30 37 20 20 4a 65 66  .2003-07-07  Jef
05b0: 66 20 48 6f 62 62 73 20 20 3c 6a 65 66 66 68 40  f Hobbs  <jeffh@
05c0: 41 63 74 69 76 65 53 74 61 74 65 2e 63 6f 6d 3e  ActiveState.com>
05d0: 0a 0a 09 2a 20 74 6c 73 2e 63 20 28 54 6c 73 5f  ...* tls.c (Tls_
05e0: 49 6e 69 74 29 3a 20 20 20 61 64 64 65 64 20 74  Init):   added t
05f0: 6c 73 3a 3a 6d 69 73 63 20 63 6f 6d 6d 61 6e 64  ls::misc command
0600: 20 70 72 6f 76 69 64 65 64 20 62 79 0a 09 2a 20   provided by..* 
0610: 74 6c 73 58 35 30 39 2e 63 3a 20 20 20 20 20 20  tlsX509.c:      
0620: 20 20 20 20 57 6f 6a 63 69 65 63 68 20 4b 6f 63      Wojciech Koc
0630: 6a 61 6e 20 28 77 6f 6a 63 69 65 63 68 20 6b 6f  jan (wojciech ko
0640: 63 6a 61 6e 2e 6f 72 67 29 0a 09 2a 20 74 65 73  cjan.org)..* tes
0650: 74 73 2f 6b 65 79 74 65 73 74 31 2e 74 63 6c 3a  ts/keytest1.tcl:
0660: 20 74 6f 20 65 78 70 6f 73 65 20 6d 6f 72 65 20   to expose more 
0670: 6c 6f 77 2d 6c 65 76 65 6c 20 53 53 4c 20 63 6f  low-level SSL co
0680: 6d 6d 61 6e 64 73 0a 09 2a 20 74 65 73 74 73 2f  mmands..* tests/
0690: 6b 65 79 74 65 73 74 32 2e 74 63 6c 3a 0a 0a 32  keytest2.tcl:..2
06a0: 30 30 33 2d 30 35 2d 31 35 20 20 44 61 6e 20 52  003-05-15  Dan R
06b0: 61 7a 7a 65 6c 6c 09 3c 72 65 73 65 61 72 63 68  azzell.<research
06c0: 40 73 74 61 72 66 69 73 68 73 79 73 74 65 6d 73  @starfishsystems
06d0: 2e 63 61 3e 20 0a 0a 09 2a 20 74 6c 73 2e 74 63  .ca> ...* tls.tc
06e0: 6c 3a 0a 09 2a 20 74 6c 73 49 6e 74 2e 68 3a 0a  l:..* tlsInt.h:.
06f0: 09 2a 20 74 6c 73 2e 63 3a 20 61 64 64 20 73 75  .* tls.c: add su
0700: 70 70 6f 72 74 20 66 6f 72 20 62 69 6e 64 69 6e  pport for bindin
0710: 67 20 61 20 70 61 73 73 77 6f 72 64 20 63 61 6c  g a password cal
0720: 6c 62 61 63 6b 20 74 6f 20 74 68 65 20 73 6f 63  lback to the soc
0730: 6b 65 74 2e 0a 09 4e 6f 77 20 65 61 63 68 20 73  ket...Now each s
0740: 6f 63 6b 65 74 20 63 61 6e 20 68 61 76 65 20 69  ocket can have i
0750: 74 73 20 6f 77 6e 20 63 6f 6d 6d 61 6e 64 20 61  ts own command a
0760: 6e 64 20 70 61 73 73 77 6f 72 64 20 63 61 6c 6c  nd password call
0770: 62 61 63 6b 73 20 69 6e 73 74 65 61 64 0a 09 6f  backs instead..o
0780: 66 20 62 65 69 6e 67 20 66 6f 72 63 65 64 20 74  f being forced t
0790: 6f 20 68 61 76 65 20 61 6c 6c 20 70 61 73 73 77  o have all passw
07a0: 6f 72 64 20 6d 61 6e 61 67 65 6d 65 6e 74 20 70  ord management p
07b0: 61 73 73 20 74 68 72 6f 75 67 68 20 61 20 63 6f  ass through a co
07c0: 6d 6d 6f 6e 0a 09 70 72 6f 63 65 64 75 72 65 2e  mmon..procedure.
07d0: 20 20 54 68 65 20 63 6f 6d 6d 6f 6e 20 70 61 73    The common pas
07e0: 73 77 6f 72 64 20 70 72 6f 63 65 64 75 72 65 20  sword procedure 
07f0: 69 73 20 72 65 74 61 69 6e 65 64 20 66 6f 72 20  is retained for 
0800: 63 6f 6d 70 61 74 69 62 69 6c 69 74 79 0a 09 62  compatibility..b
0810: 75 74 20 69 74 73 20 75 73 65 20 73 68 6f 75 6c  ut its use shoul
0820: 64 20 62 65 20 44 45 50 52 45 43 41 54 45 44 2e  d be DEPRECATED.
0830: 0a 09 41 64 64 20 76 65 72 73 69 6f 6e 20 63 6f  ..Add version co
0840: 6d 6d 61 6e 64 20 74 6f 20 72 65 74 75 72 6e 20  mmand to return 
0850: 4f 70 65 6e 53 53 4c 20 76 65 72 73 69 6f 6e 20  OpenSSL version 
0860: 73 74 72 69 6e 67 2e 0a 09 52 65 6d 6f 76 65 20  string...Remove 
0870: 75 6e 73 74 61 62 6c 65 20 77 6f 72 6b 61 72 6f  unstable workaro
0880: 75 6e 64 73 20 6e 65 65 64 65 64 20 66 6f 72 20  unds needed for 
0890: 76 65 72 69 66 79 20 69 6e 20 6f 62 73 6f 6c 65  verify in obsole
08a0: 74 65 20 76 65 72 73 69 6f 6e 73 20 6f 66 0a 09  te versions of..
08b0: 4f 70 65 6e 53 53 4c 2e 0a 09 46 69 78 20 6d 65  OpenSSL...Fix me
08c0: 6d 6f 72 79 20 6c 65 61 6b 2e 20 5b 52 65 71 75  mory leak. [Requ
08d0: 65 73 74 20 23 36 34 30 36 36 30 5d 0a 09 4d 6f  est #640660]..Mo
08e0: 72 65 20 63 61 73 74 73 20 74 6f 20 65 6c 69 6d  re casts to elim
08f0: 69 6e 61 74 65 20 63 6f 6d 70 69 6c 65 72 20 77  inate compiler w
0900: 61 72 6e 69 6e 67 73 2e 0a 0a 09 2a 20 74 6c 73  arnings....* tls
0910: 2e 68 74 6d 3a 20 64 6f 63 75 6d 65 6e 74 20 70  .htm: document p
0920: 61 73 73 77 6f 72 64 20 63 61 6c 6c 62 61 63 6b  assword callback
0930: 2e 0a 09 43 6f 72 72 65 63 74 20 74 65 63 68 6e  ...Correct techn
0940: 69 63 61 6c 20 61 6e 64 20 74 79 70 6f 67 72 61  ical and typogra
0950: 70 68 69 63 20 65 72 72 6f 72 73 2e 0a 0a 09 2a  phic errors....*
0960: 20 52 45 41 44 4d 45 2e 74 78 74 3a 20 69 64 65   README.txt: ide
0970: 6e 74 69 66 79 20 76 65 72 73 69 6f 6e 73 20 6f  ntify versions o
0980: 66 20 4f 70 65 6e 53 53 4c 20 77 68 69 63 68 20  f OpenSSL which 
0990: 66 69 78 20 6b 6e 6f 77 6e 20 70 72 6f 62 6c 65  fix known proble
09a0: 6d 73 2e 0a 09 47 65 6e 65 72 61 6c 20 77 61 72  ms...General war
09b0: 6e 69 6e 67 20 6f 66 20 73 65 63 75 72 69 74 79  ning of security
09c0: 20 70 72 6f 62 6c 65 6d 73 20 69 6e 20 6f 6c 64   problems in old
09d0: 65 72 20 76 65 72 73 69 6f 6e 73 20 6f 66 20 4f  er versions of O
09e0: 70 65 6e 53 53 4c 2e 0a 0a 32 30 30 32 2d 30 32  penSSL...2002-02
09f0: 2d 30 34 20 20 4a 65 66 66 20 48 6f 62 62 73 20  -04  Jeff Hobbs 
0a00: 20 3c 6a 65 66 66 68 40 41 63 74 69 76 65 53 74   <jeffh@ActiveSt
0a10: 61 74 65 2e 63 6f 6d 3e 0a 0a 09 2a 20 74 6c 73  ate.com>...* tls
0a20: 2e 68 74 6d 3a 0a 09 2a 20 74 6c 73 2e 63 3a 20  .htm:..* tls.c: 
0a30: 61 64 64 65 64 20 73 75 70 70 6f 72 74 20 66 6f  added support fo
0a40: 72 20 6c 6f 63 61 6c 20 63 65 72 74 69 66 69 63  r local certific
0a50: 61 74 65 20 73 74 61 74 75 73 20 63 68 65 63 6b  ate status check
0a60: 2c 20 61 73 20 77 65 6c 6c 0a 09 61 73 20 72 65  , as well..as re
0a70: 74 75 72 6e 69 6e 67 20 74 68 65 20 23 20 6f 66  turning the # of
0a80: 20 62 69 74 73 20 69 6e 20 74 68 65 20 73 65 73   bits in the ses
0a90: 73 69 6f 6e 20 6b 65 79 2e 20 5b 50 61 74 63 68  sion key. [Patch
0aa0: 20 23 35 30 35 36 39 38 5d 20 28 72 6f 73 65 29   #505698] (rose)
0ab0: 0a 0a 09 2a 20 74 6c 73 2e 63 3a 0a 09 2a 20 74  ...* tls.c:..* t
0ac0: 6c 73 49 4f 2e 63 3a 0a 09 2a 20 74 6c 73 42 49  lsIO.c:..* tlsBI
0ad0: 4f 2e 63 3a 20 61 64 64 65 64 20 43 4f 4e 53 54  O.c: added CONST
0ae0: 73 20 74 6f 20 73 61 74 69 73 66 79 20 54 63 6c  s to satisfy Tcl
0af0: 20 38 2e 34 20 73 6f 75 72 63 65 73 2e 20 20 54   8.4 sources.  T
0b00: 68 69 73 20 6d 61 79 0a 09 67 69 76 65 20 77 61  his may..give wa
0b10: 72 6e 69 6e 67 73 20 77 68 65 6e 20 63 6f 6d 70  rnings when comp
0b20: 69 6c 65 64 20 61 67 61 69 6e 73 74 20 38 2e 33  iled against 8.3
0b30: 2c 20 62 75 74 20 74 68 65 79 20 63 61 6e 20 62  , but they can b
0b40: 65 20 69 67 6e 6f 72 65 64 2e 0a 0a 09 2a 20 74  e ignored....* t
0b50: 65 73 74 73 2f 73 69 6d 70 6c 65 43 6c 69 65 6e  ests/simpleClien
0b60: 74 2e 74 63 6c 3a 0a 09 2a 20 74 65 73 74 73 2f  t.tcl:..* tests/
0b70: 73 69 6d 70 6c 65 53 65 72 76 65 72 2e 74 63 6c  simpleServer.tcl
0b80: 3a 20 70 6f 69 6e 74 20 74 6f 20 75 70 64 61 74  : point to updat
0b90: 65 64 20 63 6c 69 65 6e 74 2f 73 65 72 76 65 72  ed client/server
0ba0: 20 6b 65 79 20 66 69 6c 65 73 2e 0a 0a 09 2a 20   key files....* 
0bb0: 74 65 73 74 73 2f 74 6c 73 49 4f 2e 74 65 73 74  tests/tlsIO.test
0bc0: 3a 0a 09 2a 20 74 65 73 74 73 2f 63 69 70 68 65  :..* tests/ciphe
0bd0: 72 73 2e 74 65 73 74 3a 20 75 70 64 61 74 65 64  rs.test: updated
0be0: 20 74 6f 20 6c 6f 61 64 20 74 6c 73 20 66 72 6f   to load tls fro
0bf0: 6d 20 62 75 69 6c 64 20 64 69 72 2e 0a 0a 09 2a  m build dir....*
0c00: 20 4d 61 6b 65 66 69 6c 65 2e 69 6e 3a 20 72 65   Makefile.in: re
0c10: 6d 6f 76 65 64 20 73 74 72 6e 63 61 73 65 63 6d  moved strncasecm
0c20: 70 20 66 72 6f 6d 20 64 65 66 61 75 6c 74 20 6f  p from default o
0c30: 62 6a 65 63 74 20 73 65 74 2e 20 20 54 68 69 73  bject set.  This
0c40: 0a 09 69 73 20 6f 6e 6c 79 20 6e 65 65 64 65 64  ..is only needed
0c50: 20 6f 6e 20 74 68 65 20 4d 61 63 2c 20 61 6e 64   on the Mac, and
0c60: 20 54 63 6c 20 73 74 75 62 73 20 70 72 6f 76 69   Tcl stubs provi
0c70: 64 65 73 20 69 74 2e 0a 0a 09 2a 20 63 6f 6e 66  des it....* conf
0c80: 69 67 75 72 65 3a 20 72 65 67 65 6e 27 65 64 2e  igure: regen'ed.
0c90: 0a 09 2a 20 63 6f 6e 66 69 67 75 72 65 2e 69 6e  ..* configure.in
0ca0: 3a 20 75 70 64 61 74 65 64 20 74 6f 20 31 2e 35  : updated to 1.5
0cb0: 2e 30 20 66 6f 72 20 6e 65 78 74 20 72 65 6c 65  .0 for next rele
0cc0: 61 73 65 2e 0a 09 43 68 61 6e 67 65 64 20 64 65  ase...Changed de
0cd0: 66 61 75 6c 74 20 6f 70 65 6e 73 73 6c 20 6c 6f  fault openssl lo
0ce0: 63 61 74 69 6f 6e 20 74 6f 20 2f 75 73 72 2f 6c  cation to /usr/l
0cf0: 6f 63 61 6c 2f 73 73 6c 20 28 74 68 69 73 20 69  ocal/ssl (this i
0d00: 73 20 77 68 65 72 65 0a 09 6f 70 65 6e 73 73 6c  s where..openssl
0d10: 20 30 2e 39 2e 36 63 20 69 6e 73 74 61 6c 6c 73   0.9.6c installs
0d20: 20 62 79 20 64 65 66 61 75 6c 74 29 2e 0a 09 43   by default)...C
0d30: 68 61 6e 67 65 64 20 74 6f 20 75 73 65 20 70 75  hanged to use pu
0d40: 62 6c 69 63 20 54 63 6c 20 68 65 61 64 65 72 73  blic Tcl headers
0d50: 20 28 70 72 69 76 61 74 65 20 6e 6f 74 20 6e 65   (private not ne
0d60: 65 64 65 64 29 2e 0a 0a 32 30 30 31 2d 30 36 2d  eded)...2001-06-
0d70: 32 31 20 20 4a 65 66 66 20 48 6f 62 62 73 20 20  21  Jeff Hobbs  
0d80: 3c 6a 65 66 66 68 40 41 63 74 69 76 65 53 74 61  <jeffh@ActiveSta
0d90: 74 65 2e 63 6f 6d 3e 0a 0a 09 54 4c 53 20 31 2e  te.com>...TLS 1.
0da0: 34 2e 31 20 52 45 4c 45 41 53 45 0a 0a 09 2a 20  4.1 RELEASE...* 
0db0: 63 6f 6e 66 69 67 75 72 65 3a 20 61 64 64 65 64  configure: added
0dc0: 20 63 6f 6e 66 69 67 75 72 65 20 74 6f 20 43 56   configure to CV
0dd0: 53 0a 09 2a 20 63 6f 6e 66 69 67 75 72 65 2e 69  S..* configure.i
0de0: 6e 3a 20 6d 6f 76 65 64 20 74 6f 20 70 61 74 63  n: moved to patc
0df0: 68 6c 65 76 65 6c 20 31 2e 34 2e 31 0a 0a 09 2a  hlevel 1.4.1...*
0e00: 20 4d 61 6b 65 66 69 6c 65 2e 69 6e 3a 20 63 6f   Makefile.in: co
0e10: 72 72 65 63 74 65 64 20 27 64 69 73 74 27 20 74  rrected 'dist' t
0e20: 61 72 67 65 74 0a 0a 09 2a 20 74 65 73 74 73 2f  arget...* tests/
0e30: 63 65 72 74 73 2f 66 69 6c 65 2e 73 72 6c 3a 0a  certs/file.srl:.
0e40: 09 2a 20 74 65 73 74 73 2f 63 65 72 74 73 2f 63  .* tests/certs/c
0e50: 61 2e 70 65 6d 3a 0a 09 2a 20 74 65 73 74 73 2f  a.pem:..* tests/
0e60: 63 65 72 74 73 2f 63 6c 69 65 6e 74 2e 6b 65 79  certs/client.key
0e70: 3a 0a 09 2a 20 74 65 73 74 73 2f 63 65 72 74 73  :..* tests/certs
0e80: 2f 63 6c 69 65 6e 74 2e 70 65 6d 3a 0a 09 2a 20  /client.pem:..* 
0e90: 74 65 73 74 73 2f 63 65 72 74 73 2f 63 6c 69 65  tests/certs/clie
0ea0: 6e 74 2e 72 65 71 3a 0a 09 2a 20 74 65 73 74 73  nt.req:..* tests
0eb0: 2f 63 65 72 74 73 2f 70 72 69 76 6b 65 79 2e 70  /certs/privkey.p
0ec0: 65 6d 3a 0a 09 2a 20 74 65 73 74 73 2f 63 65 72  em:..* tests/cer
0ed0: 74 73 2f 73 65 72 76 65 72 2e 6b 65 79 3a 0a 09  ts/server.key:..
0ee0: 2a 20 74 65 73 74 73 2f 63 65 72 74 73 2f 73 65  * tests/certs/se
0ef0: 72 76 65 72 2e 70 65 6d 3a 0a 09 2a 20 74 65 73  rver.pem:..* tes
0f00: 74 73 2f 63 65 72 74 73 2f 73 65 72 76 65 72 2e  ts/certs/server.
0f10: 72 65 71 3a 0a 09 2a 20 74 65 73 74 73 2f 63 65  req:..* tests/ce
0f20: 72 74 73 2f 63 61 63 65 72 74 2e 70 65 6d 3a 20  rts/cacert.pem: 
0f30: 72 65 70 6c 61 63 65 64 20 62 79 20 6e 65 77 20  replaced by new 
0f40: 63 61 2e 70 65 6d 0a 09 2a 20 74 65 73 74 73 2f  ca.pem..* tests/
0f50: 63 65 72 74 73 2f 73 6b 65 79 2e 70 65 6d 3a 20  certs/skey.pem: 
0f60: 72 65 70 6c 61 63 65 64 20 62 79 20 6e 65 77 20  replaced by new 
0f70: 73 65 72 76 65 72 2e 6b 65 79 0a 09 2a 20 74 65  server.key..* te
0f80: 73 74 73 2f 63 65 72 74 73 2f 63 6b 65 79 2e 70  sts/certs/ckey.p
0f90: 65 6d 3a 20 72 65 70 6c 61 63 65 64 20 62 79 20  em: replaced by 
0fa0: 6e 65 77 20 63 6c 69 65 6e 74 2e 6b 65 79 0a 09  new client.key..
0fb0: 2a 20 74 65 73 74 73 2f 63 65 72 74 73 2f 52 45  * tests/certs/RE
0fc0: 41 44 4d 45 2e 74 78 74 3a 20 6e 65 77 20 73 65  ADME.txt: new se
0fd0: 74 20 6f 66 20 74 65 73 74 20 63 65 72 74 69 66  t of test certif
0fe0: 69 63 61 74 65 73 20 77 69 74 68 20 73 6f 6d 65  icates with some
0ff0: 0a 09 52 45 41 44 4d 45 20 69 6e 66 6f 20 6f 6e  ..README info on
1000: 20 74 68 65 69 72 20 67 65 6e 65 72 61 74 69 6f   their generatio
1010: 6e 2e 0a 0a 09 2a 20 74 65 73 74 73 2f 63 69 70  n....* tests/cip
1020: 68 65 72 73 2e 74 65 73 74 3a 20 75 70 64 61 74  hers.test: updat
1030: 65 64 20 63 69 70 68 65 72 73 20 65 78 70 65 63  ed ciphers expec
1040: 74 65 64 20 77 69 74 68 20 64 65 66 61 75 6c 74  ted with default
1050: 0a 09 6f 70 65 6e 73 73 6c 20 62 75 69 6c 64 2e  ..openssl build.
1060: 0a 0a 09 2a 20 74 65 73 74 73 2f 74 63 6c 49 4f  ...* tests/tclIO
1070: 2e 74 65 73 74 3a 20 75 70 64 61 74 65 64 20 74  .test: updated t
1080: 6f 20 75 73 65 20 6e 65 77 20 6e 61 6d 65 73 20  o use new names 
1090: 66 6f 72 20 63 65 72 74 73 2f 6b 65 79 73 2e 0a  for certs/keys..
10a0: 0a 32 30 30 31 2d 30 33 2d 31 34 20 20 4a 65 66  .2001-03-14  Jef
10b0: 66 20 48 6f 62 62 73 20 20 3c 6a 65 66 66 68 40  f Hobbs  <jeffh@
10c0: 67 69 6d 6c 65 74 2e 61 63 74 69 76 65 73 74 61  gimlet.activesta
10d0: 74 65 2e 63 6f 6d 3e 0a 0a 09 2a 20 74 6c 73 2e  te.com>...* tls.
10e0: 63 20 28 54 6c 73 5f 49 6e 69 74 29 3a 20 61 64  c (Tls_Init): ad
10f0: 64 20 64 6f 2f 77 68 69 6c 65 20 66 6f 72 20 72  d do/while for r
1100: 61 6e 64 6f 6d 20 6e 75 6d 62 65 72 20 69 6e 69  andom number ini
1110: 74 69 61 6c 69 7a 61 74 69 6f 6e 0a 09 74 6f 20  tialization..to 
1120: 77 6f 72 6b 20 61 72 6f 75 6e 64 20 73 6f 6d 65  work around some
1130: 20 4f 53 65 73 20 71 75 69 72 6b 73 2e 20 20 28   OSes quirks.  (
1140: 52 61 6c 70 68 2e 42 69 6c 6c 65 73 40 74 65 6c  Ralph.Billes@tel
1150: 74 65 63 68 2e 63 6f 6d 2e 61 75 29 0a 0a 32 30  tech.com.au)..20
1160: 30 30 2d 30 39 2d 30 37 20 20 4a 65 66 66 20 48  00-09-07  Jeff H
1170: 6f 62 62 73 20 20 3c 68 6f 62 62 73 40 73 63 72  obbs  <hobbs@scr
1180: 69 70 74 69 63 73 2e 63 6f 6d 3e 0a 0a 09 2a 20  iptics.com>...* 
1190: 74 6c 73 49 4f 2e 63 20 28 54 6c 73 5f 43 68 61  tlsIO.c (Tls_Cha
11a0: 6e 6e 65 6c 54 79 70 65 29 3a 20 73 65 74 20 74  nnelType): set t
11b0: 79 70 65 4e 61 6d 65 20 66 69 65 6c 64 20 6f 66  ypeName field of
11c0: 20 63 68 61 6e 6e 65 6c 20 74 79 70 65 20 74 6f   channel type to
11d0: 0a 09 22 74 6c 73 22 20 28 74 68 69 73 20 67 6f  .."tls" (this go
11e0: 74 20 6c 6f 73 74 20 69 6e 20 6d 6f 76 65 20 74  t lost in move t
11f0: 6f 20 64 79 6e 61 6d 69 63 20 76 65 72 73 69 6f  o dynamic versio
1200: 6e 20 63 6f 6d 70 61 74 61 62 69 6c 69 74 79 0a  n compatability.
1210: 09 63 68 65 63 6b 69 6e 67 29 2e 0a 0a 32 30 30  .checking)...200
1220: 30 2d 30 38 2d 32 33 20 20 4a 65 66 66 20 48 6f  0-08-23  Jeff Ho
1230: 62 62 73 20 20 3c 68 6f 62 62 73 40 73 63 72 69  bbs  <hobbs@scri
1240: 70 74 69 63 73 2e 63 6f 6d 3e 0a 0a 09 54 4c 53  ptics.com>...TLS
1250: 20 31 2e 34 20 52 45 4c 45 41 53 45 44 0a 0a 09   1.4 RELEASED...
1260: 2a 20 4d 61 6b 65 66 69 6c 65 2e 69 6e 20 28 64  * Makefile.in (d
1270: 69 73 74 29 3a 20 63 72 65 61 74 65 20 64 69 73  ist): create dis
1280: 74 20 74 61 72 67 65 74 20 66 6f 72 20 61 72 63  t target for arc
1290: 68 69 76 65 20 64 69 73 74 72 69 62 75 74 69 6f  hive distributio
12a0: 6e 73 0a 0a 09 2a 20 74 65 73 74 73 2f 74 6c 73  ns...* tests/tls
12b0: 49 4f 2e 74 65 73 74 20 28 74 6c 73 49 4f 2d 38  IO.test (tlsIO-8
12c0: 2e 31 29 3a 20 61 64 64 65 64 20 61 20 64 65 6c  .1): added a del
12d0: 61 79 20 6f 6e 20 74 68 65 20 61 63 63 65 70 74  ay on the accept
12e0: 20 63 6c 6f 73 65 0a 09 74 6f 20 6d 61 6b 65 20   close..to make 
12f0: 74 68 65 20 74 65 73 74 20 77 6f 72 6b 20 77 69  the test work wi
1300: 74 68 20 4f 70 65 6e 53 53 4c 20 6f 6e 20 57 69  th OpenSSL on Wi
1310: 6e 64 6f 77 73 20 28 64 6f 65 73 6e 27 74 20 61  ndows (doesn't a
1320: 66 66 65 63 74 0a 09 6f 74 68 65 72 20 62 75 69  ffect..other bui
1330: 6c 64 73 29 2e 0a 0a 09 2a 20 74 6c 73 2e 68 74  lds)....* tls.ht
1340: 6d 3a 20 75 70 64 61 74 65 64 20 77 69 74 68 20  m: updated with 
1350: 6e 6f 74 65 73 20 66 6f 72 20 31 2e 34 2e 0a 0a  notes for 1.4...
1360: 32 30 30 30 2d 30 38 2d 32 31 20 20 4a 65 66 66  2000-08-21  Jeff
1370: 20 48 6f 62 62 73 20 20 3c 68 6f 62 62 73 40 73   Hobbs  <hobbs@s
1380: 63 72 69 70 74 69 63 73 2e 63 6f 6d 3e 0a 0a 09  criptics.com>...
1390: 2a 20 74 65 73 74 73 2f 74 6c 73 49 4f 2e 74 65  * tests/tlsIO.te
13a0: 73 74 3a 20 72 65 71 75 69 72 65 20 61 74 20 6c  st: require at l
13b0: 65 61 73 74 20 74 6c 73 31 2e 34 20 69 6e 20 74  east tls1.4 in t
13c0: 65 73 74 20 73 75 69 74 65 2e 0a 0a 32 30 30 30  est suite...2000
13d0: 2d 30 38 2d 31 38 20 20 4a 65 66 66 20 48 6f 62  -08-18  Jeff Hob
13e0: 62 73 20 20 3c 68 6f 62 62 73 40 73 63 72 69 70  bs  <hobbs@scrip
13f0: 74 69 63 73 2e 63 6f 6d 3e 0a 0a 09 2a 20 74 6c  tics.com>...* tl
1400: 73 2e 63 20 28 54 6c 73 5f 49 6e 69 74 29 3a 20  s.c (Tls_Init): 
1410: 61 64 64 65 64 20 63 61 6c 6c 20 74 6f 20 52 41  added call to RA
1420: 4e 44 5f 73 65 65 64 20 74 6f 20 73 65 65 64 20  ND_seed to seed 
1430: 74 68 65 20 53 53 4c 20 72 61 6e 64 6f 6d 0a 09  the SSL random..
1440: 6e 75 6d 62 65 72 20 67 65 6e 65 72 61 74 6f 72  number generator
1450: 2e 20 20 57 69 74 68 6f 75 74 20 74 68 69 73 2c  .  Without this,
1460: 20 4f 70 65 6e 53 53 4c 20 30 2e 39 2e 35 20 63   OpenSSL 0.9.5 c
1470: 68 6f 6b 65 73 2c 20 61 6e 64 20 69 6e 20 61 6e  hokes, and in an
1480: 79 0a 09 63 61 73 65 20 69 74 20 69 73 20 61 20  y..case it is a 
1490: 62 69 67 20 73 65 63 75 72 69 74 79 20 68 6f 6c  big security hol
14a0: 65 20 74 6f 20 64 6f 20 77 69 74 68 6f 75 74 20  e to do without 
14b0: 69 74 2e 0a 0a 09 2a 20 63 6f 6e 66 69 67 75 72  it....* configur
14c0: 65 2e 69 6e 20 28 4f 50 45 4e 53 53 4c 29 3a 20  e.in (OPENSSL): 
14d0: 61 64 64 65 64 20 4e 4f 5f 49 44 45 41 20 61 6e  added NO_IDEA an
14e0: 64 20 4e 4f 5f 52 43 35 20 64 65 66 69 6e 65 73  d NO_RC5 defines
14f0: 20 62 79 0a 09 64 65 66 61 75 6c 74 20 77 68 65   by..default whe
1500: 6e 20 63 6f 6d 70 69 6c 69 6e 67 20 77 69 74 68  n compiling with
1510: 20 4f 70 65 6e 53 53 4c 2e 0a 0a 09 2a 20 74 6c   OpenSSL....* tl
1520: 73 49 6e 74 2e 68 3a 20 61 64 64 65 64 20 65 72  sInt.h: added er
1530: 72 2e 68 20 69 6e 63 6c 75 64 65 0a 0a 09 2a 20  r.h include...* 
1540: 74 6c 73 42 49 4f 2e 63 3a 0a 09 2a 20 74 6c 73  tlsBIO.c:..* tls
1550: 49 4f 2e 63 3a 20 63 6f 72 72 65 63 74 65 64 20  IO.c: corrected 
1560: 70 65 64 61 6e 74 69 63 20 63 61 73 74 20 65 72  pedantic cast er
1570: 72 6f 72 73 2e 0a 0a 32 30 30 30 2d 30 38 2d 31  rors...2000-08-1
1580: 36 20 20 4a 65 66 66 20 48 6f 62 62 73 20 20 3c  6  Jeff Hobbs  <
1590: 68 6f 62 62 73 40 73 63 72 69 70 74 69 63 73 2e  hobbs@scriptics.
15a0: 63 6f 6d 3e 0a 0a 09 2a 20 74 65 73 74 73 2f 63  com>...* tests/c
15b0: 69 70 68 65 72 73 2e 74 65 73 74 3a 20 69 6d 70  iphers.test: imp
15c0: 72 6f 76 65 64 20 61 62 69 6c 69 74 79 20 74 6f  roved ability to
15d0: 20 63 68 61 6e 67 65 20 63 6f 6e 73 74 72 61 69   change constrai
15e0: 6e 74 0a 09 73 65 74 74 69 6e 67 20 66 6f 72 20  nt..setting for 
15f0: 77 68 65 74 68 65 72 20 75 73 65 72 20 63 6f 6d  whether user com
1600: 70 69 6c 65 64 20 61 67 61 69 6e 73 74 20 52 53  piled against RS
1610: 41 20 6f 72 20 4f 70 65 6e 53 53 4c 20 6c 69 62  A or OpenSSL lib
1620: 73 2e 0a 0a 09 2a 20 74 6c 73 2e 63 20 28 54 6c  s....* tls.c (Tl
1630: 73 5f 49 6e 69 74 29 3a 20 63 6f 72 72 65 63 74  s_Init): correct
1640: 65 64 20 69 6e 74 65 72 70 72 65 74 61 74 69 6f  ed interpretatio
1650: 6e 20 6f 66 20 76 65 72 73 69 6f 6e 20 6e 75 6d  n of version num
1660: 62 65 72 0a 09 28 70 61 74 63 68 6c 65 76 65 6c  ber..(patchlevel
1670: 20 61 6e 64 20 72 65 6c 65 61 73 65 2f 73 65 72   and release/ser
1680: 69 61 6c 20 77 65 72 65 20 73 77 61 70 70 65 64  ial were swapped
1690: 29 2e 0a 0a 32 30 30 30 2d 30 38 2d 31 35 20 20  )...2000-08-15  
16a0: 4a 65 66 66 20 48 6f 62 62 73 20 20 3c 68 6f 62  Jeff Hobbs  <hob
16b0: 62 73 40 73 63 72 69 70 74 69 63 73 2e 63 6f 6d  bs@scriptics.com
16c0: 3e 0a 0a 09 2a 20 52 45 41 44 4d 45 2e 74 78 74  >...* README.txt
16d0: 3a 20 61 64 64 65 64 20 6e 6f 74 65 73 20 61 62  : added notes ab
16e0: 6f 75 74 20 6e 65 65 64 20 74 6f 20 75 73 65 20  out need to use 
16f0: 38 2e 32 2e 30 2b 2e 0a 0a 09 2a 20 74 6c 73 49  8.2.0+....* tlsI
1700: 6e 74 2e 68 3a 0a 09 2a 20 74 6c 73 2e 63 3a 0a  nt.h:..* tls.c:.
1710: 09 2a 20 74 6c 73 49 4f 2e 63 3a 20 63 6f 72 72  .* tlsIO.c: corr
1720: 65 63 74 65 64 20 73 74 72 75 63 74 75 72 65 20  ected structure 
1730: 69 6e 69 74 69 61 6c 69 7a 61 74 69 6f 6e 20 74  initialization t
1740: 6f 20 77 6f 72 6b 20 77 68 65 6e 0a 09 63 6f 6d  o work when..com
1750: 70 69 6c 69 6e 67 20 77 69 74 68 20 38 2e 32 2e  piling with 8.2.
1760: 20 20 4e 6f 77 20 63 6f 6d 70 69 6c 65 73 20 77    Now compiles w
1770: 69 74 68 20 38 2e 32 2b 20 61 6e 64 20 74 65 73  ith 8.2+ and tes
1780: 74 65 64 20 74 6f 20 77 6f 72 6b 0a 09 77 69 74  ted to work..wit
1790: 68 20 38 2e 32 2b 20 61 6e 64 20 64 79 6e 61 6d  h 8.2+ and dynam
17a0: 69 63 61 6c 6c 79 20 61 64 6a 75 73 74 20 74 6f  ically adjust to
17b0: 20 74 68 65 20 76 65 72 73 69 6f 6e 20 6f 66 20   the version of 
17c0: 54 63 6c 20 69 74 20 77 61 73 0a 09 6c 6f 61 64  Tcl it was..load
17d0: 65 64 20 69 6e 74 6f 2e 20 20 54 4c 53 20 77 69  ed into.  TLS wi
17e0: 6c 6c 20 66 61 69 6c 20 74 68 65 20 74 65 73 74  ll fail the test
17f0: 20 73 75 69 74 65 20 77 69 74 68 20 54 63 6c 20   suite with Tcl 
1800: 38 2e 32 2d 38 2e 33 2e 31 2e 0a 0a 09 2a 20 74  8.2-8.3.1....* t
1810: 65 73 74 73 2f 61 6c 6c 2e 74 63 6c 3a 20 61 64  ests/all.tcl: ad
1820: 64 65 64 20 63 61 74 63 68 20 61 72 6f 75 6e 64  ded catch around
1830: 20 3a 3a 74 63 6c 74 65 73 74 3a 3a 6e 6f 72 6d   ::tcltest::norm
1840: 61 6c 69 7a 65 50 61 74 68 0a 09 62 65 63 61 75  alizePath..becau
1850: 73 65 20 69 74 20 64 6f 65 73 6e 27 74 20 65 78  se it doesn't ex
1860: 69 73 74 20 69 6e 20 70 72 65 2d 38 2e 33 20 74  ist in pre-8.3 t
1870: 63 6c 74 65 73 74 2e 0a 0a 09 2a 20 74 65 73 74  cltest....* test
1880: 73 2f 73 69 6d 70 6c 65 43 6c 69 65 6e 74 2e 74  s/simpleClient.t
1890: 63 6c 3a 20 0a 09 2a 20 74 65 73 74 73 2f 73 69  cl: ..* tests/si
18a0: 6d 70 6c 65 53 65 72 76 65 72 2e 74 63 6c 3a 20  mpleServer.tcl: 
18b0: 61 64 64 65 64 20 73 69 6d 70 6c 65 20 63 6c 69  added simple cli
18c0: 65 6e 74 2f 73 65 72 76 65 72 20 74 65 73 74 20  ent/server test 
18d0: 73 63 72 69 70 74 73 0a 09 74 68 61 74 20 75 73  scripts..that us
18e0: 65 20 74 65 73 74 20 63 65 72 74 73 20 61 6e 64  e test certs and
18f0: 20 63 61 6e 20 64 6f 20 73 69 6d 70 6c 65 20 73   can do simple s
1900: 74 72 65 73 73 20 74 65 73 74 73 2e 0a 0a 32 30  tress tests...20
1910: 30 30 2d 30 38 2d 31 34 20 20 4a 65 66 66 20 48  00-08-14  Jeff H
1920: 6f 62 62 73 20 20 3c 68 6f 62 62 73 40 73 63 72  obbs  <hobbs@scr
1930: 69 70 74 69 63 73 2e 63 6f 6d 3e 0a 0a 09 2a 20  iptics.com>...* 
1940: 74 6c 73 49 6e 74 2e 68 3a 0a 09 2a 20 74 6c 73  tlsInt.h:..* tls
1950: 49 4f 2e 63 3a 0a 09 2a 20 74 6c 73 42 49 4f 2e  IO.c:..* tlsBIO.
1960: 63 3a 0a 09 2a 20 74 6c 73 2e 63 3a 20 63 68 61  c:..* tls.c: cha
1970: 6e 67 65 64 20 61 72 6f 75 6e 64 20 74 6f 20 6f  nged around to o
1980: 6e 6c 79 20 77 6f 72 6b 69 6e 67 20 77 69 74 68  nly working with
1990: 20 38 2e 32 2e 30 2b 20 28 38 2e 33 2e 32 2b 0a   8.2.0+ (8.3.2+.
19a0: 09 70 72 65 66 65 72 72 65 64 29 2c 20 77 69 74  .preferred), wit
19b0: 68 20 72 75 6e 74 69 6d 65 20 63 68 65 63 6b 73  h runtime checks
19c0: 20 66 6f 72 20 70 72 65 2d 20 61 6e 64 20 70 6f   for pre- and po
19d0: 73 74 2d 69 6f 2d 72 65 77 72 69 74 65 2e 0a 0a  st-io-rewrite...
19e0: 09 2a 20 74 6c 73 2e 63 20 28 54 6c 73 5f 49 6e  .* tls.c (Tls_In
19f0: 69 74 29 3a 20 63 68 61 6e 67 65 64 20 69 74 20  it): changed it 
1a00: 74 6f 20 72 65 71 75 69 72 65 20 38 2e 33 2e 32  to require 8.3.2
1a10: 20 77 68 65 6e 20 54 63 6c 5f 49 6e 69 74 53 74   when Tcl_InitSt
1a20: 75 62 73 0a 09 77 61 73 20 63 61 6c 6c 65 64 20  ubs..was called 
1a30: 62 65 63 61 75 73 65 20 77 65 20 64 6f 6e 27 74  because we don't
1a40: 20 77 61 6e 74 20 70 65 6f 70 6c 65 20 75 73 69   want people usi
1a50: 6e 67 20 54 4c 53 20 77 69 74 68 20 74 68 65 0a  ng TLS with the.
1a60: 09 6f 72 69 67 69 6e 61 6c 20 73 74 61 63 6b 65  .original stacke
1a70: 64 20 63 68 61 6e 6e 65 6c 20 69 6d 70 6c 65 6d  d channel implem
1a80: 65 6e 74 61 74 69 6f 6e 2e 0a 0a 32 30 30 30 2d  entation...2000-
1a90: 30 37 2d 32 36 20 20 4a 65 66 66 20 48 6f 62 62  07-26  Jeff Hobb
1aa0: 73 20 20 3c 68 6f 62 62 73 40 73 63 72 69 70 74  s  <hobbs@script
1ab0: 69 63 73 2e 63 6f 6d 3e 0a 0a 09 2a 20 6d 65 72  ics.com>...* mer
1ac0: 67 65 64 20 61 6c 6c 20 63 68 61 6e 67 65 73 20  ged all changes 
1ad0: 66 72 6f 6d 20 74 6c 73 2d 31 2d 33 2d 69 6f 2d  from tls-1-3-io-
1ae0: 72 65 77 72 69 74 65 20 62 61 63 6b 20 69 6e 74  rewrite back int
1af0: 6f 20 6d 61 69 6e 20 62 72 61 6e 63 68 0a 0a 09  o main branch...
1b00: 2a 20 74 65 73 74 73 2f 74 6c 73 49 4f 2e 74 65  * tests/tlsIO.te
1b10: 73 74 3a 20 75 70 64 61 74 65 64 20 63 6f 6d 6d  st: updated comm
1b20: 65 6e 74 73 2c 20 66 69 78 65 64 20 61 20 70 63  ents, fixed a pc
1b30: 43 72 61 73 68 20 63 61 73 65 20 74 68 61 74 0a  Crash case that.
1b40: 09 77 61 73 20 64 75 65 20 74 6f 20 64 65 62 75  .was due to debu
1b50: 67 20 61 73 73 65 72 74 69 6f 6e 20 69 6e 20 57  g assertion in W
1b60: 69 6e 64 6f 77 73 20 53 53 4c 2e 0a 0a 09 2a 20  indows SSL....* 
1b70: 74 6c 73 2e 63 20 28 49 6d 70 6f 72 74 4f 62 6a  tls.c (ImportObj
1b80: 43 6d 64 29 3a 20 72 65 6d 6f 76 65 64 20 75 6e  Cmd): removed un
1b90: 6e 65 63 65 73 73 61 72 79 20 75 73 65 20 6f 66  necessary use of
1ba0: 20 27 62 69 6f 27 20 61 72 67 2e 0a 09 28 54 6c   'bio' arg...(Tl
1bb0: 73 5f 49 6e 69 74 29 3a 20 63 68 65 63 6b 20 72  s_Init): check r
1bc0: 65 74 75 72 6e 20 76 61 6c 75 65 20 6f 66 20 53  eturn value of S
1bd0: 53 4c 5f 6c 69 62 72 61 72 79 5f 69 6e 69 74 2e  SL_library_init.
1be0: 20 20 41 6c 73 6f 20 6c 6f 74 73 20 6f 66 0a 09    Also lots of..
1bf0: 77 68 69 74 65 73 70 61 63 65 20 63 6c 65 61 6e  whitespace clean
1c00: 75 70 20 28 6d 6f 72 65 20 6c 69 6b 65 20 54 63  up (more like Tc
1c10: 6c 20 45 6e 67 20 73 74 79 6c 65 20 67 75 69 64  l Eng style guid
1c20: 65 29 2c 20 62 75 74 20 6e 6f 74 20 61 6c 6c 0a  e), but not all.
1c30: 09 63 6f 64 65 20 77 61 73 20 63 6c 65 61 6e 65  .code was cleane
1c40: 64 20 75 70 2e 0a 0a 09 2a 20 74 6c 73 42 49 4f  d up....* tlsBIO
1c50: 2e 63 3a 20 6d 69 6e 6f 72 20 77 68 69 74 65 73  .c: minor whites
1c60: 70 61 63 65 20 63 6c 65 61 6e 75 70 0a 0a 09 2a  pace cleanup...*
1c70: 20 74 6c 73 49 4f 2e 63 3a 20 6d 69 6e 6f 72 20   tlsIO.c: minor 
1c80: 77 68 69 74 65 73 70 61 63 65 20 63 6c 65 61 6e  whitespace clean
1c90: 75 70 2e 0a 09 28 54 6c 73 49 6e 70 75 74 50 72  up...(TlsInputPr
1ca0: 6f 63 2c 20 54 6c 73 4f 75 74 70 75 74 50 72 6f  oc, TlsOutputPro
1cb0: 63 29 3a 20 41 64 64 65 64 20 45 52 52 5f 63 6c  c): Added ERR_cl
1cc0: 65 61 72 5f 65 72 72 6f 72 20 62 65 66 6f 72 65  ear_error before
1cd0: 20 63 61 6c 6c 73 0a 09 74 6f 20 42 49 4f 5f 72   calls..to BIO_r
1ce0: 65 61 64 20 6f 72 20 42 49 4f 5f 77 72 69 74 65  ead or BIO_write
1cf0: 2c 20 62 65 63 61 75 73 65 20 77 65 20 63 6f 75  , because we cou
1d00: 6c 64 20 6f 74 68 65 72 77 69 73 65 20 65 6e 64  ld otherwise end
1d10: 20 75 70 0a 09 70 75 6c 6c 69 6e 67 20 61 6e 20   up..pulling an 
1d20: 65 72 72 6f 72 20 6f 66 66 20 74 68 65 20 73 74  error off the st
1d30: 61 63 6b 20 74 68 61 74 20 64 69 64 6e 27 74 20  ack that didn't 
1d40: 62 65 6c 6f 6e 67 20 74 6f 20 75 73 2e 20 20 41  belong to us.  A
1d50: 6c 73 6f 0a 09 63 6c 65 61 6e 75 70 20 75 70 20  lso..cleanup up 
1d60: 65 78 63 65 73 73 69 76 65 20 75 73 65 20 6f 66  excessive use of
1d70: 20 67 6f 74 6f 73 2e 0a 0a 32 30 30 30 2d 30 37   gotos...2000-07
1d80: 2d 32 30 20 20 4a 65 66 66 20 48 6f 62 62 73 20  -20  Jeff Hobbs 
1d90: 20 3c 68 6f 62 62 73 40 73 63 72 69 70 74 69 63   <hobbs@scriptic
1da0: 73 2e 63 6f 6d 3e 0a 0a 09 2a 20 74 65 73 74 73  s.com>...* tests
1db0: 2f 74 6c 73 49 4f 2e 74 65 73 74 3a 20 63 6f 72  /tlsIO.test: cor
1dc0: 72 65 63 74 65 64 20 76 61 72 69 6f 75 73 20 74  rected various t
1dd0: 65 73 74 73 20 74 6f 20 62 65 20 63 6f 72 72 65  ests to be corre
1de0: 63 74 20 66 6f 72 20 54 4c 53 0a 09 73 74 61 63  ct for TLS..stac
1df0: 6b 65 64 20 63 68 61 6e 6e 65 6c 73 20 28 61 73  ked channels (as
1e00: 20 6f 70 70 6f 73 65 64 20 74 6f 20 74 68 65 20   opposed to the 
1e10: 73 74 61 6e 64 61 72 64 20 73 6f 63 6b 65 74 73  standard sockets
1e20: 20 74 68 65 20 74 65 73 74 0a 09 73 75 69 74 65   the test..suite
1e30: 20 77 61 73 20 61 64 6f 70 74 65 64 20 66 72 6f   was adopted fro
1e40: 6d 29 2e 20 20 4b 65 79 20 64 69 66 66 65 72 65  m).  Key differe
1e50: 6e 63 65 73 20 61 72 65 20 74 68 61 74 20 54 4c  nces are that TL
1e60: 53 20 63 61 6e 6e 6f 74 0a 09 6f 70 65 72 61 74  S cannot..operat
1e70: 65 20 69 6e 20 6f 6e 65 20 70 72 6f 63 65 73 73  e in one process
1e80: 20 77 69 74 68 6f 75 74 20 61 6c 6c 20 63 68 61   without all cha
1e90: 6e 6e 65 6c 73 20 62 65 69 6e 67 20 6e 6f 6e 2d  nnels being non-
1ea0: 62 6c 6f 63 6b 69 6e 67 2c 20 6f 72 0a 09 74 68  blocking, or..th
1eb0: 65 20 68 61 6e 64 73 68 61 6b 65 20 77 69 6c 6c  e handshake will
1ec0: 20 62 6c 6f 63 6b 2c 20 61 6e 64 20 68 61 6e 64   block, and hand
1ed0: 73 68 61 6b 69 6e 67 20 6d 75 73 74 20 62 65 20  shaking must be 
1ee0: 66 6f 72 63 65 64 20 69 6e 20 73 6f 6d 65 0a 09  forced in some..
1ef0: 63 61 73 65 73 2e 20 20 41 6c 73 6f 2c 20 68 61  cases.  Also, ha
1f00: 6e 64 73 68 61 6b 65 73 20 64 6f 6e 27 74 20 73  ndshakes don't s
1f10: 65 65 6d 20 74 6f 20 63 6f 6d 70 6c 65 74 65 20  eem to complete 
1f20: 75 6e 6c 65 73 73 20 74 68 65 20 63 6c 69 65 6e  unless the clien
1f30: 74 0a 09 68 61 73 20 70 6c 61 63 65 64 20 61 74  t..has placed at
1f40: 20 6c 65 61 73 74 20 6f 6e 65 20 62 79 74 65 20   least one byte 
1f50: 66 6f 72 20 74 68 65 20 73 65 72 76 65 72 20 74  for the server t
1f60: 6f 20 72 65 61 64 20 69 6e 20 74 68 65 20 63 68  o read in the ch
1f70: 61 6e 6e 65 6c 2e 0a 0a 09 2a 20 74 65 73 74 73  annel....* tests
1f80: 2f 72 65 6d 6f 74 65 2e 74 63 6c 3a 20 63 6f 72  /remote.tcl: cor
1f90: 72 65 63 74 65 64 20 74 68 65 20 66 69 6e 64 69  rected the findi
1fa0: 6e 67 20 6f 66 20 74 65 73 74 73 20 63 65 72 74  ng of tests cert
1fb0: 69 66 69 63 61 74 65 73 0a 0a 09 2a 20 74 6c 73  ificates...* tls
1fc0: 49 4f 2e 63 20 28 54 6c 73 43 6c 6f 73 65 50 72  IO.c (TlsClosePr
1fd0: 6f 63 29 3a 20 72 65 6d 6f 76 65 64 20 64 65 6c  oc): removed del
1fe0: 65 74 69 6e 67 20 6f 66 20 74 69 6d 65 72 20 68  eting of timer h
1ff0: 61 6e 64 6c 65 72 20 61 73 0a 09 74 68 61 74 20  andler as..that 
2000: 69 73 20 68 61 6e 64 6c 65 64 20 62 79 20 54 6c  is handled by Tl
2010: 73 5f 43 6c 65 61 6e 2e 0a 0a 09 2a 20 74 6c 73  s_Clean....* tls
2020: 2e 74 63 6c 20 28 74 6c 73 3a 3a 5f 61 63 63 65  .tcl (tls::_acce
2030: 70 74 29 3a 20 63 6f 72 72 65 63 74 65 64 20 74  pt): corrected t
2040: 68 65 20 69 6e 74 65 72 6e 61 6c 20 5f 61 63 63  he internal _acc
2050: 65 70 74 20 74 6f 0a 09 74 72 69 63 6b 6c 65 20  ept to..trickle 
2060: 63 61 6c 6c 62 61 63 6b 20 65 72 72 6f 72 73 20  callback errors 
2070: 74 6f 20 74 68 65 20 75 73 65 72 2e 0a 0a 09 2a  to the user....*
2080: 20 4d 61 6b 65 66 69 6c 65 2e 69 6e 3a 20 6d 61   Makefile.in: ma
2090: 64 65 20 74 68 65 20 69 6e 73 74 61 6c 6c 2d 62  de the install-b
20a0: 69 6e 61 72 69 65 73 20 74 61 72 67 65 74 20 72  inaries target r
20b0: 65 67 65 6e 65 72 61 74 65 20 74 68 65 0a 09 70  egenerate the..p
20c0: 6b 67 49 6e 64 65 78 2e 74 63 6c 20 63 6f 72 72  kgIndex.tcl corr
20d0: 65 63 74 6c 79 2e 20 20 54 68 65 20 74 65 73 74  ectly.  The test
20e0: 20 74 61 72 67 65 74 20 70 72 6f 62 61 62 6c 79   target probably
20f0: 20 73 68 6f 75 6c 64 6e 27 74 20 73 63 72 65 77   shouldn't screw
2100: 0a 09 69 74 20 75 70 2c 20 62 75 74 20 74 68 69  ..it up, but thi
2110: 73 20 69 73 20 74 6f 20 62 65 20 6f 6e 20 74 68  s is to be on th
2120: 65 20 73 61 66 65 20 73 69 64 65 2e 0a 0a 32 30  e safe side...20
2130: 30 30 2d 30 37 2d 31 37 20 20 4a 65 66 66 20 48  00-07-17  Jeff H
2140: 6f 62 62 73 20 20 3c 68 6f 62 62 73 40 73 63 72  obbs  <hobbs@scr
2150: 69 70 74 69 63 73 2e 63 6f 6d 3e 0a 0a 09 2a 20  iptics.com>...* 
2160: 70 6b 67 49 6e 64 65 78 2e 74 63 6c 2e 69 6e 3a  pkgIndex.tcl.in:
2170: 0a 09 2a 20 63 6f 6e 66 69 67 75 72 65 2e 69 6e  ..* configure.in
2180: 3a 20 75 70 64 61 74 65 64 20 76 65 72 73 69 6f  : updated versio
2190: 6e 20 74 6f 20 31 2e 34 0a 0a 32 30 30 30 2d 30  n to 1.4..2000-0
21a0: 37 2d 31 33 20 20 4a 65 66 66 20 48 6f 62 62 73  7-13  Jeff Hobbs
21b0: 20 20 3c 68 6f 62 62 73 40 73 63 72 69 70 74 69    <hobbs@scripti
21c0: 63 73 2e 63 6f 6d 3e 0a 0a 09 2a 20 74 65 73 74  cs.com>...* test
21d0: 73 2f 74 6c 73 49 4f 2e 74 65 73 74 3a 20 65 6e  s/tlsIO.test: en
21e0: 61 62 6c 65 64 20 74 65 73 74 73 20 32 2e 31 30  abled tests 2.10
21f0: 2c 20 37 2e 5b 31 32 34 35 5d 20 28 74 68 65 72  , 7.[1245] (ther
2200: 65 20 69 73 20 6e 6f 20 33 29 2c 0a 09 77 68 69  e is no 3),..whi
2210: 63 68 20 6e 6f 77 20 70 61 73 73 2e 20 20 41 64  ch now pass.  Ad
2220: 64 65 64 20 73 6f 6d 65 20 63 6f 6d 6d 65 6e 74  ded some comment
2230: 73 20 74 6f 20 6f 74 68 65 72 20 66 61 69 6c 69  s to other faili
2240: 6e 67 20 74 65 73 74 73 2e 0a 0a 32 30 30 30 2d  ng tests...2000-
2250: 30 37 2d 31 31 20 20 4a 65 66 66 20 48 6f 62 62  07-11  Jeff Hobb
2260: 73 20 20 3c 68 6f 62 62 73 40 73 63 72 69 70 74  s  <hobbs@script
2270: 69 63 73 2e 63 6f 6d 3e 0a 0a 09 2a 20 74 6c 73  ics.com>...* tls
2280: 49 4f 2e 63 3a 20 63 68 61 6e 67 65 64 20 61 6c  IO.c: changed al
2290: 6c 20 74 68 65 20 63 68 61 6e 6e 65 6c 20 70 72  l the channel pr
22a0: 6f 63 73 20 74 6f 20 73 74 61 72 74 20 77 69 74  ocs to start wit
22b0: 68 20 54 6c 73 2a 20 66 6f 72 0a 09 62 65 74 74  h Tls* for..bett
22c0: 65 72 20 70 61 72 69 74 79 20 77 68 65 6e 20 63  er parity when c
22d0: 6f 6d 70 61 72 69 6e 67 20 77 69 74 68 20 54 72  omparing with Tr
22e0: 61 6e 73 66 6f 72 6d 20 63 68 61 6e 6e 65 6c 20  ansform channel 
22f0: 70 72 6f 63 73 2e 0a 09 52 65 77 72 6f 74 65 20  procs...Rewrote 
2300: 54 6c 73 57 61 74 63 68 50 72 6f 63 2c 20 61 64  TlsWatchProc, ad
2310: 64 65 64 20 54 6c 73 4e 6f 74 69 66 79 50 72 6f  ded TlsNotifyPro
2320: 63 20 61 63 63 6f 72 64 69 6e 67 20 74 6f 20 74  c according to t
2330: 68 65 20 6e 65 77 0a 09 63 68 61 6e 6e 65 6c 20  he new..channel 
2340: 64 65 73 69 67 6e 2c 20 77 68 69 63 68 20 61 6c  design, which al
2350: 73 6f 20 6c 65 61 76 65 73 20 54 6c 73 43 68 61  so leaves TlsCha
2360: 6e 6e 65 6c 48 61 6e 64 6c 65 72 20 75 6e 75 73  nnelHandler unus
2370: 65 64 2e 0a 0a 09 2a 20 74 6c 73 42 49 4f 2e 63  ed....* tlsBIO.c
2380: 20 28 42 69 6f 43 74 72 6c 29 3a 20 63 68 61 6e   (BioCtrl): chan
2390: 67 65 64 20 42 49 4f 5f 43 54 52 4c 5f 46 4c 55  ged BIO_CTRL_FLU
23a0: 53 48 20 63 61 73 65 20 74 6f 20 75 73 65 0a 09  SH case to use..
23b0: 54 63 6c 5f 57 72 69 74 65 52 61 77 20 69 6e 73  Tcl_WriteRaw ins
23c0: 74 65 61 64 20 6f 66 20 54 63 6c 5f 46 6c 75 73  tead of Tcl_Flus
23d0: 68 20 28 74 6f 20 6f 70 65 72 61 74 65 20 6f 6e  h (to operate on
23e0: 20 63 6f 72 72 65 63 74 20 63 68 61 6e 6e 65 6c   correct channel
23f0: 0a 09 69 6e 20 74 68 65 20 73 74 61 63 6b 20 69  ..in the stack i
2400: 6e 73 74 65 61 64 20 6f 66 20 73 74 61 72 74 69  nstead of starti
2410: 6e 67 20 61 74 20 74 68 65 20 74 6f 70 20 61 67  ng at the top ag
2420: 61 69 6e 29 2e 20 20 57 6f 75 6c 64 0a 09 6f 74  ain).  Would..ot
2430: 68 65 72 77 69 73 65 20 63 61 75 73 65 20 61 20  herwise cause a 
2440: 72 65 63 75 72 73 69 76 65 20 73 74 61 63 6b 20  recursive stack 
2450: 62 6f 6d 62 20 77 68 65 6e 20 69 6d 70 6c 69 63  bomb when implic
2460: 69 74 20 68 61 6e 64 73 68 61 6b 69 6e 67 0a 09  it handshaking..
2470: 74 6f 6f 6b 20 65 66 66 65 63 74 2e 0a 0a 09 2a  took effect....*
2480: 20 74 65 73 74 73 2f 74 6c 73 49 4f 2e 74 65 73   tests/tlsIO.tes
2490: 74 3a 20 72 65 6d 6f 76 65 64 20 63 68 61 6e 67  t: removed chang
24a0: 65 73 20 6d 61 64 65 20 74 6f 20 74 65 73 74 20  es made to test 
24b0: 73 75 69 74 65 20 28 61 6c 6c 20 74 65 73 74 73  suite (all tests
24c0: 0a 09 74 68 61 74 20 72 61 6e 20 62 65 66 6f 72  ..that ran befor
24d0: 65 20 6e 6f 77 20 70 61 73 73 20 63 6f 72 72 65  e now pass corre
24e0: 63 74 6c 79 29 2c 20 61 6e 64 20 63 68 61 6e 67  ctly), and chang
24f0: 65 64 20 73 6f 6d 65 20 61 63 63 65 70 74 20 70  ed some accept p
2500: 72 6f 63 0a 09 61 72 67 73 20 74 6f 20 72 65 66  roc..args to ref
2510: 6c 65 63 74 20 74 68 61 74 20 61 20 73 6f 63 6b  lect that a sock
2520: 20 69 73 20 61 6e 20 61 72 67 2c 20 6e 6f 74 20   is an arg, not 
2530: 61 20 66 69 6c 65 2e 0a 0a 32 30 30 30 2d 30 37  a file...2000-07
2540: 2d 31 30 20 20 4a 65 66 66 20 48 6f 62 62 73 20  -10  Jeff Hobbs 
2550: 20 3c 68 6f 62 62 73 40 73 63 72 69 70 74 69 63   <hobbs@scriptic
2560: 73 2e 63 6f 6d 3e 0a 0a 09 2a 20 74 6c 73 42 49  s.com>...* tlsBI
2570: 4f 2e 63 20 28 42 69 6f 57 72 69 74 65 2c 20 42  O.c (BioWrite, B
2580: 69 6f 52 65 61 64 29 3a 20 63 68 61 6e 67 65 64  ioRead): changed
2590: 20 54 63 6c 5f 52 65 61 64 2f 57 72 69 74 65 20   Tcl_Read/Write 
25a0: 74 6f 0a 09 54 63 6c 5f 52 65 61 64 52 61 77 2f  to..Tcl_ReadRaw/
25b0: 54 63 6c 57 72 69 74 65 52 61 77 2e 0a 0a 09 2a  TclWriteRaw....*
25c0: 20 74 6c 73 2e 63 3a 20 61 64 64 65 64 20 75 73   tls.c: added us
25d0: 65 20 6f 66 20 54 63 6c 5f 47 65 74 54 6f 70 43  e of Tcl_GetTopC
25e0: 68 61 6e 6e 65 6c 20 61 66 74 65 72 20 54 63 6c  hannel after Tcl
25f0: 5f 47 65 74 43 68 61 6e 6e 65 6c 20 61 6e 64 0a  _GetChannel and.
2600: 09 67 6f 74 20 72 65 74 75 72 6e 20 76 61 6c 75  .got return valu
2610: 65 20 66 72 6f 6d 20 54 63 6c 5f 53 74 61 63 6b  e from Tcl_Stack
2620: 43 68 61 6e 6e 65 6c 2e 0a 0a 09 2a 20 74 65 73  Channel....* tes
2630: 74 73 2f 74 6c 73 49 4f 2e 74 65 73 74 3a 20 61  ts/tlsIO.test: a
2640: 64 64 65 64 20 73 6f 6d 65 20 68 61 6e 64 73 68  dded some handsh
2650: 61 6b 69 6e 67 20 74 68 61 74 20 73 68 6f 75 6c  aking that shoul
2660: 64 6e 27 74 20 62 65 0a 09 6e 65 63 65 73 73 61  dn't be..necessa
2670: 72 79 2c 20 62 75 74 20 77 65 20 63 72 61 73 68  ry, but we crash
2680: 20 6f 74 68 65 72 77 69 73 65 20 28 6e 65 65 64   otherwise (need
2690: 73 20 6d 6f 72 65 20 74 65 73 74 69 6e 67 29 2e  s more testing).
26a0: 0a 0a 09 2a 20 74 6c 73 49 4f 2e 63 3a 20 61 64  ...* tlsIO.c: ad
26b0: 64 65 64 20 73 75 70 70 6f 72 74 20 66 6f 72 20  ded support for 
26c0: 22 63 6f 72 72 65 63 74 65 64 22 20 73 74 61 63  "corrected" stac
26d0: 6b 65 64 20 63 68 61 6e 6e 65 6c 73 2e 20 20 41  ked channels.  A
26e0: 6c 6c 0a 09 74 68 65 20 61 62 6f 76 65 20 63 68  ll..the above ch
26f0: 61 6e 6e 65 6c 73 20 61 72 65 20 69 6e 20 54 43  annels are in TC
2700: 4c 5f 43 48 41 4e 4e 45 4c 5f 56 45 52 53 49 4f  L_CHANNEL_VERSIO
2710: 4e 5f 32 20 23 69 66 64 65 66 73 2e 0a 0a 32 30  N_2 #ifdefs...20
2720: 30 30 2d 30 36 2d 30 35 20 20 53 63 6f 74 74 20  00-06-05  Scott 
2730: 53 74 61 6e 74 6f 6e 20 20 3c 73 74 61 6e 74 6f  Stanton  <stanto
2740: 6e 40 61 6a 75 62 61 73 6f 6c 75 74 69 6f 6e 73  n@ajubasolutions
2750: 2e 63 6f 6d 3e 0a 0a 09 2a 20 4d 61 6b 65 66 69  .com>...* Makefi
2760: 6c 65 2e 69 6e 3a 20 46 69 78 65 64 20 62 72 6f  le.in: Fixed bro
2770: 6b 65 6e 20 74 65 73 74 20 74 61 72 67 65 74 2e  ken test target.
2780: 0a 0a 09 2a 20 74 6c 73 49 6e 74 2e 68 3a 20 0a  ...* tlsInt.h: .
2790: 09 2a 20 74 6c 73 2e 63 3a 20 43 6c 65 61 6e 65  .* tls.c: Cleane
27a0: 64 20 75 70 20 64 65 63 6c 61 72 61 74 69 6f 6e  d up declaration
27b0: 73 20 6f 66 20 54 6c 73 5f 43 6c 65 61 6e 20 74  s of Tls_Clean t
27c0: 6f 20 61 76 6f 69 64 20 65 72 72 6f 72 73 20 6f  o avoid errors o
27d0: 6e 0a 09 57 69 6e 64 6f 77 73 20 28 6c 69 6e 74  n..Windows (lint
27e0: 29 2e 0a 0a 32 30 30 30 2d 30 36 2d 30 35 20 20  )...2000-06-05  
27f0: 42 72 65 6e 74 20 57 65 6c 63 68 20 3c 77 65 6c  Brent Welch <wel
2800: 63 68 40 61 6a 75 62 61 73 6f 6c 75 74 69 6f 6e  ch@ajubasolution
2810: 73 2e 63 6f 6d 3e 0a 0a 09 2a 20 74 6c 73 2e 63  s.com>...* tls.c
2820: 2c 20 74 6c 73 49 4f 2e 63 3a 20 20 53 70 6c 69  , tlsIO.c:  Spli
2830: 74 20 54 6c 73 5f 46 72 65 65 20 69 6e 74 6f 20  t Tls_Free into 
2840: 54 6c 73 5f 43 6c 65 61 6e 2c 20 77 68 69 63 68  Tls_Clean, which
2850: 20 64 6f 65 73 0a 09 74 68 65 20 53 53 4c 20 63   does..the SSL c
2860: 6c 65 61 6e 75 70 2c 20 61 6e 64 20 74 68 65 20  leanup, and the 
2870: 54 63 6c 5f 46 72 65 65 20 63 61 6c 6c 2e 20 20  Tcl_Free call.  
2880: 49 74 20 69 73 20 69 6d 70 6f 72 74 61 6e 74 20  It is important 
2890: 74 6f 20 73 68 75 74 64 6f 77 6e 0a 09 74 68 65  to shutdown..the
28a0: 20 53 53 4c 20 73 74 61 74 65 20 22 73 79 6e 63   SSL state "sync
28b0: 68 72 6f 6e 6f 75 73 6c 79 22 20 64 75 72 69 6e  hronously" durin
28c0: 67 20 61 20 73 74 61 63 6b 65 64 20 66 6c 75 73  g a stacked flus
28d0: 68 2e 0a 0a 32 30 30 30 2d 30 36 2d 30 31 20 20  h...2000-06-01  
28e0: 53 63 6f 74 74 20 53 74 61 6e 74 6f 6e 20 20 3c  Scott Stanton  <
28f0: 73 74 61 6e 74 6f 6e 40 61 6a 75 62 61 73 6f 6c  stanton@ajubasol
2900: 75 74 69 6f 6e 73 2e 63 6f 6d 3e 0a 0a 09 2a 20  utions.com>...* 
2910: 74 6c 73 49 4f 2e 63 3a 20 52 65 73 74 6f 72 65  tlsIO.c: Restore
2920: 64 20 63 61 6c 6c 20 74 6f 20 54 63 6c 5f 4e 6f  d call to Tcl_No
2930: 74 69 66 79 43 68 61 6e 6e 65 6c 20 66 72 6f 6d  tifyChannel from
2940: 20 43 68 61 6e 6e 65 6c 48 61 6e 64 6c 65 72 0a   ChannelHandler.
2950: 09 74 6f 20 65 6e 73 75 72 65 20 74 68 61 74 20  .to ensure that 
2960: 65 76 65 6e 74 73 20 70 72 6f 70 61 67 61 74 65  events propagate
2970: 20 66 72 6f 6d 20 74 68 65 20 6c 6f 77 65 72 20   from the lower 
2980: 64 72 69 76 65 72 2e 20 20 54 68 69 73 20 6d 61  driver.  This ma
2990: 79 0a 09 72 65 73 75 6c 74 20 69 6e 20 61 6e 20  y..result in an 
29a0: 69 6e 66 69 6e 69 74 65 20 6c 6f 6f 70 20 69 6e  infinite loop in
29b0: 20 73 6f 6d 65 20 63 61 73 65 73 2c 20 73 6f 20   some cases, so 
29c0: 74 68 69 73 20 69 73 20 6e 6f 74 20 61 20 74 6f  this is not a to
29d0: 74 61 6c 0a 09 66 69 78 2e 20 20 54 68 69 73 20  tal..fix.  This 
29e0: 6d 61 79 20 62 65 20 73 75 66 66 69 63 69 65 6e  may be sufficien
29f0: 74 20 66 6f 72 20 6e 6f 77 2c 20 68 6f 77 65 76  t for now, howev
2a00: 65 72 2e 20 5b 42 75 67 3a 20 35 36 32 33 5d 0a  er. [Bug: 5623].
2a10: 0a 32 30 30 30 2d 30 36 2d 30 31 20 20 53 63 6f  .2000-06-01  Sco
2a20: 74 74 20 53 74 61 6e 74 6f 6e 20 20 3c 73 74 61  tt Stanton  <sta
2a30: 6e 74 6f 6e 40 73 63 72 69 70 74 69 63 73 2e 63  nton@scriptics.c
2a40: 6f 6d 3e 0a 0a 09 2a 20 74 6c 73 49 4f 2e 63 3a  om>...* tlsIO.c:
2a50: 20 52 65 73 74 6f 72 65 20 74 68 65 20 70 72 65   Restore the pre
2a60: 76 69 6f 75 73 20 76 65 72 73 69 6f 6e 2e 20 20  vious version.  
2a70: 46 69 78 65 64 20 74 68 65 20 43 6c 6f 73 65 50  Fixed the CloseP
2a80: 72 6f 63 20 73 6f 0a 09 69 74 20 75 6e 72 65 67  roc so..it unreg
2a90: 69 73 74 65 72 73 20 74 68 65 20 63 68 61 6e 6e  isters the chann
2aa0: 65 6c 20 68 61 6e 64 6c 65 72 20 6f 6e 20 74 68  el handler on th
2ab0: 65 20 73 75 70 65 72 63 65 64 65 64 20 63 68 61  e superceded cha
2ac0: 6e 6e 65 6c 0a 09 69 6e 73 74 65 61 64 20 6f 66  nnel..instead of
2ad0: 20 74 68 65 20 75 70 70 65 72 20 63 68 61 6e 6e   the upper chann
2ae0: 65 6c 2e 20 41 6c 73 6f 20 72 65 6d 6f 76 65 64  el. Also removed
2af0: 20 74 68 65 20 63 61 6c 6c 20 74 6f 0a 09 54 63   the call to..Tc
2b00: 6c 5f 4e 6f 74 69 66 79 43 68 61 6e 6e 65 6c 20  l_NotifyChannel 
2b10: 69 6e 20 74 68 65 20 43 68 61 6e 6e 65 6c 48 61  in the ChannelHa
2b20: 6e 64 6c 65 72 20 62 65 63 61 75 73 65 20 74 68  ndler because th
2b30: 69 73 20 77 69 6c 6c 20 72 65 73 75 6c 74 0a 09  is will result..
2b40: 69 6e 20 61 6e 20 69 6e 66 69 6e 69 74 65 20 6c  in an infinite l
2b50: 6f 6f 70 20 69 66 20 64 61 74 61 20 69 73 20 65  oop if data is e
2b60: 76 65 72 20 62 75 66 66 65 72 65 64 20 69 6e 20  ver buffered in 
2b70: 74 68 65 20 42 49 4f 0a 09 73 74 72 75 63 74 75  the BIO..structu
2b80: 72 65 2e 20 5b 42 75 67 3a 20 35 36 32 33 5d 0a  re. [Bug: 5623].
2b90: 0a 32 30 30 30 2d 30 35 2d 33 31 20 20 42 72 65  .2000-05-31  Bre
2ba0: 6e 74 20 57 65 6c 63 68 20 3c 77 65 6c 63 68 40  nt Welch <welch@
2bb0: 73 63 72 69 70 74 69 63 73 2e 63 6f 6d 3e 0a 0a  scriptics.com>..
2bc0: 09 2a 20 74 6c 73 2e 63 3a 20 43 68 61 6e 67 65  .* tls.c: Change
2bd0: 20 74 68 65 20 43 68 61 6e 6e 65 6c 48 61 6e 64   the ChannelHand
2be0: 6c 65 72 20 74 6f 20 62 65 20 72 65 67 69 73 74  ler to be regist
2bf0: 65 72 65 64 20 6f 6e 20 74 68 65 20 6d 61 69 6e  ered on the main
2c00: 0a 09 63 68 61 6e 6e 65 6c 20 61 73 20 6f 70 70  ..channel as opp
2c10: 73 65 64 20 74 6f 20 74 68 65 20 22 70 61 72 65  sed to the "pare
2c20: 6e 74 22 2c 20 6f 72 20 73 75 70 65 72 63 65 65  nt", or supercee
2c30: 64 65 64 2c 20 63 68 61 6e 6e 65 6c 2e 20 20 54  ded, channel.  T
2c40: 68 69 73 0a 09 69 73 20 62 65 63 61 75 73 65 20  his..is because 
2c50: 74 68 65 20 73 6f 63 6b 65 74 20 64 72 69 76 65  the socket drive
2c60: 72 20 6e 6f 74 69 66 69 65 73 20 74 68 65 20 6d  r notifies the m
2c70: 61 69 6e 20 63 68 61 6e 6e 65 6c 2c 20 61 6e 64  ain channel, and
2c80: 20 74 68 65 72 65 0a 09 61 72 65 20 74 69 6d 65   there..are time
2c90: 73 20 77 69 74 68 20 74 68 65 20 6d 61 69 6e 20  s with the main 
2ca0: 63 68 61 6e 6e 65 6c 20 67 65 74 73 20 63 6c 6f  channel gets clo
2cb0: 73 65 64 2c 20 62 75 74 20 74 68 65 20 73 75 70  sed, but the sup
2cc0: 65 72 63 65 64 65 64 0a 09 6f 6e 65 20 69 73 20  erceded..one is 
2cd0: 6e 6f 74 20 79 65 74 20 63 6c 6f 73 65 64 2e 20  not yet closed. 
2ce0: 20 49 66 20 74 68 65 20 63 68 61 6e 6e 65 6c 20   If the channel 
2cf0: 68 61 6e 64 6c 65 72 20 67 65 74 73 20 74 72 69  handler gets tri
2d00: 67 67 65 72 65 64 20 69 6e 0a 09 74 68 69 73 20  ggered in..this 
2d10: 68 61 6c 66 2d 6f 70 65 6e 20 73 74 61 74 65 20  half-open state 
2d20: 69 74 20 69 73 20 61 73 73 6f 63 69 61 74 65 64  it is associated
2d30: 20 77 69 74 68 20 74 68 65 20 73 75 70 65 72 63   with the superc
2d40: 65 65 64 65 64 0a 09 63 68 61 6e 6e 65 64 6c 2c  eeded..channedl,
2d50: 20 62 75 74 20 75 73 65 73 20 69 74 73 20 70 72   but uses its pr
2d60: 69 76 61 74 65 20 70 6f 69 6e 74 65 72 20 74 6f  ivate pointer to
2d70: 20 74 68 65 20 6d 61 69 6e 20 63 68 61 6e 6e 65   the main channe
2d80: 6c 2c 20 77 68 69 63 68 0a 09 69 73 20 6d 6f 73  l, which..is mos
2d90: 74 6c 79 20 64 65 73 74 72 6f 79 65 64 2e 20 20  tly destroyed.  
2da0: 45 6c 69 6d 69 6e 61 74 65 64 20 74 68 65 20 72  Eliminated the r
2db0: 65 64 75 6e 64 61 6e 74 20 63 61 6c 6c 20 74 6f  edundant call to
2dc0: 0a 09 54 63 6c 5f 4e 6f 74 69 66 79 43 68 61 6e  ..Tcl_NotifyChan
2dd0: 6e 65 6c 20 66 72 6f 6d 20 54 6c 73 57 61 74 63  nel from TlsWatc
2de0: 68 50 72 6f 63 2e 20 5b 42 75 67 3a 20 35 36 32  hProc. [Bug: 562
2df0: 33 5d 0a                                         3].