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

Skip Large Messages #199

Closed
256dpi opened this issue Apr 29, 2020 · 5 comments
Closed

Skip Large Messages #199

256dpi opened this issue Apr 29, 2020 · 5 comments

Comments

@256dpi
Copy link
Owner

256dpi commented Apr 29, 2020

If a client receives a message that is bigger than its receive buffer if will crash and return the error "LWMQTT_BUFFER_TOO_SHORT". For this library the better approach would be to just skip and log large messages.

@maglevize
Copy link

can we add the size for this buffer?

@Sisco21
Copy link

Sisco21 commented Feb 11, 2021

Hello, i had the same issue. Did you modified the behavior? Can we catch the error?

@mrdc
Copy link

mrdc commented Sep 20, 2021

@256dpi

Hello,
Nice feature to have - on large payloads device loses the connection to MQTT broker, so we have to protect it from this kind of possible attack.

@256dpi
Copy link
Owner Author

256dpi commented Feb 4, 2023

We should expose lwmqtt_drop_overflow to skip too large messages.

@256dpi
Copy link
Owner Author

256dpi commented Feb 5, 2023

Added in eae214b.

@256dpi 256dpi closed this as completed Feb 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants