Repository navigation
Conversation
Signed-off-by: Drew Newberry <anewberry@nvidia.com>
|
🌿 Preview your docs: https://nvidia-preview-pr-5650.docs.buildwithfern.com/openshell |
|
Label |
johntmyers
left a comment
There was a problem hiding this comment.
gator-agent
PR Review Status
The code review found no blocking issues. Expired mappings refresh through the trusted resolver and destination-validation path, while process, port, endpoint, and policy-generation checks remain in place. The docs explain refresh behavior and failed-refresh denials.
Blocking findings: None.
Carried findings: None.
Gator metadata
- Validation: Focused network reliability fix implementing accepted issue #4674.
- Docs: Published network-policy and logging pages updated.
- Checks: Branch checks remain pending; Helm lint passed and deployment scanning was not applicable.
- E2E:
test:e2eapplied; current-head Branch E2E Checks attempt 2 running for the standard suite, including the cached-address expiry regression. - Head SHA:
e66f4e3ef69851e0ab0ae4e6860632574e020555 - Base SHA:
624aceea32934f73c350ede3f2185880816a030c - Merge base SHA:
2e5589b2180dd432320adda124c4f7bcede119b5 - Patch ID:
5893900c887c164a917e8afbb8d4fbcd9a9ef6b2 - Gator payload:
13 - Review mode:
initial - Previous reviewed SHA: none
- Review budget exhausted: no
- Maintainer decision required: no
- Next state:
gator:watch-pipeline
TaylorMutch
left a comment
There was a problem hiding this comment.
Reviewed e66f4e3 locally. I found two reproducible correctness issues, detailed inline.
Validation: 71 existing policy-DNS tests passed. Two additional focused regressions reproduced the findings below, including the dispatch case with real TTL expiry. The tests ran in a temporary copy of this exact commit.
| } | ||
|
|
||
| #[async_trait::async_trait] | ||
| pub(super) trait MappingRefresher: Send + Sync { |
There was a problem hiding this comment.
Could we keep refresh orchestration in PolicyDnsService and expose one async lookup_for_connect operation that returns the resulting mapping?
Having the store call back into its owner adds MappingRefresher, a weak reference, OnceLock, and a separate enable_refresh step. Callers then have to refresh and look up the mapping separately.
| process: { run_as_user: sandbox, run_as_group: sandbox } | ||
| "; | ||
|
|
||
| struct RefreshResolver { |
There was a problem hiding this comment.
Can we simplify this fixture? It combines mutable answers, failure injection, call counting, and pause/release controls. This module already has FakeResolver, NxDomainResolver, and BlockingResolver.
| } | ||
|
|
||
| #[tokio::test] | ||
| async fn expired_mapping_refresh_does_not_upgrade_ports_observations_or_policy_generations() { |
There was a problem hiding this comment.
Could we make this a compact refresh-rejection test and give it a name that matches its assertions? It currently checks that these three attempts return an error and make no additional upstream DNS query.
If we move to a service lookup_for_connect operation, assert rejection through that operation and keep the cases clearly labeled. That would cover the behavior callers depend on without tying the test to a separate refresh_if_expired helper.
Signed-off-by: Drew Newberry <anewberry@nvidia.com>
johntmyers
left a comment
There was a problem hiding this comment.
gator-agent
PR Review Status
The follow-up review found no new blocking issues. Thanks @TaylorMutch: I checked both reported correctness problems against the new code and regressions. Dispatch now reauthorizes and rebuilds connectors from current pins, and refresh eligibility retains authored ports when the latest DNS answer satisfies only some ports.
@shiju-nv, I also checked your requests for service-owned refresh orchestration, simpler resolver fixtures, and a compact rejection test. Those remain open advisory review topics; this commit retains the existing structure. I have left your threads untouched.
Blocking findings: None.
Carried Gator findings: None.
Required branch checks and the standard E2E suite are running on this head. Gator will monitor their results; maintainer review is still required.
Gator metadata
- Validation: Focused network reliability fix implementing accepted issue #4674.
- Docs: Previously reviewed published network-policy and logging updates remain accurate; delta adds implementation details to the crate README.
- Checks: DCO, Helm Lint, and Trivy Changes passed; Branch Checks pending.
- E2E:
test:e2eretained; current-head Branch E2E Checks run 44156946578 is queued with standard-suite jobs running. No rerun needed for this head. - Head SHA:
97e8a42fc96be51179c31eb19ed2691bc2cd2100 - Base SHA:
624aceea32934f73c350ede3f2185880816a030c - Merge base SHA:
2e5589b2180dd432320adda124c4f7bcede119b5 - Patch ID:
b10279719bf29e9a09ebfad4b49dfd2b9da29bff - Gator payload:
13 - Review mode:
follow_up - Previous reviewed SHA:
e66f4e3ef69851e0ab0ae4e6860632574e020555 - Review budget exhausted: no
- Maintainer decision required: no convergence decision required; open advisory human threads remain for normal review.
- Next state:
gator:watch-pipeline
TaylorMutch
left a comment
There was a problem hiding this comment.
Rechecked 97e8a42. Both previously reported correctness issues are fixed: dispatch reauthorizes and rebuilds connectors from current DNS pins, and refresh eligibility preserves authored ports independently of the latest usable contracts. No new correctness findings. Validation: 72 policy-DNS tests and the real-TCP dispatch regression passed locally; Branch Checks and E2E are green. The open architecture and test-simplification suggestions are advisory.
Summary
Refresh expired policy DNS mappings when a new transparent connection uses a cached synthetic address. Clients can reconnect after the resolver TTL without performing another DNS lookup, while resolver failures and rejected destinations still fail closed.
Related Issue
Closes #4674
Changes
Release Notes
Clients that cache DNS answers can open new connections after a synthetic mapping expires. OpenShell refreshes and validates the destination before connecting.
Testing
mise run docspassed.local_container_native_tcp_uses_policy_dns_and_fails_closedpassed with freshly built supervisor and sandbox images, including a connection to a cached numeric address after 31 seconds.Checklist