Skip to content
This repository has been archived by the owner on Apr 26, 2021. It is now read-only.

Fix Regular Expression injection #3188

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Fix Regular Expression injection #3188

wants to merge 2 commits into from

Conversation

jorgectf
Copy link

@jorgectf jorgectf commented Mar 23, 2021

The fact of not sanitizing user input appended to a regular expression may lead to a Regular Expression Denial of Service by an attacker crafting a regular expression taking too much to load, or simply change the behaviour of the program.

Vulnerable code:

query = re.compile(query, re.I)

References:

OWASP ReDoS

@jorgectf
Copy link
Author

jorgectf commented Apr 2, 2021

@botherder @jbremer @jekil @rep Sorry for the ping! Could you merge this? Thanks :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant