Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] Add modsecurity config/compatibility for SecRequestBodyNoFilesLimit #1762

Open
1 task done
thelittlefireman opened this issue Nov 28, 2024 · 0 comments
Open
1 task done
Assignees
Labels
enhancement New feature or request

Comments

@thelittlefireman
Copy link
Contributor

thelittlefireman commented Nov 28, 2024

What's needed and why?

Hi, could it be possible to add a configuration for the SecRequestBodyNoFilesLimit in mod security ?

Current config

...
# maximum data size
SecRequestBodyLimit 52428800
SecRequestBodyNoFilesLimit 131072
...

Cause i've got some issue to get a specific app that upload more than 1 MB as raw body ("not a file")

Nov 28 23:45:39 172.16.1.1 85e7e5477190[26671]: 2024/11/28 23:45:39 [error] 17256#17256: *234903 [client  XX.XX.XX.XX] ModSecurity: Access denied with code 400 (phase 2). Matched "Operator `Eq' with parameter `0' against variable `REQBODY_ERROR' (Value: `1' ) [file "/etc/nginx/XXX.XXXX.XXX/server-http/modsecurity-rules.conf.modsec"] [line "23"] [id "200002"] [rev ""] [msg "Failed to parse request body."] [data "Request body excluding files is bigger than the maximum expected."] [severity "2"] [ver ""] [maturity "0"] [accuracy "0"] [hostname "XX.XX.XX.XX"] [uri "/picture"] [unique_id "173283393633.511094"] [ref "v0,1"], client: XX.XX.XX.XX, server: XXX.XXXX.XX, request: "POST /picture HTTP/1.1", host: "XXX.XXXX.XX"

Implementations ideas (optional)

Something similar to MAX_CLIENT_SIZE but like MAX_NO_FILES_CLIENT_SIZE

Code of Conduct

  • I agree to follow this project's Code of Conduct
@thelittlefireman thelittlefireman added the enhancement New feature or request label Nov 28, 2024
@TheophileDiot TheophileDiot self-assigned this Dec 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants