Skip to content

Add form_data_skipped_length_ limit check#3653

Open
giorka wants to merge 1 commit into
tdlib:masterfrom
giorka:patch-2
Open

Add form_data_skipped_length_ limit check#3653
giorka wants to merge 1 commit into
tdlib:masterfrom
giorka:patch-2

Conversation

@giorka

@giorka giorka commented May 19, 2026

Copy link
Copy Markdown

There is already a TODO in FormDataParseState::SkipEpilogue to check that form_data_skipped_length_ doesn't become too large.
Add a missing MAX_CONTENT_SIZE check and return HTTP 413 when the limit is exceeded.

@levlam

levlam commented Jun 13, 2026

Copy link
Copy Markdown
Contributor

It is a bit late to check form_data_skipped_length_ after all data was read and processed .Also, the check covers just the case of multipart/form-data. Additionally, the check will never fail because of content size checks in other places.

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

Successfully merging this pull request may close these issues.

2 participants