-
Notifications
You must be signed in to change notification settings - Fork 1
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
Support icmp traffic #54
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For this to work in real-time mode, the eBPF need adapting. I also changed the base of this PR for better reviewing 😄
let icmp_type = icmp_packet.get_icmp_type(); | ||
let icmp_code = icmp_packet.get_icmp_code(); | ||
// let icmp_type = icmp_packet.get_icmp_type(); | ||
// let icmp_code = icmp_packet.get_icmp_code(); | ||
source_port = 0; // ICMPv6 does not have ports | ||
destination_port = 0; | ||
data_length = icmp_packet.payload().len() as u16; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we remove the hard coded header_length of 8 for udp and icmp in the Rustiflow code and extract the header length from both the realtime and pcap?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the realtime, this is possible but it is pointer work to get the header length.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me! For the hard coded header lengths, maybe another pull request that looks into ways to get the header length straight from the packet?
let icmp_type = icmp_packet.get_icmp_type(); | ||
let icmp_code = icmp_packet.get_icmp_code(); | ||
// let icmp_type = icmp_packet.get_icmp_type(); | ||
// let icmp_code = icmp_packet.get_icmp_code(); | ||
source_port = 0; // ICMPv6 does not have ports | ||
destination_port = 0; | ||
data_length = icmp_packet.payload().len() as u16; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the realtime, this is possible but it is pointer work to get the header length.
Add support for icmp traffic. Might be interesting to finish icmp flows on reply after requst.