add --http-only (might as well)

This commit is contained in:
ed 2021-02-11 22:54:40 +00:00
parent b6dba8beee
commit 75c73f7ba7
2 changed files with 3 additions and 0 deletions

View File

@ -206,6 +206,7 @@ def main():
ap.add_argument("--urlform", type=str, default="print,get", help="how to handle url-forms")
ap.add_argument("--ssl-ver", type=str, help="ssl/tls versions to allow")
ap.add_argument("--https-only", action="store_true", help="disable plaintext")
ap.add_argument("--http-only", action="store_true", help="disable ssl/tls")
al = ap.parse_args()
# fmt: on

View File

@ -107,6 +107,8 @@ class HttpConn(object):
self.sr = None
if self.args.https_only:
is_https = True
elif self.args.http_only:
is_https = False
else:
is_https = self._detect_https()