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

Filter on IP version (IPv4 / IPv6) #459

Closed
2 tasks done
kaworu opened this issue Dec 14, 2020 · 4 comments · Fixed by cilium/cilium#14556 or #505
Closed
2 tasks done

Filter on IP version (IPv4 / IPv6) #459

kaworu opened this issue Dec 14, 2020 · 4 comments · Fixed by cilium/cilium#14556 or #505
Assignees
Labels
area/cilium Requires upstream work in Cilium ⌨️ area/cli Impacts the command line interface of any command in the repository. 👍 good-first-issue Good starting point for new developers, which requires minimal understanding of Hubble. 🙏 help-wanted Please volunteer for this by adding yourself as an assignee! kind/enhancement This would improve or streamline existing functionality.

Comments

@kaworu
Copy link
Member

kaworu commented Dec 14, 2020

Currently it is not possible to filter only IPv4 or IPv6 flows with the CLI.

Note that FlowFilter lack support for this, so a first step will be to add this filter to the Hubble observer at https://github.com/cilium/cilium. There are many example of filters, see https://github.com/cilium/cilium/blob/master/pkg/hubble/filters.

Then, the flow protobuf must be adapted with a new IPVersion field in FlowFilter so that queries can use the new filter.

Finally, a CLI change adding -4|--ipv4 and -6|--ipv6 could make use of this new filter. The option names could be different, although the one proposed in this issue are already widely adopted (see nc(1), curl(1) etc.)


Parts:

@kaworu kaworu added kind/enhancement This would improve or streamline existing functionality. 👍 good-first-issue Good starting point for new developers, which requires minimal understanding of Hubble. 🙏 help-wanted Please volunteer for this by adding yourself as an assignee! ⌨️ area/cli Impacts the command line interface of any command in the repository. area/cilium Requires upstream work in Cilium labels Dec 14, 2020
@nyrahul
Copy link
Contributor

nyrahul commented Dec 18, 2020

Is there an issue in cilium to handle this? If yes, I can take it up. I recently added tcp-flags filter which required updating FlowFilter and thus have an understanding of what needs to be done.

@gandro
Copy link
Member

gandro commented Dec 21, 2020

Is there an issue in cilium to handle this? If yes, I can take it up. I recently added tcp-flags filter which required updating FlowFilter and thus have an understanding of what needs to be done.

That would be awesome! 🚀

I don't believe there is a tracking issue on the server side, but it's probably also not needed. Feel free to just create a PR against Cilium with the required filter and API additions referencing this issue!

I have preliminarily assigned you to the issue to avoid other people accidentally taking this one. Do not hesitate un-assign yourself if anything comes up.

@kaworu
Copy link
Member Author

kaworu commented Dec 21, 2020

@nyrahul thanks for picking this up! Although I expect this to be easier than the TCP flags, don't hesitate to ping us on Slack if you have any question.

@nyrahul
Copy link
Contributor

nyrahul commented Jan 18, 2021

@kaworu, @gandro, the issue got closed due to PR merge of cilium-side (server-side) changes. The hubble side changes are still pending. Should this be reopened?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/cilium Requires upstream work in Cilium ⌨️ area/cli Impacts the command line interface of any command in the repository. 👍 good-first-issue Good starting point for new developers, which requires minimal understanding of Hubble. 🙏 help-wanted Please volunteer for this by adding yourself as an assignee! kind/enhancement This would improve or streamline existing functionality.
Projects
None yet
3 participants