diff options
Diffstat (limited to 'tls/tests/keytest1.tcl')
-rw-r--r-- | tls/tests/keytest1.tcl | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tls/tests/keytest1.tcl b/tls/tests/keytest1.tcl new file mode 100644 index 0000000..4076d69 --- /dev/null +++ b/tls/tests/keytest1.tcl @@ -0,0 +1,23 @@ +#!/bin/sh
+# The next line is executed by /bin/sh, but not tcl \
+exec tclsh "$0" ${1+"$@"}
+
+package require tls
+
+proc creadable {s} {
+ puts "LINE=[gets $s]"
+ after 2000
+ exit
+}
+
+proc myserv {s args} {
+ fileevent $s readable [list creadable $s]
+}
+
+tls::misc req 1024 $keyfile $certfile [list C CCC ST STTT L LLLL O OOOO OU OUUUU CN CNNNN Email some@email.com days 730 serial 12]
+
+tls::socket -keyfile $keyfile -certfile $certfile -server myserv 12300
+
+puts "Now run keytest2.tcl"
+vwait forever
+
|