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

Crash when receiving large GMCP buffers #184

Open
lorienhu opened this issue May 5, 2023 · 1 comment
Open

Crash when receiving large GMCP buffers #184

lorienhu opened this issue May 5, 2023 · 1 comment

Comments

@lorienhu
Copy link

lorienhu commented May 5, 2023

Tintin is crashing due to memory protection/buffer overflow upon receiving GMCP data larger than BUFFER_SIZE, which seems to be defined in the Tintin source as 40000.

Neither the Telnet RFC or the GMCP specification defines any maximum size for a single GMCP message, so there should probably be some handling for this.

@scandum
Copy link
Owner

scandum commented May 9, 2023

One thing to be mindful of is to only call %1 once in the event, and it's an option to increase BUFFER_SIZE in tintin.h and recompile.

This is on my list of things to fix, but dynamic string handling in C is a bit of a challenge.

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