Skip to content

feat(net): support stable IPv6 address generation - #2715

Merged
fslongjin merged 1 commit into
DragonOS-Community:masterfrom
fslongjin:codex/feat-ipv6-stable-addrgen-2324-50
Nov 25, 2026
Merged

fslongjin merged 1 commit into
DragonOS-Community:masterfrom
fslongjin:codex/feat-ipv6-stable-addrgen-2324-50

Conversation

@fslongjin

Copy link
Copy Markdown
Member

Summary

  • Support stable privacy and random IPv6 interface identifiers through the existing sysctl and rtnetlink configuration paths.
  • Protect stable secrets with network-namespace permissions, inherit the default secret when creating IPv6 device state, and keep secrets out of link and address notifications.
  • Use Linux-compatible identifier derivation for link-local addresses and SLAAC. Reuse the existing SHA-1 compression routine without changing BPF program tags.
  • Retry stable DAD conflicts through the existing probe queue. Read probe policy when the delay expires and complete the old address's failure handling even if creating the next address fails.

This completes the stable and random address-generation stage for the Docker firewall acceptance work tracked by #2324.

Validation

  • Compared Linux secret inheritance, credential changes, identifier vectors, random-mode lifecycle, and DAD behavior for permanent and finite addresses.
  • Passed kernel build and formatting, shared SHA-1 and BPF tag vectors, and 221 QEMU networking cases.
  • Verified stable-secret permissions, stable link-local and SLAAC conflict recovery, retry exhaustion, random-mode recreation, and policy changes during the retry delay in QEMU.
  • Passed native nftables and iptables-nft Docker IPv6 matrices with the userland proxy disabled.

Implement stable privacy and random address generation for link-local and SLAAC addresses, using Linux-compatible inputs, the permanent hardware address where present, and a shared SHA-1 compression routine.

Expose protected per-device and default stable secrets and namespace identifier retry settings. Preserve device lifecycle and default inheritance, and validate modes consistently for sysctl and rtnetlink.

Retry stable DAD conflicts through the existing worker, apply probe settings when the delay expires, and process the original conflict even if creating another candidate fails. Add regression coverage for identifier derivation and current-credential checks on already open secret files.

Signed-off-by: longjin <longjin@dragonos.org>
@fslongjin

Copy link
Copy Markdown
Member Author

@codex review

@github-actions github-actions Bot added the enhancement New feature or request label Nov 25, 2026
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 25, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-25T09:24:05.204990Z 525bfa6 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. You're on a roll.

Reviewed commit: 525bfa6f74

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@fslongjin
fslongjin merged commit 712d26b into DragonOS-Community:master Nov 25, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant