Check internet proxy with curl command on Linux

When your services must talk to the Internet proxy to go out of your secured networks, how can you verify that proxy being effective? In this post, I am going to give you a way to do so by using the curl command.

Table of Contents

Introduction

Recently, I have had to deploy our team services in Kubernetes managed by a web production team. Due to security concerns, all coming out traffics to the Internet must be passed the proxy. My services cannot be often accessed from outside Kubernetes cluster though all Kubernetes manifests look good. The first thing I suspected is the internet proxy because it used to mad me when I deployed the same services in the other data centre. I have struggled to test internet connection from Kubernetes pods, hence I want to record a simple way of doing so with the curl command in this post.

The curl command or any other tools requiring an internet proxy will check in the list of environment variables to get the setting of the proxy. If it was not set, the command won’t run appropriately. Under Unix-based operating systems, the following commands will display whether the proxy has been set or not.

env | grep proxy

If it is not the case, the next section will help us define environment variables for the proxy.

How-to-do steps

The general syntax to set proxy looks like the following snippet

## Set the proxy address of your uni/company/vpn network ## 
## HTTP version ##
# export http_proxy=http://your-ip-address:port/
export http_proxy=http://wwwcache.itersdesktop.com:1982
 
## http_proxy with username and password 
export http_proxy=http://user:password@your-proxy-ip-address:port/
 
## HTTPS version ##
# export https_proxy=https://your-ip-address:port/
# export https_proxy=https://user:password@your-proxy-ip-address:port/
export https_proxy=https://wwwcache.itersdesktop.com:1982

Try to apply for Google search website: https://www.google.co.uk

curl -I https://www.google.co.uk
curl -v -I https://www.google.co.uk

Sample outputs:

tc_pst03@flask-demo-798488fdd4-9ts5z:~/biomodels/dbtest$ curl -v -I https://www.google.co.uk
* Expire in 0 ms for 6 (transfer 0x55f2cc31af90)
* Uses proxy env variable no_proxy == 'localhost,.cluster.local'
* Uses proxy env variable https_proxy == 'http://hx-wwwcache.itersdesktop.com:1982'
* Expire in 1 ms for 1 (transfer 0x55f2cc31af90)
....
....
....
* Expire in 1 ms for 1 (transfer 0x55f2cc31af90)
* Expire in 1 ms for 1 (transfer 0x55f2cc31af90)
* Could not resolve proxy: hx-wwwcache.itersdesktop.com
* Expire in 1 ms for 1 (transfer 0x55f2cc31af90)
* Closing connection 0
curl: (5) Could not resolve proxy: hx-wwwcache.itersdesktop.com

The outputs above reveal that the curl command could not resolve proxy which was defined as an environment variable. If the issue is resolved, the outputs likely look as below:

docker@pod2:/app$ curl -v -I https://www.google.co.uk
* Expire in 0 ms for 6 (transfer 0x55641227ae80)
* Uses proxy env variable no_proxy == 'localhost,.cluster.local'
* Uses proxy env variable https_proxy == 'http://hx-wwwcache.itersdesktop.com:1982'
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 0 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 2 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
* Expire in 1 ms for 1 (transfer 0x55641227ae80)
*   Trying 10.7.48.46...
* TCP_NODELAY set
* Expire in 149997 ms for 3 (transfer 0x55641227ae80)
* Expire in 200 ms for 4 (transfer 0x55641227ae80)
* Connected to hx-wwwcache.itersdesktop.com (10.7.48.46) port 1982 (#0)
* allocate connect buffer!
* Establish HTTP proxy tunnel to www.google.co.uk:443
> CONNECT www.google.co.uk:443 HTTP/1.1
> Host: www.google.co.uk:443
> User-Agent: curl/7.64.0
> Proxy-Connection: Keep-Alive
>
< HTTP/1.1 200 Connection established
HTTP/1.1 200 Connection established
<

* Proxy replied 200 to CONNECT request
* CONNECT phase completed!
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
*   CAfile: none
  CApath: /etc/ssl/certs
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* CONNECT phase completed!
* CONNECT phase completed!
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.3 (IN), TLS handshake, Encrypted Extensions (8):
* TLSv1.3 (IN), TLS handshake, Certificate (11):
* TLSv1.3 (IN), TLS handshake, CERT verify (15):
* TLSv1.3 (IN), TLS handshake, Finished (20):
* TLSv1.3 (OUT), TLS change cipher, Change cipher spec (1):
* 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=Mountain View; O=Google LLC; CN=www.google.co.uk
*  start date: Jan 19 08:02:47 2021 GMT
*  expire date: Apr 13 08:02:46 2021 GMT
*  subjectAltName: host "www.google.co.uk" matched cert's "www.google.co.uk"
*  issuer: C=US; O=Google Trust Services; CN=GTS CA 1O1
*  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
* Using Stream ID: 1 (easy handle 0x55641227ae80)
> HEAD / HTTP/2
> Host: www.google.co.uk
> User-Agent: curl/7.64.0
> Accept: */*
>
* TLSv1.3 (IN), TLS handshake, Newsession Ticket (4):
* TLSv1.3 (IN), TLS handshake, Newsession Ticket (4):
* old SSL session ID is stale, removing
* Connection state changed (MAX_CONCURRENT_STREAMS == 100)!
< HTTP/2 200
HTTP/2 200
< content-type: text/html; charset=ISO-8859-1
content-type: text/html; charset=ISO-8859-1
< p3p: CP="This is not a P3P policy! See g.co/p3phelp for more info."
p3p: CP="This is not a P3P policy! See g.co/p3phelp for more info."
< date: Sat, 13 Feb 2021 17:02:06 GMT
date: Sat, 13 Feb 2021 17:02:06 GMT
< server: gws
server: gws
< x-xss-protection: 0
x-xss-protection: 0
< x-frame-options: SAMEORIGIN
x-frame-options: SAMEORIGIN
< expires: Sat, 13 Feb 2021 17:02:06 GMT
expires: Sat, 13 Feb 2021 17:02:06 GMT
< cache-control: private
cache-control: private
< set-cookie: NID=209=gMl9ZI5j5x9xZuE-hM8CqX9ejMgl33bJ3gYazAEQE7_aVk6vHuTCTIoRl15_i0hopJZdQyJxx3hH-U5x0X0jrIEcqXU0KhNVzIPzsjvlrSEBCByv3smuEEDCCBXiAsligULGtmZ4jokW8EoTK07ilGThPL4-7FdnrbB_Nxiog_A; expires=Sun, 15-Aug-2021 17:02:06 GMT; path=/; domain=.google.co.uk; HttpOnly
set-cookie: NID=209=gMl9ZI5j5x9xZuE-hM8CqX9ejMgl33bJ3gYazAEQE7_aVk6vHuTCTIoRl15_i0hopJZdQyJxx3hH-U5x0X0jrIEcqXU0KhNVzIPzsjvlrSEBCByv3smuEEDCCBXiAsligULGtmZ4jokW8EoTK07ilGThPL4-7FdnrbB_Nxiog_A; expires=Sun, 15-Aug-2021 17:02:06 GMT; path=/; domain=.google.co.uk; HttpOnly
< set-cookie: CONSENT=PENDING+467; expires=Fri, 01-Jan-2038 00:00:00 GMT; path=/; domain=.google.co.uk
set-cookie: CONSENT=PENDING+467; expires=Fri, 01-Jan-2038 00:00:00 GMT; path=/; domain=.google.co.uk
< alt-svc: h3-29=":443"; ma=2592000,h3-T051=":443"; ma=2592000,h3-Q050=":443"; ma=2592000,h3-Q046=":443"; ma=2592000,h3-Q043=":443"; ma=2592000,quic=":443"; ma=2592000; v="46,43"
alt-svc: h3-29=":443"; ma=2592000,h3-T051=":443"; ma=2592000,h3-Q050=":443"; ma=2592000,h3-Q046=":443"; ma=2592000,h3-Q043=":443"; ma=2592000,quic=":443"; ma=2592000; v="46,43"

<
* Connection #0 to host hx-wwwcache.itersdesktop.com left intact

That’s it!

Conclusion

The curl command is very common and useful which most developers are using it to test RESTful API as well as the internet connection. If you are interested in catching up my experience, you may subscribe to my weblog to receive the latest posts. Enjoy!

 

Laisser un commentaire

Votre adresse e-mail ne sera pas publiée. Les champs obligatoires sont indiqués avec *

Ce site utilise Akismet pour réduire les indésirables. En savoir plus sur comment les données de vos commentaires sont utilisées.