From 0334facc2ecdc80fac41634c51c0819d98c4a667 Mon Sep 17 00:00:00 2001 From: Dennis Hermsmeier Date: Fri, 31 Jul 2020 16:49:51 +0200 Subject: [PATCH] finally fix auth struggle --- auth/rest.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/auth/rest.go b/auth/rest.go index 618930f..e397f60 100644 --- a/auth/rest.go +++ b/auth/rest.go @@ -99,7 +99,9 @@ func (a *RestAuthDecorator) DecorateHandler(orig httprouter.Handle, appName stri return } - if cfg.Authentication.ProviderConfig.Service == appName { + if cfg.Authentication.ProviderConfig.Service == appName || + (cfg.Applications[appName].Backend.Url != "" && cfg.Authentication.ProviderConfig.Url != "" && + cfg.Applications[appName].Backend.Url == cfg.Authentication.ProviderConfig.Url) { goto valid }