test1270 (1291B)
1 <testcase> 2 <info> 3 <keywords> 4 HTTP 5 HTTP GET 6 redirect_url 7 followlocation 8 --write-out 9 </keywords> 10 </info> 11 12 # Server-side 13 <reply> 14 <data nocheck="yes"> 15 HTTP/1.1 302 Captive Portal 16 Server: ohlala/2000 17 Date: Tue, 17 Dec 2019 13:08:30 GMT 18 Cache-Control: no-cache,no-store,must-revalidate,post-check=0,pre-check=0 19 Location: https://moo.moo.moo 20 Content-Type: text/html; charset=utf-8 21 X-Frame-Options: SAMEORIGIN 22 Strict-Transport-Security: max-age=604800 23 Content-Length: 0 24 Connection: close 25 26 </data> 27 </reply> 28 29 # Client-side 30 <client> 31 <server> 32 http 33 </server> 34 <name> 35 Basic 'redirect_url' 36 </name> 37 <command> 38 http://%HOSTIP:%HTTPPORT/we/want/our/%TESTNUMBER -w '%{redirect_url}\n' -s 39 </command> 40 </client> 41 42 # Verify data after the test has been "shot" 43 <verify> 44 <protocol> 45 GET /we/want/our/%TESTNUMBER HTTP/1.1 46 Host: %HOSTIP:%HTTPPORT 47 User-Agent: curl/%VERSION 48 Accept: */* 49 50 </protocol> 51 52 <stdout> 53 HTTP/1.1 302 Captive Portal 54 Server: ohlala/2000 55 Date: Tue, 17 Dec 2019 13:08:30 GMT 56 Cache-Control: no-cache,no-store,must-revalidate,post-check=0,pre-check=0 57 Location: https://moo.moo.moo 58 Content-Type: text/html; charset=utf-8 59 X-Frame-Options: SAMEORIGIN 60 Strict-Transport-Security: max-age=604800 61 Content-Length: 0 62 Connection: close 63 64 https://moo.moo.moo/ 65 </stdout> 66 </verify> 67 </testcase>