xref: /aosp_15_r20/external/curl/tests/data/test783 (revision 6236dae45794135f37c4eb022389c904c8b0090d)
1<testcase>
2<info>
3<keywords>
4HTTP
5HTTP proxy
6HSTS
7</keywords>
8</info>
9
10<reply>
11
12# we use this as response to a CONNECT
13<connect nocheck="yes">
14HTTP/1.1 200 OK
15Server: fake
16
17</connect>
18
19<data nocheck="yes">
20HTTP/1.1 200 OK
21Date: Tue, 09 Nov 2010 14:49:00 GMT
22Server: test-server/fake swsclose
23Content-Type: text/html
24Funny-head: yesyes
25Strict-Transport-Security: max-age=1000;
26
27</data>
28</reply>
29
30<client>
31<server>
32http
33http-proxy
34https
35</server>
36<features>
37HSTS
38proxy
39https
40Debug
41large-time
42</features>
43
44<setenv>
45CURL_HSTS_HTTP=yes
46CURL_TIME=1728465947
47</setenv>
48
49<file name="%LOGDIR/input%TESTNUMBER">
50.hsts.example "20991001 04:47:41"
51.this.hsts.example "99991001 04:47:41"
52</file>
53
54<name>
55HSTS update expiry, removing includesubdomains in update
56</name>
57<command>
58-x http://%HOSTIP:%PROXYPORT http://this.hsts.example:%HTTPSPORT/%TESTNUMBER --hsts %LOGDIR/input%TESTNUMBER -k
59</command>
60</client>
61
62<verify>
63
64<stdout>
65HTTP/1.1 200 OK
66Server: fake
67
68HTTP/1.1 200 OK
69Date: Tue, 09 Nov 2010 14:49:00 GMT
70Server: test-server/fake swsclose
71Content-Type: text/html
72Funny-head: yesyes
73Strict-Transport-Security: max-age=1000;
74
75</stdout>
76
77<file name="%LOGDIR/input%TESTNUMBER" mode="text">
78# Your HSTS cache. https://curl.se/docs/hsts.html
79# This file was generated by libcurl! Edit at your own risk.
80.hsts.example "20991001 04:47:41"
81this.hsts.example "20241009 09:42:27"
82</file>
83</verify>
84</testcase>
85