Skip to content

[feature] RFC-compliant multicast MAC derivation #57

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

Merged
merged 3 commits into from
Jul 21, 2025

Conversation

zeeshanlakhani
Copy link
Contributor

@zeeshanlakhani zeeshanlakhani commented Jul 18, 2025

Implements multicast MAC address derivation from IP addresses following RFC standards:

  • IPv4: RFC 1112 Section 6.4 (01:00:5e prefix + 23 bits)
  • IPv6: RFC 2464 Section 7 (33:33 prefix + 32 bits)

Features:

  • Core trait returns [u8; 6] for dependency-light usage
  • Optional macaddr feature provides MacAddr6 integration (not a default feature)
  • Support for IpAddr, Ipv4Addr, Ipv6Addr, and IpNetwork types
  • Comprehensive tests with RFC compliance verification

We need this in both dendrite (testing) and omicron. It felt proper to place this here over omicron common (for example).

Implements multicast MAC address derivation from IP addresses following RFC standards:
  - IPv4: RFC 1112 Section 6.4 (01:00:5e prefix + 23 bits)
  - IPv6: RFC 2464 Section 7 (33:33 prefix + 32 bits)

  Features:
  - Core trait returns [u8; 6] for dependency-light usage
  - Optional macaddr feature provides MacAddr6 integration
  - Support for IpAddr, Ipv4Addr, Ipv6Addr, and IpNetwork types
  - Comprehensive tests with RFC compliance verification

We need this in both dendrite (testing) and omicron.
It felt proper to place this here over omicron common (for example).
Copy link
Contributor

@FelixMcFelix FelixMcFelix left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, the implementation looks good!

@zeeshanlakhani zeeshanlakhani merged commit fcd453f into main Jul 21, 2025
14 checks passed
@zeeshanlakhani zeeshanlakhani deleted the zl/multicast-mac branch July 21, 2025 02:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants