You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
gate-5 and gate-14 invariant 2 never judge the ten routes Routes::standard() supplies — doriath's settings#update resolves to a method that does not exist #265
#264 taught gate-14 invariant 1 about them, so an app shipping its own DashboardController / SettingsController is no longer told its working endpoints 404. That direction only removes false positives, which is why it was safe to land on its own.
The other two directions were deliberately left open, and both are false NEGATIVES in a security gate:
gate-5 (route-auth) iterates only the names it can grep out of appinfo/routes.php. For an ADR-040 adopter that means its dashboard#page, settings#* and preferences#* endpoints — served by the leaf's own controllers whenever it defines them, because aliasControllerUnlessLeafDefinesIt skips the alias — are never auth-judged at all. A missing #[NoAdminRequired] there is invisible.
gate-14 invariant 2 likewise never checks that the named method exists on the class the route resolves to.
The concrete defect this hides, found while measuring #264
Routes::standard() supplies settings#update (PUT /api/settings). doriath's lib/Controller/SettingsController.php has no update() — its methods are index, create, load, getAdminSettings, updateAdminSettings, getUserSettings, updateUserSettings, getPolicy (measured at origin/development b11ee90be).
Because doriath does define SettingsController, Bootstrap::aliasControllerUnlessLeafDefinesIt() does not alias the AppHost generic in — so PUT /api/settings resolves to a method that does not exist. That is invariant 2's exact subject matter (ReflectionException 500) and no gate currently asks the question.
What to do
Feed _HYDRA_APPHOST_ROUTE_NAMES (already defined in run-hydra-gates.sh as of #264) into:
gate-5's route-name stream, when _HYDRA_APPHOST_ROUTE_TABLE=1
gate-14 invariant 2's route-name stream, same condition
The existing absent-file handling already covers the legitimate case: when the leaf does not define the controller, _apphost_serves marks it NOT JUDGED rather than a finding.
⚠️ It adds findings across up to 16 apps, where #264 only removes them. Measured on doriath and procest, the auth attributes are present on every controller they do define — so the gate-5 half looks close to free — but "looks close to free on two repos" is not a fleet measurement, and a change that can turn green repos red needs its own A/B and its own PR. Mixing it in would have made #264's before/after unreadable.
Blocked on nothing; wants a full-fleet A/B before merge.
Activity
fix(gates 12-22): four gates could not detect the defect they exist f…
fix(gate-14): a namespaced route name resolves to the app root, not t…
fix(gates 12-22): four gates could not detect the defect they exist f…