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

5.0.x: ftp: truncate first segment if over max length #7363

Closed

Conversation

jasonish
Copy link
Member

@jasonish jasonish commented May 2, 2022

The first segment was not limited to the configured maximum line length
allowing it to be up to 65k. This could result in the next input length
being negative, which while handled properly by the code, did trigger a
debug validation assertion.

The fix is to be consistent and apply the limit to the first segment as
well, which does ensure the input_len could never be less than 0.

Issue: https://redmine.openinfosecfoundation.org/issues/5281

(cherry picked from commit 9645285)

suricata-very-pr: 819

The first segment was not limited to the configured maximum line length
allowing it to be up to 65k. This could result in the next input length
being negative, which while handled properly by the code, did trigger a
debug validation assertion.

The fix is to be consistent and apply the limit to the first segment as
well, which does ensure the input_len could never be less than 0.

Ticket OISF#5281

(cherry picked from commit 9645285)
@victorjulien
Copy link
Member

Merged in #7377, thanks!

@jasonish jasonish deleted the 5.0.x-ticket-5281-ftp/v1 branch May 5, 2022 18:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants