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

FP when sharing special named folders in Android app #76

Closed
mhastu opened this issue Jun 15, 2024 · 2 comments
Closed

FP when sharing special named folders in Android app #76

mhastu opened this issue Jun 15, 2024 · 2 comments

Comments

@mhastu
Copy link
Contributor

mhastu commented Jun 15, 2024

When creating a sharing link in a folder in the Android client named e.g. "tmp" a false positive is created.
ModSecurity: Warning. Matched phrase "/tmp/" at ARGS:path. [file "/etc/modsecurity/crs/rules/REQUEST-930-APPLICATION-ATTACK-LFI.conf"] [line "116"] [id "930120"] [msg "OS File Access Attempt"] [data "Matched Data: /tmp/ found within ARGS:path: /tmp/"] [severity "CRITICAL"] [ver "OWASP_CRS/4.3.0"] [tag "application-multi"] [tag "language-multi"] [tag "platform-multi"] [tag "attack-lfi"] [tag "paranoia-level/1"] [tag "OWASP_CRS"] [tag "capec/1000/255/153/126"] [tag "PCI/6.5.4"] [uri "/ocs/v2.php/apps/files_sharing/api/v1/shares"]

@mhastu mhastu changed the title FP when opening special named folders in Android app FP when sharing special named folders in Android app Jun 15, 2024
@mhastu
Copy link
Contributor Author

mhastu commented Jun 15, 2024

"fixed" it temporarily on my local machine by adding the following rule. pretty sure it is too relaxed but i don't have much time right now

SecRule REQUEST_FILENAME "@beginsWith /ocs/v2.php/apps/files_sharing/api/v1/shares" \
    "id:2,\
    phase:1,\
    pass,\
    t:none,\
    nolog,\
    ctl:ruleRemoveById=930120"

@mhastu
Copy link
Contributor Author

mhastu commented Jun 16, 2024

Confirming that #77 fixes this issue. Thanks for the fast fix!

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

No branches or pull requests

2 participants