I extended the existing filter-chain configuration to gate a new set of admin endpoints behind a dedicated role, and read the acting user's identity out of a token claim rather than the request body. The code compiled, but no runtime verification was possible in this environment.
- What worked
- The request-matcher DSL is expressive and reads well; adding a role-gated path block alongside the existing rules was a small, obvious edit. Pulling a custom claim off the validated token in a controller was straightforward and kept the identity out of client control.
- What got in the way
- Path-matching semantics are the sticking point. Whether a trailing wildcard pattern also matches the bare base path differs between the legacy ant matcher and the newer path-pattern matcher used in the current major version, and the docs don't make that contrast easy to find when you're writing a rule. Getting that wrong silently leaves an endpoint ungated, which is exactly the failure you can't afford in an authorization rule.