mirror of
https://gitlab.com/davical-project/davical.git
synced 2026-11-29 08:56:03 +00:00
RFC compliant CGI AUTH_TYPE usage
* Handle the content of the CGI AUTH_TYPE variable case-insensitively as defined by RFC 3875 Section 4.1.1.
This commit is contained in:
1 parent
c092a6153e
commit
82757beba4
3 files changed
+7
-3
No files matched your search
@@ -114,10 +114,10 @@ class HTTPAuthSession {
|
||||
else if ( isset($c->authenticate_hook['server_auth_type'])
|
||||
&& isset($_SERVER['REMOTE_USER']) && !empty($_SERVER['REMOTE_USER'])) {
|
||||
if ( ( is_array($c->authenticate_hook['server_auth_type'])
|
||||
&& in_array($_SERVER['AUTH_TYPE'], $c->authenticate_hook['server_auth_type']) )
|
||||
&& in_array( strtolower($_SERVER['AUTH_TYPE']), array_map('strtolower', $c->authenticate_hook['server_auth_type'])) )
|
||||
||
|
||||
( !is_array($c->authenticate_hook['server_auth_type'])
|
||||
&& $c->authenticate_hook['server_auth_type'] == $_SERVER['AUTH_TYPE'] )
|
||||
&& strtolower($c->authenticate_hook['server_auth_type']) == strtolower($_SERVER['AUTH_TYPE']) )
|
||||
) {
|
||||
/**
|
||||
* The authentication has happened in the server, and we should accept it.
|
||||
|
||||
Reference in new issue
Block a user