Page MenuHomePhabricator
Paste P11231

T253114 - example of a request that does not work (via Chrome's "Copy as cURL" option)
ActivePublic

Authored by Tgr on May 19 2020, 10:33 AM.
Tags
None
Referenced Files
F31832800: raw.txt
May 19 2020, 10:33 AM
Subscribers
None
curl -v 'https://hu.wikipedia.org/w/api.php?action=opensearch&format=json&formatversion=2&search=R%C3%A9vai%20Le&namespace=0%7C1%7C2%7C3%7C4%7C5%7C6%7C7%7C8%7C9%7C10%7C11%7C12%7C13%7C14%7C15%7C90%7C91%7C92%7C93%7C100%7C101%7C828%7C829%7C2300%7C2301%7C2302%7C2303&limit=10' \
-H 'authority: hu.wikipedia.org' \
-H 'pragma: no-cache' \
-H 'cache-control: no-cache' \
-H 'accept: application/json, text/javascript, */*; q=0.01' \
-H 'user-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36' \
-H 'x-requested-with: XMLHttpRequest' \
-H 'sec-fetch-site: same-origin' \
-H 'sec-fetch-mode: cors' \
-H 'sec-fetch-dest: empty' \
-H 'referer: https://hu.wikipedia.org/wiki/Kezd%C5%91lap' \
-H 'accept-language: en-US,en;q=0.9,hu;q=0.8' \
-H 'cookie: GeoIP=US:CA:San_Francisco:37.80:-122.41:v4; huwikiUserID=245425; huwikiUserName=Tgr+%28WMF%29; centralauth_User=Tgr+%28WMF%29; centralauth_Token=<redacted>; huwikimwuser-sessionId=<redacted>; forceHTTPS=true; VEE=wikitext; stopMobileRedirect=true; huwikiSession=<redacted>; centralauth_Session=<redacted>; WMF-Last-Access=19-May-2020; WMF-Last-Access-Global=19-May-2020' \
--compressed
* Trying 2620:0:862:ed1a::1...
* TCP_NODELAY set
* Connected to hu.wikipedia.org (2620:0:862:ed1a::1) port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
* CAfile: /etc/ssl/certs/ca-certificates.crt
CApath: /etc/ssl/certs
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.3 (IN), TLS Unknown, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, Unknown (8):
* TLSv1.3 (IN), TLS Unknown, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, Certificate (11):
* TLSv1.3 (IN), TLS Unknown, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, CERT verify (15):
* TLSv1.3 (IN), TLS Unknown, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, Finished (20):
* TLSv1.3 (OUT), TLS change cipher, Client hello (1):
* TLSv1.3 (OUT), TLS Unknown, Certificate Status (22):
* TLSv1.3 (OUT), TLS handshake, Finished (20):
* SSL connection using TLSv1.3 / TLS_AES_256_GCM_SHA384
* ALPN, server accepted to use h2
* Server certificate:
* subject: C=US; ST=California; L=San Francisco; O=Wikimedia Foundation, Inc.; CN=*.wikipedia.org
* start date: Nov 12 00:00:00 2019 GMT
* expire date: Oct 6 12:00:00 2020 GMT
* subjectAltName: host "hu.wikipedia.org" matched cert's "*.wikipedia.org"
* issuer: C=US; O=DigiCert Inc; OU=www.digicert.com; CN=DigiCert SHA2 High Assurance Server CA
* SSL certificate verify ok.
* Using HTTP2, server supports multi-use
* Connection state changed (HTTP/2 confirmed)
* Copying HTTP/2 data in stream buffer to connection buffer after upgrade: len=0
* TLSv1.3 (OUT), TLS Unknown, Unknown (23):
* TLSv1.3 (OUT), TLS Unknown, Unknown (23):
* TLSv1.3 (OUT), TLS Unknown, Unknown (23):
* Using Stream ID: 1 (easy handle 0x55cbe815c580)
* TLSv1.3 (OUT), TLS Unknown, Unknown (23):
> GET /w/api.php?action=opensearch&format=json&formatversion=2&search=R%C3%A9vai%20Le&namespace=0%7C1%7C2%7C3%7C4%7C5%7C6%7C7%7C8%7C9%7C10%7C11%7C12%7C13%7C14%7C15%7C90%7C91%7C92%7C93%7C100%7C101%7C828%7C829%7C2300%7C2301%7C2302%7C2303&limit=10 HTTP/2
> Host: hu.wikipedia.org
> Accept-Encoding: deflate, gzip
> authority: hu.wikipedia.org
> pragma: no-cache
> cache-control: no-cache
> accept: application/json, text/javascript, */*; q=0.01
> user-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36
> x-requested-with: XMLHttpRequest
> sec-fetch-site: same-origin
> sec-fetch-mode: cors
> sec-fetch-dest: empty
> referer: https://hu.wikipedia.org/wiki/Kezd%C5%91lap
> accept-language: en-US,en;q=0.9,hu;q=0.8
> cookie: <redacted>
>
* TLSv1.3 (IN), TLS Unknown, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, Newsession Ticket (4):
* TLSv1.3 (IN), TLS Unknown, Unknown (23):
* Connection state changed (MAX_CONCURRENT_STREAMS updated)!
* TLSv1.3 (OUT), TLS Unknown, Unknown (23):
* TLSv1.3 (IN), TLS Unknown, Unknown (23):
< HTTP/2 200
< date: Tue, 19 May 2020 10:24:26 GMT
< server: mw1408.eqiad.wmnet
< x-content-type-options: nosniff
< x-search-id: 5hw68zt3j64j9tacp7zam4tr8
< x-opensearch-type: comp_suggest
< x-frame-options: DENY
< content-disposition: inline; filename=api-result.json
< vary: Accept-Encoding,Treat-as-Untrusted,X-Forwarded-Proto,Cookie,Authorization
< cache-control: private, must-revalidate, max-age=10800
< content-type: application/json; charset=utf-8
< content-encoding: gzip
< age: 0
< x-cache: cp3052 miss, cp3064 pass
< x-cache-status: pass
< server-timing: cache;desc="pass"
< strict-transport-security: max-age=106384710; includeSubDomains; preload
< x-client-ip: 2a02:ab88:56c3:c880:c564:f7e5:be47:f091
< accept-ranges: bytes
< content-length: 222
<
* Connection #0 to host hu.wikipedia.org left intact
["Révai Le",["Révai nagy lexikona","Révai új lexikona","Révai Testvérek","Révai Dezső","Révai Kereskedelmi, Pénzügyi és Ipari Lexikona"],["","","","",""],["https://hu.wikipedia.org/wiki/R%C3%A9vai_nagy_lexikona","https://hu.wikipedia.org/wiki/R%C3%A9vai_%C3%BAj_lexikona","https://hu.wikipedia.org/wiki/R%C3%A9vai_Testv%C3%A9rek","https://hu.wikipedia.org/wiki/R%C3%A9vai_Dezs%C5%91","https://hu.wikipedia.org/wiki/R%C3%A9vai_Kereskedelmi,_P%C3%A9nz%C3%BCgyi_%C3%A9s_Ipari_Lexikona"]]