blob: c513259b0c4c01bef6f6f3d2fe657fd9c4577fc4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
--- a/tests/ssl.test
+++ b/tests/ssl.test
@@ -56,34 +56,4 @@ test ssl-1.2 {puts/gets} {
}
} {a g a i n}
-test ssl-2.1 {https to google.com, gets} -body {
- set c [[socket stream www.google.com:443] ssl]
- $c puts -nonewline "GET / HTTP/1.0\r\n\r\n"
- $c flush
- set lines {}
- while {[$c gets buf] >= 0} {
- lappend lines $buf
- }
- $c close
- join $lines \n
-} -match glob -result {HTTP/1.0 200 OK*</html>}
-
-test ssl-2.2 {https to google.com, read with cert verify} -body {
- # Note that in order to verify the cert, we need sni
- set c [[socket stream www.google.com:443] ssl -sni www.google.com]
- # Verify the cert (note that this does not check CN)
- $c verify
- $c puts -nonewline "GET / HTTP/1.0\r\n\r\n"
- $c flush
- set buf [$c read]
-} -match glob -result {HTTP/1.0 200 OK*</html>}
-
-test ssl-2.3 {ssl to google.com on port 80} -body {
- # Try to talk SSL to a non-SSL server
- set c [[socket stream www.google.com:80] ssl]
- $c puts -nonewline "GET / HTTP/1.0\r\n\r\n"
- $c flush
- set buf [$c read]
-} -returnCodes error -match glob -result {error:*}
-
testreport
|