Disable security for one operation
See original GitHub issueHi,
I have a @OpenAPIDefinition
with security defined for the whole app, but I want to override and disable security for one method, how can I do that?
Using @Operation(security = {})
on the method doesn’t seem to work.
Expected output in yaml is security: []
for that one operation.
Thanks
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:7 (2 by maintainers)
Top Results From Across the Web
Swagger: disabling security on one particular path
Is there some way I can disable security on just ONE particular Path or Method? rest · swagger · Share.
Read more >How to disable WebSphere Global Security for one ... - IBM
Go to "Application Servers" · Select the appropriate server · Select "Server security" · Select "Server level security" · Uncheck the "Enable global ......
Read more >Disabling and enabling individual controls - AWS Security Hub
From the Security Hub console, you can disable controls from the control list on the standard details page or from the control details...
Read more >Disable Security in IBM WebSphere Application Server
You forget the credential · Someone changed the password · Messed up the SSL/Security configuration or security.xml.
Read more >Disable Security System - Armored Core Wiki - Fandom
Disable Security System is a mission in Armored Core 3. Requester: Union Advance: 0 Upon success: 51000 Operation Area: Crest's Data Storage Facility...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi,
I came across this issue recently. I found a workaround using OpenApiCustomiser, but I would prefer a proper solution. I think it is doable without changes to the swagger-core annotations (not with the Operation annotation, but with an ‘empty’ SecurityRequirements). It would look like this:
It doesn’t work out of the box, there are some changes needed in the SecurityParser Would you mind if I sent you a PR?
Yeah @mafor, i wasn’t sure about your feedback. Anyway, the important is that its now shared with the community.