Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
kazet committed Jul 18, 2024
1 parent 0b0d821 commit 28c7121
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions artemis/modules/nuclei.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,7 @@ def _scan(self, templates: List[str], targets: List[str]) -> List[Dict[str, Any]

milliseconds_per_request_candidates = [
milliseconds_per_request_initial,
max(500, milliseconds_per_request_initial * 2),
max(2000, milliseconds_per_request_initial * 4),
max(200, milliseconds_per_request_initial * 2),
]

if Config.Miscellaneous.CUSTOM_USER_AGENT:
Expand Down Expand Up @@ -190,7 +189,10 @@ def _scan(self, templates: List[str], targets: List[str]) -> List[Dict[str, Any]
lines.append(line)

if "context deadline exceeded" in call_result_utf8:
self.log.info("Detected 'context deadline exceeded', retrying with longer timeout")
self.log.info(
"Detected %d occurencies of 'context deadline exceeded', retrying with longer timeout",
call_result_utf8.count("context deadline exceeded"),
)
new_milliseconds_per_request_candidates = [
item for item in milliseconds_per_request_candidates if item > milliseconds_per_request
]
Expand Down

0 comments on commit 28c7121

Please sign in to comment.