Skip to content

Instantly share code, notes, and snippets.

@elblivion
Last active March 29, 2018 07:44
Show Gist options
  • Save elblivion/9f41eacdc15f92d68ea8e0d57caf59be to your computer and use it in GitHub Desktop.
Save elblivion/9f41eacdc15f92d68ea8e0d57caf59be to your computer and use it in GitHub Desktop.
curlformat
Timings:
DNS lookup: %{time_namelookup}
Connection: %{time_connect}
SSL negotiation: %{time_appconnect}
Total: %{time_total}
\n
$ curl -sSvo /dev/null -w "$(curl -sSLo - https://gist.github.com/elblivion/9f41eacdc15f92d68ea8e0d57caf59be/raw/64337cb581d4ec4037ef5a469fea09dca20b6047/curlformat)" $URL
* Trying 52.85.173.103...
* TCP_NODELAY set
* Connected to images.ctfassets.net (52.85.173.103) port 443 (#0)
* ALPN, offering http/1.1
* Cipher selection: ALL:!EXPORT:!EXPORT40:!EXPORT56:!aNULL:!LOW:!RC4:@STRENGTH
* successfully set certificate verify locations:
* CAfile: /etc/ssl/certs/ca-certificates.crt
CApath: /etc/ssl/certs
* TLSv1.2 (OUT), TLS header, Certificate Status (22):
} [5 bytes data]
* TLSv1.2 (OUT), TLS handshake, Client hello (1):
} [512 bytes data]
* TLSv1.2 (IN), TLS handshake, Server hello (2):
{ [76 bytes data]
* TLSv1.2 (IN), TLS handshake, Certificate (11):
{ [4583 bytes data]
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
{ [333 bytes data]
* TLSv1.2 (IN), TLS handshake, Server finished (14):
{ [4 bytes data]
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
} [70 bytes data]
* TLSv1.2 (OUT), TLS change cipher, Client hello (1):
} [1 bytes data]
* TLSv1.2 (OUT), TLS handshake, Finished (20):
} [16 bytes data]
* TLSv1.2 (IN), TLS change cipher, Client hello (1):
{ [1 bytes data]
* TLSv1.2 (IN), TLS handshake, Finished (20):
{ [16 bytes data]
* SSL connection using TLSv1.2 / ECDHE-RSA-AES128-GCM-SHA256
* ALPN, server accepted to use http/1.1
* Server certificate:
* subject: CN=images.contentful.com
* start date: Jun 2 00:00:00 2017 GMT
* expire date: Jul 2 12:00:00 2018 GMT
* subjectAltName: host "images.ctfassets.net" matched cert's "images.ctfassets.net"
* issuer: C=US; O=Amazon; OU=Server CA 1B; CN=Amazon
* SSL certificate verify ok.
} [5 bytes data]
> GET /cfexampleapi/1x0xpXu4pSGS4OukSyWGUK/cc1239c6385428ef26f4180190532818/doge.jpg?w=800 HTTP/1.1
> Host: images.ctfassets.net
> User-Agent: curl/7.55.1
> Accept: */*
>
{ [5 bytes data]
< HTTP/1.1 200 OK
< Content-Type: image/jpeg
< Content-Length: 33583
< Connection: keep-alive
< ETag: "dd3781000b62cfc9db4cbf6eb3112b19"
< Cache-Control: public, max-age=2592000
< Access-Control-Allow-Origin: *
< X-Cloud-Trace-Context: 41136bda09841f71a499a02448b62723
< Date: Sun, 04 Mar 2018 09:41:30 GMT
< Server: Google Frontend
< Age: 2152942
< X-Cache: Hit from cloudfront
< Via: 1.1 55ee6ea70e0823309f10db2e4b8f119f.cloudfront.net (CloudFront)
< X-Amz-Cf-Id: ajpsMtIFjfB0qil2XCBnu0xdAUa3lnfTD7Gjg2v_HH3hgE34YcyzLQ==
<
{ [5 bytes data]
* Connection #0 to host images.ctfassets.net left intact
Timings:
DNS lookup: 0.060697
Connection: 0.084064
SSL negotiation: 0.188102
Total: 0.231517
URL=https://images.ctfassets.net/cfexampleapi/1x0xpXu4pSGS4OukSyWGUK/cc1239c6385428ef26f4180190532818/doge.jpg?w=800
curl -sSvo /dev/null -w "$(curl -sSLo - https://gist.github.com/elblivion/9f41eacdc15f92d68ea8e0d57caf59be/raw/64337cb581d4ec4037ef5a469fea09dca20b6047/curlformat)" $URL
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment