squidclient1
A simple http web client tool
Usage
squidclient [-aknNrsv]
[--ping
[ping-options]]
[--https]
[tls-options]
[-A
string]
[{-h | --host
remote
host}]
[-H
'
string
']
[-i
IMS]
[-j
'
Host
header
']
[{-l | --local
host}]
[-m
method]
[{-p | --port
port}]
[-P
file]
[-t
count]
[-T
timeout]
[-u
user]
[-U
user]
[-V
version]
[-w
password]
[-W
password]
url
Ping options:
[-g
count]
[-I
interval]
TLS options:
[--anonymous-tls]
[--trusted-ca
CA
certificates
file ...]
[--cert
client
X.509
certificate
file]
[--params
TLS
session
parameters]
Overview
squidclient is a tool providing a command line interface for retrieving URLs. Designed for testing any HTTP 0.9, 1.0, or 1.1 web server or proxy. This tool can be combined with scripts to perform any basic HTTP operation. Some additional features for access to the squid proxy object cache and management information are provided.
Options
-
-a -
Do NOT include Accept: header.
-
-A 'string' -
Send
stringas User-Agent: header. To omit the header completely set string to empty ('').
-
-h | --host host -
Retrieve URL from server host. Default is
localhost
-
-H 'string' -
Extra headers to send. Use
'\n'for new lines.
-
-i time -
If-Modified-Since time (in Epoch seconds).
-
-j hosthdr -
Host header content
-
-k -
Keep the connection active. Default is to do only one request then close.
-
-l | --local host -
Specify a local IP address to bind to. Default is none.
-
-m method -
Request method, default is GET. Squid also supports a non-standard method called PURGE. You can use that to purge a specific URL from the cache. You need to have purge access setup in
squid.confsimilar to manager access. Here is an example:acl purge method PURGE http_access deny purge !localhost
-
-n -
Proxy Negotiate(Kerberos) authentication.
Use kinit username@DOMAIN first to get initial TGS.
-
-N -
WWW Negotiate(Kerberos) authentication.
Use kinit username@DOMAIN first to get initial TGS.
-
-p port -
Port number of cache. Default is 3128.
-
-P file -
Request body. Using the named file as data.
-
-r -
Force cache to reload URL.
-
-s -
Silent. Do not print data to stdout.
-
-t count -
Trace count HTTP relay or proxy hops
-
-T timeout -
Timeout value (seconds) for read/write operations.
-
-u user -
Proxy authentication username
-
-U user -
WWW authentication username
-
-v -
Verbose. Print outgoing message to stderr.
-
-V version -
HTTP Version. Use '-' for HTTP/0.9 omitted case
-
-w password -
Proxy authentication password
-
-W password -
WWW authentication password
-
--https -
Use Transport Layer Security on the HTTP connection.
-
--anonymous-tls -
Use TLS with unauthenticated (anonymous) certificate.
-
--cert file -
File containing client X.509 certificate in PEM format. May be repeated to load several client certificates.
-
--trusted-ca file -
File containing trusted Certificate Authority (CA) certificates in PEM format. May be repeated to load any number of files.
-
--params values -
TLS library specific parameters for the communication session. See the library documentation for details on valid parameters. GnuTLS: http://gnutls.org/manual/html_node/Priority-Strings.html If repeated only the last value will have effect.
-
--ping [options] -
Enable ping mode. Optional -g and -I parameters must follow immediately if used. Repeated use resets to default ping settings.
-
-g count -
Ping mode, perform count iterations (default is to loop until interrupted).
-
-I interval -
Ping interval in seconds (default 1 second).
Questions
Questions on the usage of this program can be sent to the Squid Users mailing list <[email protected]>
Releases
15 releases since Debian 2.0 (Hamm); the text changed 9 times.
--anonymous-tls since Debian 9 (Stretch);
--cert since Debian 9 (Stretch);
--host since Debian 9 (Stretch);
--https since Debian 9 (Stretch);
--local since Debian 9 (Stretch);
--params since Debian 9 (Stretch);
--ping since Debian 9 (Stretch);
--trusted-ca since Debian 9 (Stretch);
-A since Debian 7 (Wheezy);
-H since Debian 6.0 (Squeeze);
-I since Debian 6.0 (Squeeze);
-N since Debian 8 (Jessie);
-P since Debian 6.0 (Squeeze);
-T since Debian 6.0 (Squeeze);
-U since Debian 6.0 (Squeeze);
-V since Debian 6.0 (Squeeze);
-W since Debian 6.0 (Squeeze);
-a since Debian 6.0 (Squeeze);
-g since Debian 6.0 (Squeeze);
-j since Debian 6.0 (Squeeze);
-k since Debian 8 (Jessie);
-l since Debian 6.0 (Squeeze);
-n since Debian 8 (Jessie);
-t since Debian 6.0 (Squeeze);
-u since Debian 6.0 (Squeeze);
-v since Debian 6.0 (Squeeze);
-w since Debian 6.0 (Squeeze).