Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e3a02f5

Browse files
committed
Just in case for --force-ssl (if url is returned in e.g. refresh toward the target)
1 parent 42a73d8 commit e3a02f5

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

lib/request/connect.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,10 @@ def getPage(**kwargs):
276276
pass
277277

278278
elif target:
279+
if conf.forceSSL and urlparse.urlparse(url).scheme != "https":
280+
url = re.sub("\Ahttp:", "https:", url, re.I)
281+
url = re.sub(":80/", ":443/", url, re.I)
282+
279283
if PLACE.GET in conf.parameters and not get:
280284
get = conf.parameters[PLACE.GET]
281285

0 commit comments

Comments
 (0)