xref: /aosp_15_r20/external/curl/tests/data/test167 (revision 6236dae45794135f37c4eb022389c904c8b0090d)
1*6236dae4SAndroid Build Coastguard Worker<testcase>
2*6236dae4SAndroid Build Coastguard Worker<info>
3*6236dae4SAndroid Build Coastguard Worker<keywords>
4*6236dae4SAndroid Build Coastguard WorkerHTTP
5*6236dae4SAndroid Build Coastguard WorkerHTTP GET
6*6236dae4SAndroid Build Coastguard WorkerHTTP proxy
7*6236dae4SAndroid Build Coastguard WorkerHTTP proxy Basic auth
8*6236dae4SAndroid Build Coastguard WorkerHTTP Digest auth
9*6236dae4SAndroid Build Coastguard Worker</keywords>
10*6236dae4SAndroid Build Coastguard Worker</info>
11*6236dae4SAndroid Build Coastguard Worker
12*6236dae4SAndroid Build Coastguard Worker# Server-side
13*6236dae4SAndroid Build Coastguard Worker<reply>
14*6236dae4SAndroid Build Coastguard Worker<data>
15*6236dae4SAndroid Build Coastguard WorkerHTTP/1.1 401 Authorization Required swsclose
16*6236dae4SAndroid Build Coastguard WorkerWWW-Authenticate: Digest realm="weirdorealm", nonce="12345"
17*6236dae4SAndroid Build Coastguard Worker
18*6236dae4SAndroid Build Coastguard Worker</data>
19*6236dae4SAndroid Build Coastguard Worker
20*6236dae4SAndroid Build Coastguard Worker<data1000>
21*6236dae4SAndroid Build Coastguard WorkerHTTP/1.1 200 OK swsclose
22*6236dae4SAndroid Build Coastguard WorkerServer: no
23*6236dae4SAndroid Build Coastguard WorkerContent-Length: 15
24*6236dae4SAndroid Build Coastguard Worker
25*6236dae4SAndroid Build Coastguard WorkerNice auth sir!
26*6236dae4SAndroid Build Coastguard Worker</data1000>
27*6236dae4SAndroid Build Coastguard Worker
28*6236dae4SAndroid Build Coastguard Worker<datacheck>
29*6236dae4SAndroid Build Coastguard WorkerHTTP/1.1 401 Authorization Required swsclose
30*6236dae4SAndroid Build Coastguard WorkerWWW-Authenticate: Digest realm="weirdorealm", nonce="12345"
31*6236dae4SAndroid Build Coastguard Worker
32*6236dae4SAndroid Build Coastguard WorkerHTTP/1.1 200 OK swsclose
33*6236dae4SAndroid Build Coastguard WorkerServer: no
34*6236dae4SAndroid Build Coastguard WorkerContent-Length: 15
35*6236dae4SAndroid Build Coastguard Worker
36*6236dae4SAndroid Build Coastguard WorkerNice auth sir!
37*6236dae4SAndroid Build Coastguard Worker</datacheck>
38*6236dae4SAndroid Build Coastguard Worker</reply>
39*6236dae4SAndroid Build Coastguard Worker
40*6236dae4SAndroid Build Coastguard Worker# Client-side
41*6236dae4SAndroid Build Coastguard Worker<client>
42*6236dae4SAndroid Build Coastguard Worker<server>
43*6236dae4SAndroid Build Coastguard Workerhttp
44*6236dae4SAndroid Build Coastguard Worker</server>
45*6236dae4SAndroid Build Coastguard Worker<features>
46*6236dae4SAndroid Build Coastguard Worker!SSPI
47*6236dae4SAndroid Build Coastguard Workercrypto
48*6236dae4SAndroid Build Coastguard Workerproxy
49*6236dae4SAndroid Build Coastguard Worker</features>
50*6236dae4SAndroid Build Coastguard Worker<name>
51*6236dae4SAndroid Build Coastguard WorkerHTTP with proxy-requiring-Basic to site-requiring-Digest
52*6236dae4SAndroid Build Coastguard Worker</name>
53*6236dae4SAndroid Build Coastguard Worker<command>
54*6236dae4SAndroid Build Coastguard Workerhttp://data.from.server.requiring.digest.hohoho.com/%TESTNUMBER --proxy http://%HOSTIP:%HTTPPORT --proxy-user foo:bar --digest --user digest:alot
55*6236dae4SAndroid Build Coastguard Worker</command>
56*6236dae4SAndroid Build Coastguard Worker</client>
57*6236dae4SAndroid Build Coastguard Worker
58*6236dae4SAndroid Build Coastguard Worker# Verify data after the test has been "shot"
59*6236dae4SAndroid Build Coastguard Worker<verify>
60*6236dae4SAndroid Build Coastguard Worker<protocol>
61*6236dae4SAndroid Build Coastguard WorkerGET http://data.from.server.requiring.digest.hohoho.com/%TESTNUMBER HTTP/1.1
62*6236dae4SAndroid Build Coastguard WorkerHost: data.from.server.requiring.digest.hohoho.com
63*6236dae4SAndroid Build Coastguard WorkerProxy-Authorization: Basic Zm9vOmJhcg==
64*6236dae4SAndroid Build Coastguard WorkerUser-Agent: curl/%VERSION
65*6236dae4SAndroid Build Coastguard WorkerAccept: */*
66*6236dae4SAndroid Build Coastguard WorkerProxy-Connection: Keep-Alive
67*6236dae4SAndroid Build Coastguard Worker
68*6236dae4SAndroid Build Coastguard WorkerGET http://data.from.server.requiring.digest.hohoho.com/%TESTNUMBER HTTP/1.1
69*6236dae4SAndroid Build Coastguard WorkerHost: data.from.server.requiring.digest.hohoho.com
70*6236dae4SAndroid Build Coastguard WorkerProxy-Authorization: Basic Zm9vOmJhcg==
71*6236dae4SAndroid Build Coastguard WorkerAuthorization: Digest username="digest", realm="weirdorealm", nonce="12345", uri="/%TESTNUMBER", response="13c7c02a252cbe1c46d8669898a3be26"
72*6236dae4SAndroid Build Coastguard WorkerUser-Agent: curl/%VERSION
73*6236dae4SAndroid Build Coastguard WorkerAccept: */*
74*6236dae4SAndroid Build Coastguard WorkerProxy-Connection: Keep-Alive
75*6236dae4SAndroid Build Coastguard Worker
76*6236dae4SAndroid Build Coastguard Worker</protocol>
77*6236dae4SAndroid Build Coastguard Worker</verify>
78*6236dae4SAndroid Build Coastguard Worker</testcase>
79