Hex Artifact Content

Artifact 6362c4c989389cbfcc41c3418f3919cca0775c8f:


0000: 2f 2a 0a 20 2a 20 43 6f 70 79 72 69 67 68 74 20  /*. * Copyright 
0010: 28 43 29 20 31 39 39 37 2d 32 30 30 30 20 4d 61  (C) 1997-2000 Ma
0020: 74 74 20 4e 65 77 6d 61 6e 20 3c 6d 61 74 74 40  tt Newman <matt@
0030: 6e 6f 76 61 64 69 67 6d 2e 63 6f 6d 3e 0a 20 2a  novadigm.com>. *
0040: 0a 20 2a 20 54 4c 53 20 28 61 6b 61 20 53 53 4c  . * TLS (aka SSL
0050: 29 20 43 68 61 6e 6e 65 6c 20 2d 20 63 61 6e 20  ) Channel - can 
0060: 62 65 20 6c 61 79 65 72 65 64 20 6f 6e 20 61 6e  be layered on an
0070: 79 20 62 69 2d 64 69 72 65 63 74 69 6f 6e 61 6c  y bi-directional
0080: 0a 20 2a 20 54 63 6c 5f 43 68 61 6e 6e 65 6c 20  . * Tcl_Channel 
0090: 28 4e 6f 74 65 3a 20 52 65 71 75 69 72 65 73 20  (Note: Requires 
00a0: 54 72 66 20 43 6f 72 65 20 50 61 74 63 68 29 0a  Trf Core Patch).
00b0: 20 2a 0a 20 2a 20 54 68 69 73 20 77 61 73 20 62   *. * This was b
00c0: 75 69 6c 74 20 66 72 6f 6d 20 73 63 72 61 74 63  uilt from scratc
00d0: 68 20 62 61 73 65 64 20 75 70 6f 6e 20 6f 62 73  h based upon obs
00e0: 65 72 76 61 74 69 6f 6e 20 6f 66 20 4f 70 65 6e  ervation of Open
00f0: 53 53 4c 20 30 2e 39 2e 32 42 0a 20 2a 0a 20 2a  SSL 0.9.2B. *. *
0100: 20 41 64 64 69 74 69 6f 6e 20 63 72 65 64 69 74   Addition credit
0110: 20 69 73 20 64 75 65 20 66 6f 72 20 41 6e 64 72   is due for Andr
0120: 65 61 73 20 4b 75 70 72 69 65 73 20 28 61 2e 6b  eas Kupries (a.k
0130: 75 70 72 69 65 73 40 77 65 73 74 65 6e 64 2e 63  upries@westend.c
0140: 6f 6d 29 2c 20 66 6f 72 0a 20 2a 20 70 72 6f 76  om), for. * prov
0150: 69 64 69 6e 67 20 74 68 65 20 54 63 6c 5f 52 65  iding the Tcl_Re
0160: 70 6c 61 63 65 43 68 61 6e 6e 65 6c 20 6d 65 63  placeChannel mec
0170: 68 61 6e 69 73 6d 20 61 6e 64 20 77 6f 72 6b 69  hanism and worki
0180: 6e 67 20 63 6c 6f 73 65 6c 79 20 77 69 74 68 20  ng closely with 
0190: 6d 65 0a 20 2a 20 74 6f 20 65 6e 68 61 6e 63 65  me. * to enhance
01a0: 20 69 74 20 74 6f 20 73 75 70 70 6f 72 74 20 66   it to support f
01b0: 75 6c 6c 20 66 69 6c 65 65 76 65 6e 74 20 73 65  ull fileevent se
01c0: 6d 61 6e 74 69 63 73 2e 0a 20 2a 0a 20 2a 20 41  mantics.. *. * A
01d0: 6c 73 6f 20 77 6f 72 6b 20 64 6f 6e 65 20 62 79  lso work done by
01e0: 20 74 68 65 20 66 6f 6c 6c 6f 77 20 70 65 6f 70   the follow peop
01f0: 6c 65 20 70 72 6f 76 69 64 65 64 20 74 68 65 20  le provided the 
0200: 69 6d 70 65 74 75 73 20 74 6f 20 64 6f 20 74 68  impetus to do th
0210: 69 73 20 22 72 69 67 68 74 22 3a 2d 0a 20 2a 09  is "right":-. *.
0220: 74 63 6c 53 53 4c 20 28 43 6f 6c 69 6e 20 4d 63  tclSSL (Colin Mc
0230: 43 6f 72 6d 61 63 6b 2c 20 53 68 61 72 65 64 20  Cormack, Shared 
0240: 54 65 63 68 6e 6f 6c 6f 67 79 29 0a 20 2a 09 53  Technology). *.S
0250: 53 4c 74 63 6c 20 28 50 65 74 65 72 20 41 6e 74  SLtcl (Peter Ant
0260: 6d 61 6e 29 0a 20 2a 0a 20 2a 2f 0a 23 69 66 6e  man). *. */.#ifn
0270: 64 65 66 20 5f 54 4c 53 5f 48 0a 23 64 65 66 69  def _TLS_H.#defi
0280: 6e 65 20 5f 54 4c 53 5f 48 0a 0a 23 69 6e 63 6c  ne _TLS_H..#incl
0290: 75 64 65 20 3c 74 63 6c 2e 68 3e 09 2f 2a 20 49  ude <tcl.h>./* I
02a0: 6e 74 65 72 6e 61 6c 20 64 65 66 69 6e 69 74 69  nternal definiti
02b0: 6f 6e 73 20 66 6f 72 20 54 63 6c 2e 20 2a 2f 0a  ons for Tcl. */.
02c0: 0a 23 69 66 64 65 66 20 54 43 4c 5f 53 54 4f 52  .#ifdef TCL_STOR
02d0: 41 47 45 5f 43 4c 41 53 53 0a 23 20 75 6e 64 65  AGE_CLASS.# unde
02e0: 66 20 54 43 4c 5f 53 54 4f 52 41 47 45 5f 43 4c  f TCL_STORAGE_CL
02f0: 41 53 53 0a 23 65 6e 64 69 66 0a 23 69 66 64 65  ASS.#endif.#ifde
0300: 66 20 42 55 49 4c 44 5f 74 6c 73 0a 23 20 64 65  f BUILD_tls.# de
0310: 66 69 6e 65 20 54 43 4c 5f 53 54 4f 52 41 47 45  fine TCL_STORAGE
0320: 5f 43 4c 41 53 53 20 44 4c 4c 45 58 50 4f 52 54  _CLASS DLLEXPORT
0330: 0a 23 65 6c 73 65 0a 23 20 64 65 66 69 6e 65 20  .#else.# define 
0340: 54 43 4c 5f 53 54 4f 52 41 47 45 5f 43 4c 41 53  TCL_STORAGE_CLAS
0350: 53 20 44 4c 4c 49 4d 50 4f 52 54 0a 23 65 6e 64  S DLLIMPORT.#end
0360: 69 66 0a 0a 2f 2a 0a 20 2a 20 46 6f 72 77 61 72  if../*. * Forwar
0370: 64 20 64 65 63 6c 61 72 61 74 69 6f 6e 73 0a 20  d declarations. 
0380: 2a 2f 0a 0a 45 58 54 45 52 4e 20 69 6e 74 20 54  */..EXTERN int T
0390: 6c 73 5f 49 6e 69 74 20 5f 41 4e 53 49 5f 41 52  ls_Init _ANSI_AR
03a0: 47 53 5f 20 28 28 54 63 6c 5f 49 6e 74 65 72 70  GS_ ((Tcl_Interp
03b0: 20 2a 29 29 3b 0a 45 58 54 45 52 4e 20 69 6e 74   *));.EXTERN int
03c0: 20 54 6c 73 5f 53 61 66 65 49 6e 69 74 20 5f 41   Tls_SafeInit _A
03d0: 4e 53 49 5f 41 52 47 53 5f 20 28 28 54 63 6c 5f  NSI_ARGS_ ((Tcl_
03e0: 49 6e 74 65 72 70 20 2a 29 29 3b 0a 0a 23 65 6e  Interp *));..#en
03f0: 64 69 66 20 2f 2a 20 5f 54 4c 53 5f 48 20 2a 2f  dif /* _TLS_H */
0400: 0a                                               .