xf.li | 6c8fc1e | 2023-08-12 00:11:09 -0700 | [diff] [blame^] | 1 | <testcase> |
| 2 | <info> |
| 3 | <keywords> |
| 4 | HTTP |
| 5 | CURLOPT_AWS_SIGV4 |
| 6 | </keywords> |
| 7 | </info> |
| 8 | |
| 9 | # Server-side |
| 10 | <reply> |
| 11 | <data nocheck="yes"> |
| 12 | HTTP/1.1 302 OK |
| 13 | Date: Thu, 09 Nov 2010 14:49:00 GMT |
| 14 | Server: test-server/fake |
| 15 | Content-Type: text/html |
| 16 | Content-Length: 0 |
| 17 | Location: /%TESTNUMBER0002 |
| 18 | |
| 19 | </data> |
| 20 | <data2> |
| 21 | HTTP/1.1 200 OK |
| 22 | Date: Thu, 09 Nov 2010 14:49:00 GMT |
| 23 | Server: test-server/fake |
| 24 | Content-Type: text/html |
| 25 | Content-Length: 0 |
| 26 | |
| 27 | </data2> |
| 28 | </reply> |
| 29 | |
| 30 | # Client-side |
| 31 | <client> |
| 32 | <server> |
| 33 | http |
| 34 | </server> |
| 35 | # this relies on the debug feature which allow to set the time |
| 36 | <features> |
| 37 | SSL |
| 38 | debug |
| 39 | crypto |
| 40 | </features> |
| 41 | <setenv> |
| 42 | CURL_FORCEHOST=1 |
| 43 | </setenv> |
| 44 | |
| 45 | <name> |
| 46 | HTTP AWS_SIGV4 with X-Xxx-Content-Sha256 |
| 47 | </name> |
| 48 | <tool> |
| 49 | lib%TESTNUMBER |
| 50 | </tool> |
| 51 | |
| 52 | <command> |
| 53 | http://exam.ple.com:9000/%TESTNUMBER/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPPORT |
| 54 | </command> |
| 55 | </client> |
| 56 | |
| 57 | # Verify data after the test has been "shot" |
| 58 | <verify> |
| 59 | <strip> |
| 60 | ^User-Agent:.* |
| 61 | ^Content-Type:.* |
| 62 | ^Accept:.* |
| 63 | </strip> |
| 64 | <protocol> |
| 65 | GET /%TESTNUMBER/testapi/test HTTP/1.1
|
| 66 | Host: exam.ple.com:9000
|
| 67 | Authorization: XXX4-HMAC-SHA256 Credential=xxx/19700101/ple/exam/xxx4_request, SignedHeaders=content-type;host;tesmixcase;test0;test1;test2;test_space;x-xxx-date, Signature=819251feec8de52dfaa992320241f23d27cefa979c93e039ae7df03ac486ed16
|
| 68 | X-Xxx-Date: 19700101T000000Z
|
| 69 | test2: 1234
|
| 70 | test_space: t s m end
|
| 71 | tesMixCase: MixCase
|
| 72 |
|
| 73 | </protocol> |
| 74 | </verify> |
| 75 | </testcase> |