Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proxy logs violation for request with multiple or optional security schemes #141

Open
richjyoung opened this issue Oct 23, 2024 · 0 comments

Comments

@richjyoung
Copy link

This looks like the same issue as #80, except this affects the proxy mode rather than the mock server.

Given the following securitySchemes:

securitySchemes:
  Session:
    type: apiKey
    in: cookie
    name: session
  APIKey:
    type: apiKey
    in: header
    name: "X-API-Key"

In both of the following cases a request with the given security section will log a violation of "API Key X-API-Key not found in header":

# Optional security
security:
  - {}
  - APIKey: []

# Either Cookie or API Key security required
security:
  - Session: []
  - APIKey: []

No violation is logged for the cookie authentication which is present in the request in both cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant