Scroll to navigation

pathod(1) pathod(1)

NAME

pathod - a pathological HTTP/S daemon

SYNOPSIS

pathod [-h] [--version] [-p PORT] [-l ADDRESS] [-a ANCHOR]

       [-c CRAFTANCHOR] [--confdir CONFDIR] [-d STATICDIR] [-D]

       [-t TIMEOUT] [--limit-size SIZELIMIT] [--nohang] [--nocraft]

       [--webdebug] [-s] [--cn CN] [-C] [--cert SPEC]

       [--ciphers CIPHERS] [--san SAN]

       [--ssl-version {all|TLSv1_2|secure|TLSv1_1|TLSv1|SSLv3|SSLv2}]

       [-e] [-f LOGFILE] [-q] [-r] [-x] [--http2-framedump]

DESCRIPTION

pathod is a pathological HTTP daemon designed to let you craft almost any conceivable HTTP response, including ones that creatively violate the standards. HTTP responses are specified using a small, terse language which pathod shares with its evil twin, pathoc. To start playing with pathod, fire up the daemon:

$ pathod

By default, the service listens on port 9999 of localhost, and the default crafting anchor point is the path /p/. Anything after this URL prefix is treated as a response specifier. So, hitting the following URL will generate an HTTP 200 response with 100 bytes of random data:

http://localhost:9999/p/200:b@100

See the language documentation (http://docs.mitmproxy.org/en/latest/pathod/language.html#language) to get (much) fancier.

OPTIONS

Optional Arguments:

Show this help message and exit.
Show program's version number and exit.
Port. Specify 0 to pick an arbitrary empty port. (Default: 9999)
Listening address. (Default: 127.0.0.1)
Add an anchor. Specified as a string with the form pattern=spec or pattern=filepath, where pattern is a regular expression.
URL path specifying prefix for URL crafting commands. (Default: /p/)
Configuration directory. (Default: ~/.mitmproxy)
Directory for static files.
Daemonize.
Connection timeout.
Size limit of served responses. Understands size suffixes, e.g. 100k.
Disable pauses during crafted response generation.
Disable response crafting. If anchors are specified, they still work.
Debugging mode for the web app (dev only).

SSL:

Run in HTTPS mode.
CN for generated SSL certs. (Default: pathod.net)
Don't expect SSL after a CONNECT request.
Add an SSL certificate. SPEC is of the form "[domain=]path". The domain may include a wildcard, and is equal to "*" if not specified. The file at path is a certificate in PEM format. If a private key is included in the PEM, it is used, otherwise the default key in the conf dir is used. Can be passed multiple times.
SSL cipher specification.
Subject Altnernate Name to add to the server certificate. May be passed multiple times.
Set supported SSL/TLS versions. SSLv2, SSLv3 and all are INSECURE. Defaults to secure, which is TLS1.0+.

Controlling Logging:

Some of these options expand generated values for logging. If you're generating large data, use them with caution.

Explain responses.
Log to file.
Log full request.
Log full response.
Log request/response in hexdump format.
Output all received & sent HTTP/2 frames.

AUTHORS

pathod was written by Aldo Cortesi.

This manual page was written for the Debian GNU/Linux system, but its use elsewhere is encouraged.

SEE ALSO

pathod documentation and examples are available online at <http://docs.mitmproxy.org/en/latest/pathod/intro.html#pathod>.

November 2016