Skip to content

Exclude paths from security when using quarkus-oidc #14001

@codependent

Description

@codependent

Description
I'm using Quarkus 1.10.5 with the quarkus-oidc component to enforce the validation of a JWT token. This application is playing the role of a sidecar container that simply validates this security requirement and forwards the request to the next container.

The point is I need to exclude some paths from the oidc validation. On Stackoverflow I was pointed at this documentation resource: https://quarkus.io/guides/security-authorization#matching-on-paths-methods

My full configuration is as follows:

quarkus:
  http:
    port: 8081
    cors: false
    auth:
      permission:
        permit1:
          policy: permit
          paths: /api/public/*
  oidc:
    auth-server-url: ${keycloak.auth-server-url}/realms/${keycloak.realm}
    client-id: XXX
  ssl:
    native: true
  native:
    enable-https-url-handler: true
  log:
    console:
      enable: true
      level: DEBUG

The problem is quarkus.http.auth.permission.permit1.* configuration seems to be ignored, and I keep getting 401 on public paths.

Could you add support for excluding paths from the oidc validation?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions