You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(ipv6-opts): _make_opt_smf_dpd overwrites the parsed DPD mode, so H-DPD rebuilds as I-DPD #1190
Describe the bug _make_opt_smf_dpd drops the parsed DPD mode. It sets dpd_type = opt.dpd_type (pcapkit/protocols/internet/hopopt.py:1606) and then overwrites it at :1611 from the mode keyword, whose default is I-DPD. A parsed H-DPD option therefore rebuilds as I-DPD. ipv6_opts.py has the same code.
To Reproduce
On origin/main, build an H-DPD SMF_DPD option (mode=H_DPD, hav=01020304), parse it, and rebuild it with from_data. The original bytes are 3b00080481020304. The rebuild is 3b00080100010100: I-DPD with a null tagger ID. HOPOPT and IPv6_Opts behave the same.
Expected behavior
A parsed SMF_DPD option keeps its mode and rebuilds byte-exactly.
Found by the #1187 worker. The #1187 cross-review reproduced it. I read both lines on main.
Activity
JarryShaw commentedon Oct 7, 2026
Blocked until #1187 merges, because both edit
hopopt.pyandipv6_opts.py.JarryShaw commentedon Oct 7, 2026
Unblocked: #1187 merged. A worker is on it now.