Skip to content

[dhcp_relay] Cover chained requests without Option 82 - #26324

Draft
Xichen96 wants to merge 1 commit into
sonic-net:masterfrom
Xichen96:dev/xichenlin/item10-chained-no-option82-test
Draft

[dhcp_relay] Cover chained requests without Option 82#26324
Xichen96 wants to merge 1 commit into
sonic-net:masterfrom
Xichen96:dev/xichenlin/item10-chained-no-option82-test

Conversation

@Xichen96

@Xichen96 Xichen96 commented Jul 19, 2026

Copy link
Copy Markdown
Contributor

Description of PR

Summary:
Add focused native-relay coverage for a chained request with a genuinely nonlocal TEST-NET giaddr and no Option 82 while agent mode is discard. The expected upstream packet preserves giaddr, increments hops, and still contains no Option 82.

This is a low-priority draft placeholder for a non-current deployment scenario. It depends on sonic-net/sonic-dhcp-relay#125 and may intentionally fail on current images until that product dependency merges. DRAFT — MUST NOT MERGE.

Fixes # N/A — draft test placeholder; no issue is linked.

Type of change

  • Bug fix
  • Testbed and Framework(new/improvement)
  • New Test case
    • Skipped for non-supported platforms
  • Test case improvement

Back port request

  • 202311
  • 202405
  • 202411
  • 202505
  • 202511
  • 202512
  • 202605

Tracking issue/work item for backport/cherry-pick request (GitHub issue or Microsoft ADO): N/A; no backport requested.
Failure type: other — low-priority test coverage gap for a non-current deployment scenario.

Tested branch

  • master
  • 202311
  • 202405
  • 202411
  • 202505
  • 202511
  • 202512
  • 202605
  • N/A

Test result

  • NOT RUN: no pytest, PTF, syntax-check, or hardware validation was executed.

  • Validation is intentionally deferred until the higher-priority DHCP relay PRs merge.

  • This draft must not merge before its dependency and validation TODOs are complete.

  • Dependency TODO: rebase/validate after [dhcp4relay] Forward chained requests without relay information sonic-dhcp-relay#125 merges.

  • Validation TODO: run the focused native hardware/PTF case after the higher-priority DHCP relay PRs merge.

Approach

What is the motivation for this PR?

Agent relay mode applies to packets carrying relay information, but native relay currently applies discard behavior to nonzero-giaddr requests even when Option 82 is absent.

How did you do it?

Allow the PTF input to omit Option 82 independently of agent mode, use TEST-NET-1 address 192.0.2.1 for the synthetic downstream relay, and explicitly require forwarding with the same giaddr and no inserted Option 82.

How did you verify/test it?

No validation was executed. Validation is deferred until the higher-priority DHCP relay PRs merge. This draft must not merge before the dependency and validation TODOs above are complete.

Any platform specific information?

Scoped to native sonic-relay-agent; ISC fixture behavior is intentionally not used for this native-only policy assertion.

Supported testbed topology if it's a new test case?

Existing t0 and m0 DHCP relay topologies; unsupported relay agents remain excluded.

Documentation

No documentation update. This draft only adds or corrects DHCP relay test coverage.

Add native relay coverage for a nonlocal chained request without Option 82 and require forwarding without adding relay information.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 2b881aa9-3a3a-4aaf-b2ca-b941705b2438
Signed-off-by: Xichen96 <lukelin0907@gmail.com>
@mssonicbld

Copy link
Copy Markdown
Collaborator

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).

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.

2 participants