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

Misc Fixes #870

Merged
merged 7 commits into from Mar 4, 2014
Merged

Misc Fixes #870

merged 7 commits into from Mar 4, 2014

Conversation

The file has no active rules by default.
Treat all OpenBSD versions in the same way. No more -fgnu89-inline.
Coverity 992695, fix potential array index with negative int. Very unlikely
case at rule keyword parsing stage.
Eve-log would call GET_VLAN_ID on the packets vlan header if p->vlan_idx
was bigger than 0. GET_VLAN_ID would then unconditionally dereference
p->vlanh[0] or [1]. However, there are a number of cases in which these
pointers are not set. Defrag pseudo packets, AF_PACKET and in the future
PF_RING, do set the id's, but not the header pointers.

This patch adds 2 new macro's which are wrappers around a function:

VLAN_GET_ID1 and VLAN_GET_ID2 get the id's by calling DecodeVLANGetId.

This function will return the correct id.

Bug #1120.
VLAN functions/macros return vlan id in host byte order, so no need
to convert them in output functions.
This would lead to reading past the end of the buffer and also writing
past the end of the newly allocated buffer.

Bug #1121
@inliniac inliniac merged commit 00d2f2d into master Mar 4, 2014
@inliniac inliniac deleted the dev-file-log-abort branch March 11, 2014 14:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants