Repository navigation
Conversation
…licy The egress guard denied only 169.254.169.254 and fd00:ec2::254 when an operator admits private targets (OPENSTORAGE_WEBHOOK_ALLOW_PRIVATE, OPENSTORAGE_SYNC_ALLOW_PRIVATE, and the transitional pull default). The other metadata and credential endpoints of the major clouds sit inside the classes that the policy admits: Alibaba Cloud's 100.100.100.200 in RFC 6598 shared space, AWS ECS and EKS, Tencent Cloud and Scaleway in 169.254/16, Google Cloud and Scaleway IPv6 in ULA space, and OpenStack's fe80::a9fe:a9fe in IPv6 link-local space. With private targets admitted, a webhook or a sync link could reach them. deniedReason now denies one list of single addresses, metadataAddrs, whatever the policy; each entry cites the provider's documentation. The classes around them stay admitted. The comments, the boot warnings, the configuration and deployment docs and ADR-45 list RFC 6598 shared space with the admitted classes and state the metadata rule; the configuration reference gets the list. Signed-off-by: Thomas Kosiewski <tk@coder.com> --- _Generated with [`xum`](https://github.com/coder/xum) • Model: `anthropic:claude-opus-5-5` • Thinking: `xhigh`_ Change-Id: I1d3933353e9b897a8a669325f992763d0094cb2b Signed-off-by: Thomas Kosiewski <tk@coder.com>
|
@codex review |
|
@codex security review |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
Security findingsAdvisory findings (1)
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8f097c7bd1
ℹ️ 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".
🛡️ Codex Security ReviewSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
fd00:c1::a9fe:a9fe is the IPv6 metadata and instance-principal credential endpoint that Oracle's own SDK (oci-python-sdk, IMDS_IPV6_HOST) and cloud-init use; Oracle's metadata page names only 169.254.169.254. It lies in ULA space, so private-admitting policies reached it. The docs no longer say that every IPv6 address outside 2000::/3 stays denied under `true` (loopback, ULA and link-local are admitted), nor that each entry has a private class around it (192.0.0.192 has none). The guard comment cites AWS for 169.254.169.254, and the boot warning test pins the new text. Signed-off-by: Thomas Kosiewski <tk@coder.com> --- _Generated with [`xum`](https://github.com/coder/xum) • Model: `anthropic:claude-opus-5-5` • Thinking: `xhigh`_ Change-Id: Icd1f32804db687427a41dbc7b6b74609227be878 Signed-off-by: Thomas Kosiewski <tk@coder.com>
|
@codex review |
|
@codex security review |
|
Codex Review: Didn't find any major issues. What shall we delve into next? Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
🛡️ Codex Security ReviewSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
169.254.169.252 is the GKE metadata server that Pods reach for Workload Identity (ports 988 and 987, in Google's network policy guide). It lies in 169.254/16, so private-admitting policies reached it. The sync egress test now records a denial for each request, the configuration reference says that an IPv4-mapped address counts as its IPv4 address, and a long line is rewrapped. Signed-off-by: Thomas Kosiewski <tk@coder.com> --- _Generated with [`xum`](https://github.com/coder/xum) • Model: `anthropic:claude-opus-5-5` • Thinking: `xhigh`_ Change-Id: Ic7df241bc27ab3f3b5321959a943abe0381bf97f Signed-off-by: Thomas Kosiewski <tk@coder.com>
|
@codex review |
|
@codex security review |
|
Codex Review: Didn't find any major issues. 🚀 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
There was a problem hiding this comment.
🛡️ Codex Security Review
Here are some automated security review suggestions for this pull request.
Reviewed commit: 6a333c51a8
ℹ️ About Codex security reviews in GitHub
This is an experimental Codex feature. Security reviews are triggered when:
- You comment "@codex security review"
- A regular code review gets triggered (for example, "@codex review" or when a PR is opened), and you’re opted in so security review runs alongside code review
Once complete, Codex will leave suggestions, or a comment if no findings are found.
Microsoft lists WireServer (168.63.129.16) with the Instance Metadata Service as serving metadata and bootstrapping VM credentials, in its Metadata Security Protocol overview. It is a public address, so every policy admitted it, the strict default too. It is denied now under every policy; its neighbours stay public. The guard comment cites Hetzner for fe80::a9fe:a9fe, and an older guard test that named 100.100.100.200 as a plain shared-space target uses 100.100.100.201. Signed-off-by: Thomas Kosiewski <tk@coder.com> --- _Generated with [`xum`](https://github.com/coder/xum) • Model: `anthropic:claude-opus-5-5` • Thinking: `xhigh`_ Change-Id: Iaad16b9e8def9cc74e97acd7886b9c48ddbc5ef9 Signed-off-by: Thomas Kosiewski <tk@coder.com>
With private targets admitted, the egress guard denied only two cloud metadata addresses,
169.254.169.254andfd00:ec2::254. The other metadata and credential endpoints of the major clouds lie inside the classes that the policy admits, so a webhook or a sync link could reach them whenever an operator setOPENSTORAGE_WEBHOOK_ALLOW_PRIVATE=trueorOPENSTORAGE_SYNC_ALLOW_PRIVATE=true, and on pulls under the transitional default too. Alibaba Cloud's100.100.100.200, for example, is in RFC 6598 shared space. Azure's WireServer,168.63.129.16, is a public address, so every policy admitted it, the strict default too. (fe80::a9fe:a9feis listed for completeness: on Linux a link-local address without a zone does not connect, and with a zone the guard already refused it.)Now
deniedReason(internal/events/guard.go) denies one list of single addresses,metadataAddrs, under every policy, for webhook deliveries and for both sync directions. The private classes around them stay admitted.The list
Each address was checked on 2026-11-16 in the provider's own documentation, except
fd00:c1::a9fe:a9fe, which comes from Oracle's own SDK:169.254.169.254fd00:ec2::254169.254.170.2169.254.170.23,fd00:ec2::23fd20:ce::254169.254.169.252100.100.100.200169.254.10.10metadata.tencentyun.com169.254.0.23169.254.42.42,fd00:42::42fd00:a9fe:a9fe::1fe80::a9fe:a9fefd00:c1::a9fe:a9fe169.254.169.254)IMDS_IPV6_HOST), also cloud-init168.63.129.16192.0.0.192192.0.0.0/24; listed for its reason)An IPv4 entry is denied in its IPv4-mapped IPv6 form too (the guard unmaps first), and a DNS name that resolves to an entry, such as
metadata.google.internal, is denied at registration and at dial time.Not on the list:
fd00:100::100:200, an Alibaba Cloud IPv6 metadata address named only in a cloud-init issue and an unmerged cloud-init PR; Alibaba's metadata pages and its own credential SDKs name only100.100.100.200.Comments and docs
guard.go(TargetGuard.AllowPrivate,metadataAddrs),cmd/openstorage/config.go,internal/sync/worker.go,internal/sync/egress.goandcmd/openstorage/wire_eventing.golist RFC 6598 shared space with the admitted classes and state that the cloud metadata endpoints stay denied.cmd/openstorage/wire.goname the admitted classes, RFC 6598 included, and say that a cloud metadata endpoint is never a target.docs/reference/configuration.mdgets a "Cloud metadata endpoints" section with the list; the sync and webhook sections, the table rows,docs/reference/http-api.md,docs/how-to/deploy-production.md, ADR-45 (a new paragraph),README.mdandinternal/events/README.mdpoint to it. The synctruevalue also names the other addresses that stay denied (multicast, broadcast, unspecified, zone-scoped, IPv6 outside2000::/3), and the unset default says that pulls admit whattrueadmits: two P3 points from the review of docs(sync): name OPENSTORAGE_SYNC_ALLOW_PRIVATE for push destinations #897.Evidence
TestTargetGuardDeniesCloudMetadataUnderEveryPolicy(internal/events): each of the 17 addresses, and each IPv4 one in its mapped form, withAllowPrivateoff and on:deniedReason, dial time for the literal and for a name that resolves to it,CheckHostandCheckRegistration.TestTargetGuardMetadataNeighborsKeepTheirClass: the addresses next to the endpoints (100.100.100.201,169.254.170.3,fd20:ce::255, …) stay admitted withAllowPrivateand keep their class's reason without it, so each entry is one address.TestEgressProxyDeniesCloudMetadataUnderEveryPolicy(internal/sync): the sync egress proxy answers 403 to CONNECT and to an absolute-form request for five endpoints, with the private hatch off and on.TestRegistrationDeniesCloudMetadataWithPrivateAllowed(internal/api): with private targets admitted,POST /reposwithupstream.hosthttp://100.100.100.200,http://169.254.170.2orhttp://[fd20:ce::254], andPOST /webhooksto100.100.100.200,169.254.170.23or[fd00:ec2::23], answer 400cloud metadata addressand store nothing.guard.gooverlaid): everyallow_privatecase of the guard and proxy tests fails, and so does every case whose reason differs; the sync create to100.100.100.200answers 201, and the proxy dials100.100.100.200and169.254.170.2(10 s connect timeout).go test -race -tags=openstorage_viewcheckof./internal/events/...(21 s),./internal/sync/...(75 s) and./internal/api/...without pg (362 s) pass at 8f097c7; b07b4d1, 6a333c5 and 8ba58a3 add three addresses, docs and tests; at each of them./internal/events/...and the egress tests of./internal/syncpass with-race, and the api metadata test passes. PostgreSQL and S3-WAL rely on CI.internal/events,internal/sync,internal/api,cmd/openstorage), vet (linux and darwin), gofmt, the docs gate and both fingerprint gates pass.go test ./cmd/openstorage/passes (the boot warning tests match on substrings that stay).Reviews
Round 1 (8f097c7): the Codex security review found nothing. The Codex review (P1) and a fresh read-only review both asked for
fd00:c1::a9fe:a9fe, which b07b4d1 adds with Oracle's SDK as the source. The review also found a P2 in the docs: the synctruevalue said that all IPv6 outside2000::/3stays denied, but loopback, ULA and link-local are admitted. b07b4d1 fixes it with four P3 points: a source for169.254.169.254inguard.go,192.0.0.192has no private class around it, a boot warning test that pins the new text, and a ragged line. The reviewer's 18 overlay mutants (each address dropped, the metadata case moved after the private cases or beforeUnmap, gated on the policy) all failed the tests.Round 2 (b07b4d1): the Codex review and the Codex security review found nothing. A fresh read-only review found one P2: Google documents
169.254.169.252as the GKE metadata server, and the guard admitted it under private-admitting policies. 6a333c5 adds it, with three P3 points: the sync egress test records a denial for each request, the configuration reference says that an IPv4-mapped address counts as its IPv4 address, and a long line is rewrapped. Not changed: no test pins the webhook boot warning (it is logged inline inbuildAPIHandler), and ADR-44 keeps its generic list.Round 3 (6a333c5): the Codex review and a fresh read-only review (PASS) found nothing new in the code. The Codex security review (P2) asked for Azure's WireServer,
168.63.129.16, citing Microsoft's Metadata Security Protocol overview, which lists it with the Instance Metadata Service as serving metadata and bootstrapping VM credentials. 8ba58a3 adds it: it is a public address, so it was admitted even under the strict default. That commit also adds the Hetzner source forfe80::a9fe:a9feand moves an older guard test from100.100.100.200to100.100.100.201. All six Codex requests of this PR are used, so this last head has no Codex pass; a fresh read-only review covers it.Round 4 (8ba58a3): a fresh read-only review: PASS. Its overlay mutants (main's guard, WireServer dropped, a /24 in its place, metadata before
Unmap, metadata only withAllowPrivate) all failed the tests. Four wording points follow up in the desk's docs PR:deploy-production.mdand the webhookfalsebullet still file the metadata endpoints under the public or IANA ranges, ADR-45 says that the private classes hold them all, and theguard.gonote on168.63.129.16reads as past tense.Left open (P3): no test pins the webhook boot warning text (it is logged inline in
buildAPIHandler); ADR-44 keeps its generic list; the webhook half of the api test fails on main only after the sync half (the events test covers it).Found by the reviews of #897 (desk follow-up).
Generated with
xum• Model:anthropic:claude-opus-5-5• Thinking:xhigh