lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 1 | <testcase> |
| 2 | <info> |
| 3 | <keywords> |
| 4 | IMAP |
| 5 | FETCH |
| 6 | HTTP |
| 7 | HTTP CONNECT |
| 8 | HTTP proxy |
| 9 | </keywords> |
| 10 | </info> |
| 11 | |
| 12 | # |
| 13 | # Server-side |
| 14 | <reply> |
| 15 | <connect> |
| 16 | HTTP/1.1 200 Mighty fine indeed
|
| 17 | imap: sure hit me
|
| 18 |
|
| 19 | </connect> |
| 20 | <data> |
| 21 | From: me@somewhere
|
| 22 | To: fake@nowhere
|
| 23 |
|
| 24 | body
|
| 25 |
|
| 26 | --
|
| 27 | yours sincerely
|
| 28 | </data> |
| 29 | <datacheck> |
| 30 | HTTP/1.1 200 Mighty fine indeed
|
| 31 | imap: sure hit me
|
| 32 |
|
| 33 | From: me@somewhere
|
| 34 | To: fake@nowhere
|
| 35 |
|
| 36 | body
|
| 37 |
|
| 38 | --
|
| 39 | yours sincerely
|
| 40 | </datacheck> |
| 41 | </reply> |
| 42 | |
| 43 | # |
| 44 | # Client-side |
| 45 | <client> |
| 46 | <server> |
| 47 | imap |
| 48 | http-proxy |
| 49 | </server> |
| 50 | <features> |
| 51 | http |
| 52 | </features> |
| 53 | <name> |
| 54 | IMAP FETCH tunneled through HTTP proxy |
| 55 | </name> |
| 56 | <command> |
| 57 | 'imap://imap.1321:%IMAPPORT/1321/;UID=1' -u user:secret -p -x %HOSTIP:%PROXYPORT |
| 58 | </command> |
| 59 | </client> |
| 60 | |
| 61 | # |
| 62 | # Verify data after the test has been "shot" |
| 63 | <verify> |
| 64 | <strip> |
| 65 | ^User-Agent: curl/.* |
| 66 | </strip> |
| 67 | <protocol> |
| 68 | A001 CAPABILITY
|
| 69 | A002 LOGIN user secret
|
| 70 | A003 SELECT 1321
|
| 71 | A004 FETCH 1 BODY[]
|
| 72 | A005 LOGOUT
|
| 73 | </protocol> |
| 74 | <proxy> |
| 75 | CONNECT imap.1321:%IMAPPORT HTTP/1.1
|
| 76 | Host: imap.1321:%IMAPPORT
|
| 77 | User-Agent: curl/7.24.0-DEV (i686-pc-linux-gnu) libcurl/7.24.0-DEV OpenSSL/1.0.0e zlib/1.2.3.4 c-ares/1.7.6-DEV libidn/1.23 libssh2/1.4.0_DEV librtmp/2.2e
|
| 78 | Proxy-Connection: Keep-Alive
|
| 79 |
|
| 80 | </proxy> |
| 81 | </verify> |
| 82 | </testcase> |