Skip to content

Commit

Permalink
Redirection fixed
Browse files Browse the repository at this point in the history
Now -L option for redirects shows the second HTTP code response
  • Loading branch information
lobuhi authored Nov 9, 2021
1 parent 9ebb624 commit 99d68df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion byp4xx.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def banner():
#Defining the standard curl calling. Default options used: -k -s -I (HEAD method)
#Code is returned already colored
def curl_code_response(options_var, payload_var):
code = popen("curl -k -s -I %s %s" % (options_var, payload_var)).read()
code = popen("curl -k -s -I %s %s | grep HTTP | tail -1" % (options_var, payload_var)).read()

#If we use -x proxy curl option then we must take the third line of the response
if "-x" in options_var:
Expand Down

0 comments on commit 99d68df

Please sign in to comment.