From 0a0f8da2f4f8fac0e26ca43959c15ded39e93a06 Mon Sep 17 00:00:00 2001 From: yuri Date: Thu, 22 Oct 2015 10:41:07 +0300 Subject: [PATCH] fix auth for 5.5 --- application/Espo/Core/Utils/Api/Auth.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/application/Espo/Core/Utils/Api/Auth.php b/application/Espo/Core/Utils/Api/Auth.php index bb4e66c4e5..b49011b454 100644 --- a/application/Espo/Core/Utils/Api/Auth.php +++ b/application/Espo/Core/Utils/Api/Auth.php @@ -55,7 +55,10 @@ class Auth extends \Slim\Middleware } $espoCgiAuth = $req->headers('HTTP_ESPO_CGI_AUTH'); - if ( !isset($authUsername) && !isset($authPassword) && !empty($espoCgiAuth) ) { + if (empty($espoCgiAuth)) { + $espoCgiAuth = $req->headers('REDIRECT_HTTP_ESPO_CGI_AUTH'); + } + if (!isset($authUsername) && !isset($authPassword) && !empty($espoCgiAuth)) { list($authUsername, $authPassword) = explode(':' , base64_decode(substr($espoCgiAuth, 6))); }