diff options
author | Aldo Cortesi <aldo@nullcube.com> | 2012-02-27 15:05:45 +1300 |
---|---|---|
committer | Aldo Cortesi <aldo@nullcube.com> | 2012-02-27 15:05:45 +1300 |
commit | 00942c1431c551e0bded111271be9b69f5261d91 (patch) | |
tree | c03a1bd9c18ae941446bbdb24dcfa01b3890287a /libmproxy/cmdline.py | |
parent | 4a2964985c3ca9e044134857175bde895372a898 (diff) | |
download | mitmproxy-00942c1431c551e0bded111271be9b69f5261d91.tar.gz mitmproxy-00942c1431c551e0bded111271be9b69f5261d91.tar.bz2 mitmproxy-00942c1431c551e0bded111271be9b69f5261d91.zip |
Add upstream certificate lookup.
This initiates a connection to the server to obtain certificate information to
generate interception certificates. At the moment, the information used is the
Common Name, and the list of Subject Alternative Names.
Diffstat (limited to 'libmproxy/cmdline.py')
-rw-r--r-- | libmproxy/cmdline.py | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/libmproxy/cmdline.py b/libmproxy/cmdline.py index ee4f3b08..42c02449 100644 --- a/libmproxy/cmdline.py +++ b/libmproxy/cmdline.py @@ -141,6 +141,17 @@ def common_options(parser): help="Byte size limit of HTTP request and response bodies."\ " Understands k/m/g suffixes, i.e. 3m for 3 megabytes." ) + parser.add_option( + "--cert-wait-time", type="float", + action="store", dest="cert_wait_time", default=0, + help="Wait for specified number of seconds after a new cert is generated. This can smooth over small discrepancies between the client and server times." + ) + parser.add_option( + "--upstream-cn-lookup", default=False, + action="store_true", dest="upstream_cn_lookup", + help="Connect to upstream server to look up certificate Common Name." + ) + group = optparse.OptionGroup(parser, "Client Replay") group.add_option( "-c", @@ -149,12 +160,6 @@ def common_options(parser): ) parser.add_option_group(group) - parser.add_option( - "--cert-wait-time", type="float", - action="store", dest="cert_wait_time", default=0, - help="Wait for specified number of seconds after a new cert is generated. This can smooth over small discrepancies between the client and server times." - ) - group = optparse.OptionGroup(parser, "Server Replay") group.add_option( "-S", |