xf.li | 6c8fc1e | 2023-08-12 00:11:09 -0700 | [diff] [blame^] | 1 | <testcase> |
| 2 | <info> |
| 3 | <keywords> |
| 4 | HTTP |
| 5 | HTTP GET |
| 6 | HTTP NTLM auth |
| 7 | followlocation |
| 8 | NTLM |
| 9 | </keywords> |
| 10 | </info> |
| 11 | # Server-side |
| 12 | <reply> |
| 13 | |
| 14 | <!-- no <data> in this test since we have NTLM from the start |
| 15 | |
| 16 | This is supposed to be returned when the server gets a first |
| 17 | Authorization: NTLM line passed-in from the client --> |
| 18 | |
| 19 | <data1001> |
| 20 | HTTP/1.1 401 Now gimme that second request of crap
|
| 21 | Server: Microsoft-IIS/5.0
|
| 22 | Content-Type: text/html; charset=iso-8859-1
|
| 23 | Content-Length: 34
|
| 24 | WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
|
| 25 |
|
| 26 | This is not the real page either! |
| 27 | </data1001> |
| 28 | |
| 29 | # This is supposed to be returned when the server gets the second |
| 30 | # Authorization: NTLM line passed-in from the client |
| 31 | <data1002> |
| 32 | HTTP/1.1 301 Things are fine in server land swsclose
|
| 33 | Server: Microsoft-IIS/5.0
|
| 34 | Connection: close
|
| 35 | Location: /you/%TESTNUMBER0010
|
| 36 |
|
| 37 | </data1002> |
| 38 | |
| 39 | # This is the first reply after the redirection |
| 40 | <data1011> |
| 41 | HTTP/1.1 401 Now gimme that second round of crap
|
| 42 | Server: Microsoft-IIS/5.0
|
| 43 | Content-Type: text/html; charset=iso-8859-1
|
| 44 | Content-Length: 34
|
| 45 | WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
|
| 46 |
|
| 47 | This is not the real page either! |
| 48 | </data1011> |
| 49 | |
| 50 | # This is supposed to be returned when the server gets the second |
| 51 | # Authorization: NTLM line passed-in from the client |
| 52 | <data1012> |
| 53 | HTTP/1.1 200 Things are fine in server land swsclose
|
| 54 | Server: Microsoft-IIS/5.0
|
| 55 | Content-Type: text/html; charset=iso-8859-1
|
| 56 | Content-Length: 32
|
| 57 |
|
| 58 | Finally, this is the real page! |
| 59 | </data1012> |
| 60 | |
| 61 | <datacheck> |
| 62 | HTTP/1.1 401 Now gimme that second request of crap
|
| 63 | Server: Microsoft-IIS/5.0
|
| 64 | Content-Type: text/html; charset=iso-8859-1
|
| 65 | Content-Length: 34
|
| 66 | WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
|
| 67 |
|
| 68 | HTTP/1.1 301 Things are fine in server land swsclose
|
| 69 | Server: Microsoft-IIS/5.0
|
| 70 | Connection: close
|
| 71 | Location: /you/%TESTNUMBER0010
|
| 72 |
|
| 73 | HTTP/1.1 401 Now gimme that second round of crap
|
| 74 | Server: Microsoft-IIS/5.0
|
| 75 | Content-Type: text/html; charset=iso-8859-1
|
| 76 | Content-Length: 34
|
| 77 | WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
|
| 78 |
|
| 79 | HTTP/1.1 200 Things are fine in server land swsclose
|
| 80 | Server: Microsoft-IIS/5.0
|
| 81 | Content-Type: text/html; charset=iso-8859-1
|
| 82 | Content-Length: 32
|
| 83 |
|
| 84 | Finally, this is the real page! |
| 85 | </datacheck> |
| 86 | |
| 87 | </reply> |
| 88 | |
| 89 | # Client-side |
| 90 | <client> |
| 91 | <features> |
| 92 | NTLM |
| 93 | SSL |
| 94 | !SSPI |
| 95 | </features> |
| 96 | <server> |
| 97 | http |
| 98 | </server> |
| 99 | <name> |
| 100 | HTTP with NTLM and follow-location |
| 101 | </name> |
| 102 | <command> |
| 103 | http://%HOSTIP:%HTTPPORT/%TESTNUMBER -u testuser:testpass --ntlm -L |
| 104 | </command> |
| 105 | </client> |
| 106 | |
| 107 | # Verify data after the test has been "shot" |
| 108 | <verify> |
| 109 | <protocol> |
| 110 | GET /%TESTNUMBER HTTP/1.1
|
| 111 | Host: %HOSTIP:%HTTPPORT
|
| 112 | Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=
|
| 113 | User-Agent: curl/%VERSION
|
| 114 | Accept: */*
|
| 115 |
|
| 116 | GET /%TESTNUMBER HTTP/1.1
|
| 117 | Host: %HOSTIP:%HTTPPORT
|
| 118 | Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAALAAsAeAAAAAAAAAAAAAAAhoIBAFpkQwKRCZFMhjj0tw47wEjKHRHlvzfxQamFcheMuv8v+xeqphEO5V41xRd7R9deOXRlc3R1c2VyV09SS1NUQVRJT04=
|
| 119 | User-Agent: curl/%VERSION
|
| 120 | Accept: */*
|
| 121 |
|
| 122 | GET /you/%TESTNUMBER0010 HTTP/1.1
|
| 123 | Host: %HOSTIP:%HTTPPORT
|
| 124 | Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=
|
| 125 | User-Agent: curl/%VERSION
|
| 126 | Accept: */*
|
| 127 |
|
| 128 | GET /you/%TESTNUMBER0010 HTTP/1.1
|
| 129 | Host: %HOSTIP:%HTTPPORT
|
| 130 | Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAALAAsAeAAAAAAAAAAAAAAAhoIBAFpkQwKRCZFMhjj0tw47wEjKHRHlvzfxQamFcheMuv8v+xeqphEO5V41xRd7R9deOXRlc3R1c2VyV09SS1NUQVRJT04=
|
| 131 | User-Agent: curl/%VERSION
|
| 132 | Accept: */*
|
| 133 |
|
| 134 | </protocol> |
| 135 | </verify> |
| 136 | </testcase> |