fix: reject recursive gateway network authority - #27
seonghobae merged 45 commits into
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthrough게이트웨이 소유 트래픽 및 메트릭 리스너와 업스트림 transport authority의 중복 검증을 추가합니다. canonical 업스트림 주소의 비특정 및 비유니캐스트 주소도 거부합니다. generic 및 pg-erd 구성과 실행 경로를 테스트합니다. Changes게이트웨이 권한 분리
Priority: ➖ Normal Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Bug fix Sequence Diagram(s)sequenceDiagram
participant ConfigSource
participant GatewayConfig
participant MigrationAdmin
participant GatewayBinary
ConfigSource->>GatewayConfig: 구성 로드 및 validate
GatewayConfig->>GatewayConfig: 업스트림 authority 및 canonical 주소 검사
GatewayConfig-->>ConfigSource: 충돌 또는 주소 오류 반환
ConfigSource->>MigrationAdmin: pg-erd 업스트림 검증
MigrationAdmin->>MigrationAdmin: listener 및 metrics_listener와 비교
MigrationAdmin-->>GatewayBinary: 검증 결과 전파
GatewayBinary-->>ConfigSource: 오류 발생 시 리스너 활성화 전 종료
Merge Risk: ⚪ Minimal · up to The configured upstream validation rejects the intended recursive and non-unicast authorities through both configuration types. No concrete merge-blocking risk remains. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Successor carryover check — exact head
|
seonghobae
left a comment
There was a problem hiding this comment.
Current exact-range owner technical sweep on final #25 f1f84c6130356134755a5eb48409bf9a485395c8 → 4fd3d1a63e72260519ee415e968db383a4e16415 finds no remaining actionable source/documentation defect in the four effective paths. The child reuses the existing socket-authority overlap model, preserves pg-erd fixed upstream-name/error precedence, keeps distinct concrete same-port authorities admitted, revalidates direct-Serde construction at build_proxy(), and exercises compiled fail-closed startup for both composition roots. The current fixture also quotes every interpolated socket authority, so the IPv6 dual-stack case reaches SocketAddr validation rather than failing in YAML parsing. Hosted CI/Supply Chain are still in progress; this COMMENT is technical evidence only, not self-approval or independent APPROVED governance.
seonghobae
left a comment
There was a problem hiding this comment.
Current-exact owner technical sweep (COMMENT only; not self-approval or organization-governance credit): RFC 9293 §3.9.1.1 MUST-46 requires TCP active OPEN to reject an invalid remote IP address, explicitly including broadcast or multicast destinations. Predecessor 8a6b8da... rejected zero-port, unspecified and recursive listener aliases but still admitted IPv4 multicast, IPv4 limited broadcast, IPv6 multicast, and IPv4-mapped multicast/broadcast authorities. Test-first 176b1d9... adds generic and pg-erd runtime RED cases for those five forms. Minimal production repair 5a0f1ec... reuses the existing canonical IP value and rejects only IPv4 broadcast/multicast plus IPv6 multicast via NonUnicastUpstreamAddress; loopback/private/link-local/documentation and other concrete unicast addresses remain unaffected. Exact 5d6b790... pins that specific error reason in both config roots. Fresh base compare is 1a369e... -> 5d6b790..., ahead 42 / behind 0, five effective paths. Hosted exact-head formatting/compile/test/coverage/load/OCI/Supply evidence and independent governance remain required.
|
@coderabbitai review Please review current exact |
|
Tip For best results, initiate chat on the files or code changes. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
repo="ContextualWisdomLab/pingora-gateway"
base="1a369e144ce8021595cebe388ab042e369875229"
head="5d6b79028cd5dee173216fd6bbd83d526b0dde70"
predecessor="8a6b8da2a90b9ab3310fbc99d1d4e47d9ac496fe"
echo '== Live pull request metadata =='
gh pr view 27 --repo "$repo" \
--json number,state,isDraft,headRefName,headRefOid,baseRefName,baseRefOid,mergeable,reviewDecision,statusCheckRollup
echo '== Exact ancestry =='
printf 'merge-base='
git merge-base "$base" "$head"
git merge-base --is-ancestor "$base" "$head"
echo "base_is_ancestor=$?"
printf 'ahead='
git rev-list --count "$base..$head"
printf 'behind='
git rev-list --count "$head..$base"
git merge-base --is-ancestor "$predecessor" "$head"
echo "predecessor_is_ancestor=$?"
echo '== Effective changed paths and whitespace =='
git diff --name-status "$base" "$head"
git diff --stat "$base" "$head"
git diff --check "$base" "$head" --
echo '== Follow-up commits and paths =='
git log --format='%H %s' --reverse "${predecessor}..${head}"
git diff --name-status "$predecessor" "$head"
git diff --unified=24 "$predecessor" "$head" -- \
TEST_STRATEGY.md \
src/edge_contract.rs \
src/migration_admin.rs \
tests/network_authority_self_loop_contract.rs
echo '== Validation source maps =='
ast-grep outline src/edge_contract.rs --items all --type function,enum,impl --match 'GatewayConfig|GatewayConfigError|UpstreamConfig|validate_upstream_authority_separation|socket_authorities_overlap'
ast-grep outline src/migration_admin.rs --items all --type function,impl --match 'PgErdMigrationConfig|validate_transport_authority|build_proxy'
ast-grep outline tests/network_authority_self_loop_contract.rs --items all --type function
echo '== Destination and listener-authority validation contexts =='
rg -n -C 28 --type rust '\b(to_canonical|is_unspecified|is_multicast|is_broadcast|UnspecifiedUpstreamAddress|NonUnicast|validate_upstream_authority_separation|socket_authorities_overlap)\b' \
src/edge_contract.rs src/migration_admin.rs
echo '== Contract test cases =='
rg -n -C 20 --type rust '(0\.0\.0\.0|\[::\]|::ffff|multicast|broadcast|Unicast|Unspecified|NonUnicast)' \
tests/network_authority_self_loop_contract.rs
echo '== Exact five-path diff =='
git diff --unified=16 "$base" "$head" -- \
TEST_STRATEGY.md \
src/edge_contract.rs \
src/migration_admin.rs \
tests/network_authority_self_loop_contract.rs
echo '== Exact-head workflow state =='
gh pr checks 27 --repo "$repo" || true
echo '== Review receipts =='
gh pr view 27 --repo "$repo" --json reviews \
--jq '.reviews[] | {author: .author.login, state: .state, commit: .commit.oid, submittedAt: .submittedAt}' || trueLength of output: 13007 🏁 Script executed: #!/bin/bash
set -euo pipefail
repo="ContextualWisdomLab/pingora-gateway"
base="1a369e144ce8021595cebe388ab042e369875229"
head="5d6b79028cd5dee173216fd6bbd83d526b0dde70"
echo '== edge_contract imports and validation contexts =='
sed -n '1,145p' src/edge_contract.rs
rg -n -C 26 --type rust '\b(socket_authorities_overlap|validate_upstream_authority_separation|fn validate\(&self\)|to_canonical|is_unspecified|is_broadcast|is_multicast|NonUnicastUpstreamAddress)\b' src/edge_contract.rs
echo '== pg-erd validation and construction contexts =='
rg -n -C 28 --type rust '\b(validate_transport_authority|build_proxy|self\.validate\(\)|UpstreamConfiguration)\b' src/migration_admin.rs
echo '== all non-unicast contract cases =='
cat -n tests/upstream_unicast_authority_contract.rs
echo '== self-loop contract cases relevant to canonicalization and validation =='
rg -n -C 18 --type rust '(::ffff|0\.0\.0\.0|\[::\]|UnspecifiedUpstreamAddress|NonUnicastUpstreamAddress|build_proxy)' tests/network_authority_self_loop_contract.rs
echo '== all uses of NonUnicastUpstreamAddress =='
rg -n -C 6 --type rust '\bNonUnicastUpstreamAddress\b' .
echo '== effective documentation diff =='
git diff --unified=24 "$base" "$head" -- TEST_STRATEGY.md
echo '== exact-head checks =='
gh pr checks 27 --repo "$repo" || true
echo '== exact-head reviews =='
gh pr view 27 --repo "$repo" --json reviews \
--jq '.reviews[] | {author: .author.login, state: .state, commit: .commit.oid, submittedAt: .submittedAt}' || trueLength of output: 66759 🤖 web_search executed:
Length of output: 5778 🏁 Script executed: #!/bin/bash
set -euo pipefail
url="https://www.rfc-editor.org/rfc/rfc9293.txt"
curl --fail --silent --show-error --location "$url" |
awk '
/MUST-46/ { start=NR-8; end=NR+12 }
NR >= start && NR <= end { printf "%d:%s\n", NR, $0 }
'Length of output: 3021 🏁 Script executed: #!/bin/bash
set -euo pipefail
base="1a369e144ce8021595cebe388ab042e369875229"
head="5d6b79028cd5dee173216fd6bbd83d526b0dde70"
predecessor="8a6b8da2a90b9ab3310fbc99d1d4e47d9ac496fe"
echo '== Remaining pg-erd authority validation =='
sed -n '180,230p' src/migration_admin.rs
echo '== Focused implementation and regression diffs =='
git diff --unified=30 "$predecessor" "$head" -- \
src/edge_contract.rs \
tests/upstream_unicast_authority_contract.rs
echo '== Five-path range details =='
git diff --numstat "$base" "$head"
git diff --check "$base" "$head" --Length of output: 13574 🏁 Script executed: #!/bin/bash
set -euo pipefail
curl --fail --silent --show-error --location \
"https://www.rfc-editor.org/rfc/rfc9293.txt" |
grep -n -C 10 'MUST-46' |
head -n 45Length of output: 3177
I found no implementation finding. The merge base is
The new validation satisfies the RFC 9293 MUST-46 requirement. RFC 9293 states that a TCP implementation “MUST reject as an error a local OPEN call for an invalid remote IP address (e.g., a broadcast or multicast address).”
The code calls The existing unspecified-address behavior remains correct. Canonicalization causes The listener-authority behavior remains bounded:
The exact-head CI jobs 🧠 Learnings usedYou are interacting with an AI system. |
seonghobae
left a comment
There was a problem hiding this comment.
Current-exact owner technical sweep (COMMENT only; not self-approval or organization-governance credit): 00046c7bc4c48d737a2ef9c243315f55268475b3 is ahead-only one commit from source/test exact 5d6b790... and changes only TEST_STRATEGY.md (+1/-1). The documentation now matches the implemented authority contract: recursive listener aliases remain rejected, tests/upstream_unicast_authority_contract.rs separately pins IPv4 limited broadcast, IPv4/IPv6 multicast, and mapped broadcast/multicast as invalid remote TCP authority after canonicalization, while distinct concrete non-aliased unicast same-port addresses remain admitted. The prior 5d6b790... source/test review remains historical; fresh exact-head hosted CI/Supply and independent current-head review are required.
|
@coderabbitai review Please review current exact |
🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
repo="ContextualWisdomLab/pingora-gateway"
base="1a369e144ce8021595cebe388ab042e369875229"
head="00046c7bc4c48d737a2ef9c243315f55268475b3"
predecessor="5d6b79028cd5dee173216fd6bbd83d526b0dde70"
echo '== Live pull request metadata =='
gh pr view 27 --repo "$repo" \
--json number,state,isDraft,headRefName,headRefOid,baseRefName,baseRefOid,mergeable,reviewDecision,statusCheckRollup
echo '== Requested commit and ancestry =='
git rev-parse "${head}^{commit}"
printf 'merge-base='
git merge-base "$base" "$head"
git merge-base --is-ancestor "$base" "$head"
echo "base_is_ancestor=$?"
git merge-base --is-ancestor "$predecessor" "$head"
echo "predecessor_is_ancestor=$?"
printf 'ahead='
git rev-list --count "$base..$head"
printf 'behind='
git rev-list --count "$head..$base"
echo '== Effective changed paths and whitespace =='
git diff --name-status "$base" "$head"
git diff --stat "$base" "$head"
git diff --check "$base" "$head" --
echo '== Final commit identity and changed paths =='
git show --no-ext-diff --format=fuller --name-status "$head"
echo '== Final documentation-only diff =='
git diff --unified=30 "$predecessor" "$head" -- TEST_STRATEGY.md
echo '== Source changes after predecessor =='
git diff --name-status "$predecessor" "$head" -- src tests
echo '== Relevant source outlines =='
ast-grep outline src/edge_contract.rs --items all --type function,enum,impl --match 'GatewayConfig|GatewayConfigError|UpstreamConfig|validate_upstream_authority_separation|socket_authorities_overlap'
ast-grep outline src/migration_admin.rs --items all --type function,impl --match 'PgErdMigrationConfig|validate_transport_authority|build_proxy'
ast-grep outline tests/upstream_unicast_authority_contract.rs --items all --type function
ast-grep outline tests/network_authority_self_loop_contract.rs --items all --type function
echo '== Validation and test contexts =='
rg -n -C 20 --type rust '\b(to_canonical|is_unspecified|is_multicast|is_broadcast|NonUnicastUpstreamAddress|validate_upstream_authority_separation|validate_transport_authority|build_proxy)\b' \
src/edge_contract.rs src/migration_admin.rs tests/upstream_unicast_authority_contract.rs tests/network_authority_self_loop_contract.rs
echo '== Exact-head workflow state and reviews =='
gh pr checks 27 --repo "$repo" || true
gh pr view 27 --repo "$repo" --json reviews \
--jq '.reviews[] | {author: .author.login, state: .state, commit: .commit.oid, submittedAt: .submittedAt}' || trueLength of output: 30989 🏁 Script executed: #!/bin/bash
set -euo pipefail
repo="ContextualWisdomLab/pingora-gateway"
head="00046c7bc4c48d737a2ef9c243315f55268475b3"
echo '== Source and test outlines =='
ast-grep outline src/edge_contract.rs --items all --type function,enum --match 'GatewayConfig|GatewayConfigError|UpstreamConfig|validate_upstream_authority_separation|socket_authorities_overlap'
ast-grep outline src/migration_admin.rs --items all --type function --match 'PgErdMigrationConfig|validate_transport_authority|build_proxy'
ast-grep outline tests/upstream_unicast_authority_contract.rs --items all --type function
ast-grep outline tests/network_authority_self_loop_contract.rs --items all --type function
echo '== Upstream validation implementation =='
rg -n -C 28 --type rust '\b(to_canonical|is_unspecified|is_multicast|is_broadcast|NonUnicastUpstreamAddress|fn validate\(&self\)|validate_upstream_authority_separation|socket_authorities_overlap)\b' src/edge_contract.rs
echo '== Pg-erd validation boundary =='
rg -n -C 28 --type rust '\b(validate_transport_authority|build_proxy|self\.validate\(\)|UpstreamConfiguration)\b' src/migration_admin.rs
echo '== Non-unicast authority contract =='
cat -n tests/upstream_unicast_authority_contract.rs
echo '== Self-loop canonicalization and construction-boundary contract =='
rg -n -C 16 --type rust '(::ffff|0\.0\.0\.0|\[::\]|UnspecifiedUpstreamAddress|build_proxy|startup)' \
tests/network_authority_self_loop_contract.rs
echo '== Exact-head workflow state =='
gh pr checks 27 --repo "$repo" || true
echo '== Exact-head review receipts =='
gh pr view 27 --repo "$repo" --json reviews \
--jq '.reviews[] | {author: .author.login, state: .state, commit: .commit.oid, submittedAt: .submittedAt}' || true
echo '== Checkout identity =='
git rev-parse HEAD
git merge-base --is-ancestor "$head" HEAD
echo "requested_head_is_ancestor_of_checkout=$?"Length of output: 38876
I used the existing PR guidance to review the live configured base-to-head range. The merge base is The effective range contains five paths:
I found no implementation or documentation finding. Commit
The listener-authority invariant remains separate and bounded to the traffic The exact-head CI jobs I did not execute repository code or tests in this inspection environment. 🧠 Learnings used✅ Action performedReview finished.
|
seonghobae
left a comment
There was a problem hiding this comment.
Hosted CI 35031683741 exposed a source-local formatter RED on exact 00046c7bc4c48d737a2ef9c243315f55268475b3: test failed at cargo fmt --all -- --check while oci-runtime, load-contract, and Supply Chain were successful. The lane was returned to Draft before source movement. Exact c2dfbbc9e7af5026f3c194bf63a7153f758a9a48 applies only rustfmt's multiline trailing-comma layout in tests/upstream_unicast_authority_contract.rs; no policy, assertion, fixture data, or production behavior changes. Current head must obtain fresh execution and independent review before merge.
|
@coderabbitai review Please review current exact |
🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
repo="ContextualWisdomLab/pingora-gateway"
base="1a369e144ce8021595cebe388ab042e369875229"
head="c2dfbbc9e7af5026f3c194bf63a7153f758a9a48"
predecessor="00046c7bc4c48d737a2ef9c243315f55268475b3"
echo '== Live PR metadata =='
gh pr view 27 --repo "$repo" \
--json number,state,isDraft,headRefName,headRefOid,baseRefName,baseRefOid,mergeable,reviewDecision,statusCheckRollup
echo '== Exact ancestry =='
printf 'merge-base='
git merge-base "$base" "$head"
git merge-base --is-ancestor "$base" "$head"; echo "base_is_ancestor=$?"
git merge-base --is-ancestor "$predecessor" "$head"; echo "predecessor_is_ancestor=$?"
printf 'ahead='; git rev-list --count "$base..$head"
printf 'behind='; git rev-list --count "$head..$base"
echo '== Effective base-to-head paths =='
git diff --name-status "$base" "$head"
git diff --stat "$base" "$head"
echo '== Whitespace check =='
git diff --check "$base" "$head" --
echo '== Predecessor-to-head change =='
git show --no-ext-diff --format=fuller --name-status "$head"
git diff --check "$predecessor" "$head" --
git diff --unified=24 "$predecessor" "$head" -- tests/upstream_unicast_authority_contract.rs
echo '== Non-target source/test changes after predecessor =='
git diff --name-status "$predecessor" "$head" -- . ':!tests/upstream_unicast_authority_contract.rs'
echo '== Test and validation outlines =='
ast-grep outline tests/upstream_unicast_authority_contract.rs --items all --type function
ast-grep outline src/edge_contract.rs --items all --type function,enum,impl --match 'GatewayConfig|GatewayConfigError|UpstreamConfig|validate_upstream_authority_separation'
ast-grep outline src/migration_admin.rs --items all --type function,impl --match 'PgErdMigrationConfig|validate_transport_authority|build_proxy'
echo '== Relevant validation and regression-test contexts =='
rg -n -C 20 --type rust '\b(to_canonical|is_unspecified|is_multicast|is_broadcast|NonUnicastUpstreamAddress|validate_upstream_authority_separation|validate_transport_authority|build_proxy)\b' \
src/edge_contract.rs src/migration_admin.rs tests/upstream_unicast_authority_contract.rs
echo '== Exact-head workflows =='
gh pr checks 27 --repo "$repo" || true
echo '== Review receipts =='
gh pr view 27 --repo "$repo" --json reviews \
--jq '.reviews[] | {author: .author.login, state: .state, commit: .commit.oid, submittedAt: .submittedAt}' || trueLength of output: 8352 🏁 Script executed: #!/bin/bash
set -uo pipefail
repo="ContextualWisdomLab/pingora-gateway"
head="c2dfbbc9e7af5026f3c194bf63a7153f758a9a48"
echo '== Source outlines =='
ast-grep outline src/edge_contract.rs --items all --match 'GatewayConfig|GatewayConfigError|UpstreamConfig|validate_upstream_authority_separation|socket_authorities_overlap' || true
ast-grep outline src/migration_admin.rs --items all --match 'PgErdMigrationConfig|validate_transport_authority|build_proxy' || true
ast-grep outline tests/upstream_unicast_authority_contract.rs --items all || true
echo '== Upstream destination validation =='
rg -n -C 26 --type rust '\b(to_canonical|is_unspecified|is_multicast|is_broadcast|NonUnicastUpstreamAddress|validate_upstream_authority_separation|socket_authorities_overlap)\b' src/edge_contract.rs || true
echo '== PgErd validation boundary =='
rg -n -C 24 --type rust '\b(validate_transport_authority|build_proxy|self\.validate\(\)|UpstreamConfiguration)\b' src/migration_admin.rs || true
echo '== Non-unicast regression test =='
cat -n tests/upstream_unicast_authority_contract.rs
echo '== Current exact-head workflow state =='
gh pr checks 27 --repo "$repo" || true
echo '== Current review receipts =='
gh pr view 27 --repo "$repo" --json reviews \
--jq '.reviews[] | {author: .author.login, state: .state, commit: .commit.oid, submittedAt: .submittedAt}' || true
echo '== Checkout relation =='
git rev-parse HEAD
git merge-base --is-ancestor "$head" HEAD; echo "requested_head_is_ancestor_of_checkout=$?"Length of output: 26784
I used the existing PR guidance to review the live configured base-to-head range. The merge base is The effective range changes these five paths:
I found no implementation or test finding. The delta from The effective range retains the validation behavior:
The exact-head CI jobs CodeRabbit reports that reviews are disabled for this base branch. No CodeRabbit review receipt exists for this exact head. 🧠 Learnings used✅ Action performedReview finished.
|
seonghobae
left a comment
There was a problem hiding this comment.
Hosted log RCA corrected on current head. CI 35031683741 for predecessor 00046c7bc4c48d737a2ef9c243315f55268475b3 failed cargo fmt --all -- --check specifically on src/edge_contract.rs: Rust 1.98 requires the long UnspecifiedUpstreamAddress #[error(...)] attribute to use multiline formatting. The intervening c2dfbbc9e7af5026f3c194bf63a7153f758a9a48 trailing-comma-only test formatting change was benign but did not address the hosted finding. Current exact 84a4df0bb162673f602dac95e9ded7eaa0e23582 adopts that intervening delta and applies the exact runner-prescribed source formatting. No production semantics, error text, policy, or fixture values change. Fresh exact execution and independent review are still required.
|
@coderabbitai review Please review current exact |
🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
repo="ContextualWisdomLab/pingora-gateway"
base="1a369e144ce8021595cebe388ab042e369875229"
head="84a4df0bb162673f602dac95e9ded7eaa0e23582"
predecessor="c2dfbbc9e7af5026f3c194bf63a7153f758a9a48"
echo '== Live pull request metadata =='
gh pr view 27 --repo "$repo" \
--json number,state,isDraft,headRefName,headRefOid,baseRefName,baseRefOid,mergeable,reviewDecision,statusCheckRollup
echo '== Exact ancestry =='
git rev-parse "${head}^{commit}"
printf 'merge-base='; git merge-base "$base" "$head"
git merge-base --is-ancestor "$base" "$head"; echo "base_is_ancestor=$?"
git merge-base --is-ancestor "$predecessor" "$head"; echo "predecessor_is_ancestor=$?"
printf 'ahead='; git rev-list --count "$base..$head"
printf 'behind='; git rev-list --count "$head..$base"
echo '== Effective base-to-head paths and whitespace =='
git diff --name-status "$base" "$head"
git diff --stat "$base" "$head"
git diff --check "$base" "$head" --
echo '== Exact final commit =='
git show --no-ext-diff --format=fuller --name-status "$head"
echo '== Predecessor-to-head diff =='
git diff --check "$predecessor" "$head" --
git diff --unified=30 "$predecessor" "$head" -- \
src/edge_contract.rs \
tests/upstream_unicast_authority_contract.rs
echo '== Other paths after predecessor =='
git diff --name-status "$predecessor" "$head" -- . \
':!src/edge_contract.rs' \
':!tests/upstream_unicast_authority_contract.rs'
echo '== Relevant source maps =='
ast-grep outline src/edge_contract.rs --items all --type enum,function,impl --match 'GatewayConfigError|UpstreamConfig|validate_upstream_authority_separation|socket_authorities_overlap'
ast-grep outline tests/upstream_unicast_authority_contract.rs --items all --type function
echo '== Error attribute and destination validation contexts =='
rg -n -C 24 --type rust '\b(UnspecifiedUpstreamAddress|NonUnicastUpstreamAddress|to_canonical|is_unspecified|is_broadcast|is_multicast)\b' src/edge_contract.rs
echo '== Non-unicast regression test =='
cat -n tests/upstream_unicast_authority_contract.rs
echo '== Exact-head workflows =='
gh pr checks 27 --repo "$repo" || true
echo '== Review receipts =='
gh pr view 27 --repo "$repo" --json reviews \
--jq '.reviews[] | {author: .author.login, state: .state, commit: .commit.oid, submittedAt: .submittedAt}' || true
echo '== Checkout relation =='
git rev-parse HEAD
git merge-base --is-ancestor "$head" HEAD; echo "requested_head_is_ancestor_of_checkout=$?"Length of output: 9486 🏁 Script executed: #!/bin/bash
set -u
repo="ContextualWisdomLab/pingora-gateway"
head="84a4df0bb162673f602dac95e9ded7eaa0e23582"
echo '== Source outlines =='
ast-grep outline src/edge_contract.rs --items all --match 'GatewayConfigError|UpstreamConfig|validate_upstream_authority_separation|socket_authorities_overlap' || true
ast-grep outline src/migration_admin.rs --items all --match 'PgErdMigrationConfig|validate_transport_authority|build_proxy' || true
ast-grep outline tests/upstream_unicast_authority_contract.rs --items all || true
echo '== Upstream destination validation =='
rg -n -C 26 --type rust '\b(UnspecifiedUpstreamAddress|NonUnicastUpstreamAddress|to_canonical|is_unspecified|is_broadcast|is_multicast|validate_upstream_authority_separation|socket_authorities_overlap)\b' src/edge_contract.rs || true
echo '== PgErd validation boundary =='
rg -n -C 24 --type rust '\b(validate_transport_authority|build_proxy|self\.validate\(\)|UpstreamConfiguration)\b' src/migration_admin.rs || true
echo '== Non-unicast contract test =='
cat -n tests/upstream_unicast_authority_contract.rs || true
echo '== Exact head status checks =='
gh pr checks 27 --repo "$repo" || true
echo '== Review receipts =='
gh pr view 27 --repo "$repo" --json reviews \
--jq '.reviews[] | {author: .author.login, state: .state, commit: .commit.oid, submittedAt: .submittedAt}' || true
echo '== Checkout relation =='
git rev-parse HEAD || true
git merge-base --is-ancestor "$head" HEAD
echo "requested_head_is_ancestor_of_checkout=$?"Length of output: 26908
I used the existing PR guidance to scope the review to the live configured base-to-head range. The merge base is The effective range changes these five paths:
I found no implementation or test finding. Commit The commit preserves the earlier trailing comma in The effective range still has the required behavior:
The exact-head CI checks I did not run repository code or tests in this inspection environment. 🧠 Learnings used✅ Action performedReview finished.
|
Bounded authority
This PR owns gateway Admin Config / Runtime Isolation invariants for upstream TCP network authority only. It does not add product authentication/business routing, service discovery, Keyverse identity, Wardnet/EgressWeave verdicts, certificate authority, retry/failover policy, or consumer source mutation. Repository-wide TRACEABILITY and
docs/product-technical-gap-baseline.mdremain dedicated #61 authority.Parent succession
Canonical parent #25 exact
1a369e144ce8021595cebe388ab042e369875229reached terminal-success CI/Supply and was normally merged ase8d86b9c90bded49d48ee5e03535a45c5dab5837. Ordinary two-parent adoption6268351e7fd79a5fb0cf19000b18798bc7aa9af9made current #25 an ancestor;50bf0e124d188d6f4286f0947659f3f567191d16restored current-parent TEST_STRATEGY truth while preserving the bounded child delta. No force-push or destructive rebase is used.RED → causal repairs
49d2a252ea6d040ed163c90147263cbd3503209b→ repair584e6b898e5c796b076b46bfc6331f4a1b2c205a.804170e9be22a9d8da47842e272ae9e37d101656→ canonicalization repair8a6b8da2a90b9ab3310fbc99d1d4e47d9ac496fe.176b1d9f1fae963b6b2cff9bc96314d62e715a14→ repair5a0f1eccad2bf85923f5b82d6c09358def1866f9; exact-error fixture5d6b79028cd5dee173216fd6bbd83d526b0dde70.00046c7bc4c48d737a2ef9c243315f55268475b3limits same-port admission language to concrete non-aliased unicast authorities.00046c7...: CI35031683741had successfuloci-runtime/load-contractand successful Supply Chain but failed Rust 1.98 formatting. Current exact84a4df0bb162673f602dac95e9ded7eaa0e23582preserves the benign intervening fixture formatting and applies the exact hosted multiline layout for the longUnspecifiedUpstreamAddresserror attribute. No validation semantics, error text, policy, or fixture values changed.Primary references remain RFC 4291, RFC 9293 §3.9.1.1 MUST-46, RFC 919, and stable Rust canonicalization/broadcast/multicast predicates.
Current exact evidence
Current exact is
84a4df0bb162673f602dac95e9ded7eaa0e23582; configured base remains1a369e144ce8021595cebe388ab042e369875229. Effective paths remainTEST_STRATEGY.md,src/edge_contract.rs,src/migration_admin.rs,tests/network_authority_self_loop_contract.rs, andtests/upstream_unicast_authority_contract.rs.CI
35047995796is terminal SUCCESS at this exact.testpassed checkout identity, Rust 1.98 formatting, all-target compile/test, strict Clippy, warning-denied rustdoc, pinned coverage tooling, owned-production coverage enforcement and dependency-lock verification;load-contractpassed generic and routed pg-erd traffic/latency evidence;oci-runtimepassed dual-profile non-root/read-only runtime checks. Supply Chain35047995901is terminal SUCCESS and passed dependency audit, candidate image builds, SPDX SBOM generation, image scans, exact-source evidence binding and artifact upload.All review threads are resolved. Independent CodeRabbit current-head review reports Merge Risk Minimal and no actionable findings. Owner reviews remain COMMENT-only; there is no independent
APPROVEDreview in the current review inventory. No self-approval or governance bypass is authorized, so normal integration waits only for then-live required governance rather than for additional source or execution repair.Child succession
Direct child #107 remains Draft at
4bbd8a91dbd94a7d8e71106f81756f1a03b07c4fbecause its merge-base is historical00046c7...and it is ahead 11 / behind 2 relative to this exact. After #27 normally integrates, #107 must adopt the current parent by ordinary/non-force reconciliation, preserve only its four SNI HostName authority paths, and reacquire exact execution/review/governance. Historical #107 runs do not transfer.No protected merge, immutable release, parity, shadow/canary, cutover, rollback, or legacy-removal credit is claimed.