xf.li | 6c8fc1e | 2023-08-12 00:11:09 -0700 | [diff] [blame^] | 1 | <testcase> |
| 2 | <info> |
| 3 | <keywords> |
| 4 | HTTP |
| 5 | HTTP POST |
| 6 | HTTP proxy |
| 7 | HTTP proxy NTLM auth |
| 8 | NTLM |
| 9 | </keywords> |
| 10 | </info> |
| 11 | |
| 12 | # Server-side |
| 13 | <reply> |
| 14 | |
| 15 | # this is returned first since we get no proxy-auth |
| 16 | <data1001> |
| 17 | HTTP/1.1 407 Authorization Required to proxy me my dear
|
| 18 | Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
|
| 19 | Content-Length: 34
|
| 20 |
|
| 21 | Hey you, authenticate or go away! |
| 22 | </data1001> |
| 23 | |
| 24 | # This is supposed to be returned when the server gets the second |
| 25 | # Authorization: NTLM line passed-in from the client |
| 26 | <data1002> |
| 27 | HTTP/1.1 200 Things are fine in proxy land swsclose
|
| 28 | Server: Microsoft-IIS/5.0
|
| 29 | Content-Type: text/html; charset=iso-8859-1
|
| 30 | Content-Length: 42
|
| 31 |
|
| 32 | Contents of that page you requested, sir. |
| 33 | </data1002> |
| 34 | |
| 35 | <datacheck> |
| 36 | HTTP/1.1 407 Authorization Required to proxy me my dear
|
| 37 | Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
|
| 38 | Content-Length: 34
|
| 39 |
|
| 40 | HTTP/1.1 200 Things are fine in proxy land swsclose
|
| 41 | Server: Microsoft-IIS/5.0
|
| 42 | Content-Type: text/html; charset=iso-8859-1
|
| 43 | Content-Length: 42
|
| 44 |
|
| 45 | Contents of that page you requested, sir. |
| 46 | </datacheck> |
| 47 | </reply> |
| 48 | |
| 49 | # Client-side |
| 50 | <client> |
| 51 | <server> |
| 52 | http |
| 53 | </server> |
| 54 | <features> |
| 55 | NTLM |
| 56 | SSL |
| 57 | !SSPI |
| 58 | proxy |
| 59 | </features> |
| 60 | <name> |
| 61 | HTTP proxy-auth NTLM and then POST |
| 62 | </name> |
| 63 | <command> |
| 64 | http://%HOSTIP:%HTTPPORT/%TESTNUMBER --proxy http://%HOSTIP:%HTTPPORT --proxy-user testuser:testpass --proxy-ntlm -d "postit" |
| 65 | </command> |
| 66 | </client> |
| 67 | |
| 68 | # Verify data after the test has been "shot" |
| 69 | <verify> |
| 70 | <protocol nonewline="yes"> |
| 71 | POST http://%HOSTIP:%HTTPPORT/%TESTNUMBER HTTP/1.1
|
| 72 | Host: %HOSTIP:%HTTPPORT
|
| 73 | Proxy-Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=
|
| 74 | User-Agent: curl/%VERSION
|
| 75 | Accept: */*
|
| 76 | Proxy-Connection: Keep-Alive
|
| 77 | Content-Length: 0
|
| 78 | Content-Type: application/x-www-form-urlencoded
|
| 79 |
|
| 80 | POST http://%HOSTIP:%HTTPPORT/%TESTNUMBER HTTP/1.1
|
| 81 | Host: %HOSTIP:%HTTPPORT
|
| 82 | Proxy-Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAALAAsAeAAAAAAAAAAAAAAAhoIBAFpkQwKRCZFMhjj0tw47wEjKHRHlvzfxQamFcheMuv8v+xeqphEO5V41xRd7R9deOXRlc3R1c2VyV09SS1NUQVRJT04=
|
| 83 | User-Agent: curl/%VERSION
|
| 84 | Accept: */*
|
| 85 | Proxy-Connection: Keep-Alive
|
| 86 | Content-Length: 6
|
| 87 | Content-Type: application/x-www-form-urlencoded
|
| 88 |
|
| 89 | postit |
| 90 | </protocol> |
| 91 | </verify> |
| 92 | </testcase> |