-
Notifications
You must be signed in to change notification settings - Fork 39
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
net primitive does to accept dotted quads #159
Comments
Thanks for reporting this, @eugeneia ; it definitely needs to be fixed. As a workaround in the meanwhile, "src net 109.145.29.1/32" appears to work. |
@kbara Yeah I know :) A tip: Write a generator for the packet-filter grammar and fuzz PFLua with it. That will weed out these kinds of bugs quickly (checking that the compiled behavior is actually correct is another issue though). |
@eugeneia Yeah, I've written a partial generator, and mean to expand it - and to run it through AFL, cross-checking with whether libpcap accepts various expressions, to make sure I miss less corner cases. I'm still learning about all sorts of interesting edge cases ( #157 and #82 cover a subset). This one, admittedly, is not in that category; it should Just Work, and I apologize that it doesn't. |
PFlua's
net
primitive does not support dotted quads as described in in the pcap-filter manpage:To reproduce:
Result:
Expected result: A compiled filter that matches only packets from
109.145.29.1
.The text was updated successfully, but these errors were encountered: