Skip to content

Commit

Permalink
Fixes #914
Browse files Browse the repository at this point in the history
  • Loading branch information
stasinopoulos committed May 13, 2024
1 parent d81bcfe commit 82d4aba
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
13 changes: 7 additions & 6 deletions src/core/injections/controller/checks.py
Original file line number Diff line number Diff line change
Expand Up @@ -321,12 +321,13 @@ def connection_exceptions(err_msg):
"""
def not_declared_cookies(response):
try:
set_cookie_headers = []
for set_cookie_header in response.getheaders():
if settings.SET_COOKIE in set_cookie_header:
set_cookie_headers.append(re.search(r'([^;]+);?', set_cookie_header[1]).group(1))

candidate = settings.COOKIE_DELIMITER.join(str(value) for value in set_cookie_headers)
set_cookie_header = []
for response_header in response.getheaders():
if settings.SET_COOKIE in response_header:
_ = re.search(r'([^;]+);?', response_header[1])
if _:
set_cookie_header.append(_.group(1))
candidate = settings.COOKIE_DELIMITER.join(str(value) for value in set_cookie_header)
if candidate and settings.DECLARED_COOKIES is not False and settings.CRAWLING is False:
settings.DECLARED_COOKIES = True
if menu.options.cookie:
Expand Down
2 changes: 1 addition & 1 deletion src/utils/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ def sys_argv_errors():
DESCRIPTION = "The command injection exploiter"
AUTHOR = "Anastasios Stasinopoulos"
VERSION_NUM = "4.0"
REVISION = "45"
REVISION = "46"
STABLE_RELEASE = False
VERSION = "v"
if STABLE_RELEASE:
Expand Down

0 comments on commit 82d4aba

Please sign in to comment.