quickjs-tart

quickjs-based runtime for wallet-core logic
Log | Files | Refs | README | LICENSE

test1568 (1771B)


      1 <testcase>
      2 # based on test 64
      3 
      4 <info>
      5 <keywords>
      6 HTTP
      7 HTTP GET
      8 HTTP Digest auth
      9 </keywords>
     10 </info>
     11 
     12 <reply>
     13 <data>
     14 HTTP/1.1 401 Authorization Required swsclose
     15 Server: Apache/1.3.27 (Darwin) PHP/4.1.2
     16 WWW-Authenticate: Digest realm="testrealm", nonce="1053604145"
     17 Content-Type: text/html; charset=iso-8859-1
     18 Content-Length: 26
     19 
     20 This is not the real page
     21 </data>
     22 
     23 # This is supposed to be returned when the server gets a
     24 # Authorization: Digest line passed-in from the client
     25 <data1000>
     26 HTTP/1.1 200 OK swsclose
     27 Server: Apache/1.3.27 (Darwin) PHP/4.1.2
     28 Content-Type: text/html; charset=iso-8859-1
     29 Content-Length: 23
     30 
     31 This IS the real page!
     32 </data1000>
     33 
     34 <datacheck>
     35 HTTP/1.1 401 Authorization Required swsclose
     36 Server: Apache/1.3.27 (Darwin) PHP/4.1.2
     37 WWW-Authenticate: Digest realm="testrealm", nonce="1053604145"
     38 Content-Type: text/html; charset=iso-8859-1
     39 Content-Length: 26
     40 
     41 HTTP/1.1 200 OK swsclose
     42 Server: Apache/1.3.27 (Darwin) PHP/4.1.2
     43 Content-Type: text/html; charset=iso-8859-1
     44 Content-Length: 23
     45 
     46 This IS the real page!
     47 </datacheck>
     48 
     49 </reply>
     50 
     51 # Client-side
     52 <client>
     53 <server>
     54 http
     55 </server>
     56 <features>
     57 !SSPI
     58 crypto
     59 digest
     60 </features>
     61 <name>
     62 HTTP with Digest authorization on custom CURLOPT_PORT
     63 </name>
     64 <tool>
     65 lib%TESTNUMBER
     66 </tool>
     67 <command>
     68 http://%HOSTIP/%TESTNUMBER %HTTPPORT
     69 </command>
     70 </client>
     71 
     72 # Verify data after the test has been "shot"
     73 <verify>
     74 <protocol>
     75 GET /%TESTNUMBER HTTP/1.1
     76 Host: %HOSTIP:%HTTPPORT
     77 User-Agent: lib%TESTNUMBER
     78 Accept: */*
     79 
     80 GET /%TESTNUMBER HTTP/1.1
     81 Host: %HOSTIP:%HTTPPORT
     82 Authorization: Digest username="testuser", realm="testrealm", nonce="1053604145", uri="/%TESTNUMBER", response="9cbbd857a37e45f2bcad5c7d088191df"
     83 User-Agent: lib%TESTNUMBER
     84 Accept: */*
     85 
     86 </protocol>
     87 </verify>
     88 </testcase>