You've already forked oauth2-proxy
mirror of
https://github.com/oauth2-proxy/oauth2-proxy.git
synced 2025-08-08 22:46:33 +02:00
Add API route config (#1760)
* Add API route config In addition to requests with Accept header `application/json` return 401 instead of 302 to login page on requests matching API paths regex. * Update changelog * Refactor * Remove unnecessary comment * Reorder checks * Lint Api -> API Co-authored-by: Sebastian Halder <sebastian.halder@boehringer-ingelheim.com>
This commit is contained in:
@ -25,6 +25,7 @@ func Validate(o *options.Options) error {
|
||||
msgs = append(msgs, prefixValues("injectRequestHeaders: ", validateHeaders(o.InjectRequestHeaders)...)...)
|
||||
msgs = append(msgs, prefixValues("injectResponseHeaders: ", validateHeaders(o.InjectResponseHeaders)...)...)
|
||||
msgs = append(msgs, validateProviders(o)...)
|
||||
msgs = append(msgs, validateAPIRoutes(o)...)
|
||||
msgs = configureLogger(o.Logging, msgs)
|
||||
msgs = parseSignatureKey(o, msgs)
|
||||
|
||||
|
Reference in New Issue
Block a user