deployed_allowlist_parses cannot observe the deployment it is named after #11
Labels
No labels
waiting-on-julian
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
jlxq0/carddav-mcp#11
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
src/oauth_redirect.rs:347is nameddeployed_allowlist_parsesand holdsnothing about the deployment. It hardcodes a nine-entry literal, parses it, and
asserts the count is nine. Nothing in the suite reads an environment variable;
grep -n 'env::var' src/oauth_redirect.rsis empty.AGENTS.mdalready carries the prose warning ("Adding a URI todeployed_allowlist_parsesdoes not enable it at runtime"). This issue existsbecause the test's name is the thing making the false promise, and a name is
read far more often than a pitfall list.
Measured, not inferred. Three mutations against
12395a1:https://attacker.example/callbackto the literal and bump the count toten. All 10 tests in the module pass. A URI that is in no deployment and
was reviewed by nobody sails through a test whose name says "deployed".
validate_redirect_uri, so cleartextcallbacks are accepted on any host.
http_is_loopback_onlygoes red;deployed_allowlist_parsesstays green. It pins nothing about safety.matches_loopback_entry→return falsereddensloopback_entry_matches_any_portandloopback_port_relaxation_does_not_relax_host_or_path. Those two do holdtheir behaviour.
I also compared the literal against the live value
(
kubectl get deploy carddav-mcp -n carddav-mcp -o jsonpath=…) and they arebyte-identical right now. That is agreement, not a measurement: mutation 1 shows
the suite would not notice if they stopped agreeing, in either direction — a
dropped entry silently breaking a client, or an added one silently enabling a
redirect nobody reviewed.
Fix is a rename plus a comment saying what it does and does not cover, e.g.
configured_allowlist_shape_parses. Deliberately kept out of PR #8, which Alanscoped to three prose lines.
A real deployment check would have to read the platform repo's manifest, which
is a different repo and a different pipeline, and is probably not worth it. The
name is.