-
Notifications
You must be signed in to change notification settings - Fork 81
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
Sending garbage data will raise weird exception #100
Comments
The beats parser get confused by the frame it received and just crash, So the way to fix this is to make sure we have received a valid header at the beginning of the batch to continue with the parser if its not the case we can just raise and |
ph
added a commit
to ph/logstash-input-beats
that referenced
this issue
Jul 20, 2016
This change make sure the state machien correctly recover from sending garbage data over the write. The current strategy is to check to make sure the frametype are correctly send if we received an unknown frame type we will assume that the frame is poisonous, we will raise a custom exception `InvalidFrameProtocol` with the associated bytes and will terminate the connection since we cannot do anything with it. Fixes: logstash-plugins#100
ph
added a commit
to ph/logstash-input-beats
that referenced
this issue
Jul 25, 2016
This change make sure the state machien correctly recover from sending garbage data over the write. The current strategy is to check to make sure the frametype are correctly send if we received an unknown frame type we will assume that the frame is poisonous, we will raise a custom exception `InvalidFrameProtocol` with the associated bytes and will terminate the connection since we cannot do anything with it. Fixes: logstash-plugins#100
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If you throw garbage at a plain text beats input, you get all kinds of fun exceptions:
To reproduce:
% bin/logstash --log.level debug -e 'input { beats { port => 12345 } }'
...
% dd if=/dev/urandom bs=4k count=1 | nc localhost 12345
full output
The text was updated successfully, but these errors were encountered: