Skip to content

Commit

Permalink
Review fix, part 1
Browse files Browse the repository at this point in the history
  • Loading branch information
kazet committed Nov 2, 2023
1 parent f01513f commit e74d877
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions karton_sqlmap/karton_sqlmap.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,11 +157,11 @@ def _expand_query_parameters_for_scanning(url: str) -> List[str]:
new_query[key] = item

# We replace token with * after building the URL, so that the asterisk is passwd to sqlmap unescaped
results.append(
urllib.parse.urlunparse(url_parsed._replace(query=urllib.parse.urlencode(new_query))).replace(
token, "*"
)
)
new_query_encoded = urllib.parse.urlencode(new_query)
new_url_parsed = url_parsed._replace(query=new_query_encoded)
new_url = urllib.parse.urlunparse(new_url_parsed)
new_url_with_injection_point = new_url.replace(token, "*")
results.append(new_url_with_injection_point)
return results

@staticmethod
Expand Down

0 comments on commit e74d877

Please sign in to comment.