diff options
| author | Aldo Cortesi <aldo@nullcube.com> | 2012-09-26 10:12:30 +1200 |
|---|---|---|
| committer | Aldo Cortesi <aldo@nullcube.com> | 2012-09-26 10:12:30 +1200 |
| commit | 0a5d4fbbbb06a4e6c5e6172b353aa878aaa6e0c6 (patch) | |
| tree | 2e0d2614d6f77446c674a346f5d0d103a6e03528 /pathoc | |
| parent | 0dd250d4f886cfa7cf91e3690b4196acfe3740ce (diff) | |
| download | mitmproxy-0a5d4fbbbb06a4e6c5e6172b353aa878aaa6e0c6.tar.gz mitmproxy-0a5d4fbbbb06a4e6c5e6172b353aa878aaa6e0c6.tar.bz2 mitmproxy-0a5d4fbbbb06a4e6c5e6172b353aa878aaa6e0c6.zip | |
Stub out new output argument structure.
Diffstat (limited to 'pathoc')
| -rwxr-xr-x | pathoc | 33 |
1 files changed, 24 insertions, 9 deletions
@@ -18,10 +18,6 @@ if __name__ == "__main__": help="Port. Defaults to 80, or 443 if SSL is active." ) parser.add_argument( - "-d", dest="reqdump", action="store_true", default=False, - help="Print request record before each response." - ) - parser.add_argument( "-s", dest="ssl", action="store_true", default=False, help="Connect with SSL." ) @@ -30,10 +26,6 @@ if __name__ == "__main__": help="Connection timeout." ) parser.add_argument( - "-v", dest="verbose", action='count', - help="Increase verbosity." - ) - parser.add_argument( 'host', type=str, help='Host to connect to' ) @@ -41,6 +33,23 @@ if __name__ == "__main__": 'request', type=str, nargs="+", help='Request specification' ) + group = parser.add_argument_group('Controlling Output') + group.add_argument( + "-e", dest="explain", action="store_true", default=False, + help="Explain requests." + ) + group.add_argument( + "-q", dest="showreq", action="store_true", default=False, + help="Print full request." + ) + group.add_argument( + "-r", dest="showresp", action="store_true", default=False, + help="Print full response." + ) + group.add_argument( + "-x", dest="hexdump", action="store_true", default=False, + help="Output in hexdump format." + ) args = parser.parse_args() @@ -65,7 +74,13 @@ if __name__ == "__main__": continue if args.timeout: p.settimeout(args.timeout) - p.print_requests(args.request, args.verbose, args.reqdump) + p.print_requests( + args.request, + showreq=args.showreq, + showresp=args.showresp, + explain=args.explain, + hexdump=args.hexdump, + ) sys.stdout.flush() except KeyboardInterrupt: pass |
