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

[bug?]: Webadmin POST text/plain to the server when login. #18

Closed
OrvilleQ opened this issue Aug 28, 2024 · 0 comments
Closed

[bug?]: Webadmin POST text/plain to the server when login. #18

OrvilleQ opened this issue Aug 28, 2024 · 0 comments

Comments

@OrvilleQ
Copy link

OrvilleQ commented Aug 28, 2024

Relate to stalwartlabs/mail-server#722

Seems like when press the Sign in button of the webadmin login page, it will POST /api/oauth and /api/token with content type text/plain;charset=UTF-8

image

image

This behavior is not allowed by Modsecurity rule 920420, which restricts the content types allowed to be sent to the server as POST and ultimately results in a 403 Forbidden being returned, which appears to be how Webadmin detects the missing TOTP code and ultimately results in the TOTP code page being displayed. stalwartlabs/mail-server#722 (comment)

Given that Modsecurity is used in many WAF programs, perhaps this behavior should be considered a bug and fixed? I'm also not sure how many POST requests are actually sent as text/plain, What do you think?

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

1 participant