Skip to content

Commit 1d451a6

Browse files
committed
Add readme note
1 parent e7a2410 commit 1d451a6

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

readme.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,9 @@ semverRegex().exec('unicorn 1.0.0 rainbow')[0];
2828

2929
## Important
3030

31-
If you run the regex against untrusted user input, it's recommended to truncate the string to a sensible length (for example, 100). And if you use this in a server context, you should also [give it a timeout](https://github.com/sindresorhus/super-regex).
31+
If you run the regex against untrusted user input, it's recommended to truncate the string to a sensible length (for example, 50). And if you use this in a server context, you should also [give it a timeout](https://github.com/sindresorhus/super-regex).
32+
33+
**I do not consider ReDoS a valid vulnerability for this package. It's simply not possible to make it fully ReDoS safe. It's up to the user to set a timeout for the regex if they accept untrusted user input.** However, I'm happy to accept pull requests to improve the regex.
3234

3335
## Related
3436

0 commit comments

Comments
 (0)