Skip to content

Enforce @RolesAllowed / @PermitAll / @DenyAll annotation coverage at service startup #5742

Closed

Description

@Ma77Ball

Task Summary

Follow-up to #5199 / #5301. The microservices register RolesAllowedDynamicFeature, which enforces @RolesAllowed only when it is present; an HTTP-mapped resource method with no @RolesAllowed/@PermitAll/@DenyAll (and no class-level equivalent) is silently public, and the *RunSpec mock tests only verify the feature is registered, so a newly added method that forgot a role annotation passes CI unnoticed. Add a startup-time check that scans every Jersey resource registered on environment.jersey() and asserts every HTTP-mapped method (@GET/@POST/@PUT/@DELETE/@PATCH/@HEAD/@OPTIONS) carries one of @RolesAllowed/@PermitAll/@DenyAll (taking class-level annotations into account), failing fast (log + throw) if any method is unannotated. Scope is the five microservices from #5199 (config, access-control, computing-unit-managing, workflow-compiling, file); amber is out of scope because its pre-existing endpoints are not all annotated yet.

Task Type

  • DevOps / Deployment / CI

Activity

  1. added theissue type on Jun 16, 2026
  2. added a commit that references this issue on Jun 25, 2026
    71fce70
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions