Ticket #7361: 002-use-redirect_remote_user-for-authorization.patch

File 002-use-redirect_remote_user-for-authorization.patch, 602 bytes (added by yonosoytu, 4 years ago)

Enhancement to use REMOTE_USER/REDIRECT_REMOTE_USER for authentication.

  • wp-app.php

     
    10741074                if(isset($_SERVER['HTTP_AUTHORIZATION'])) { 
    10751075                        list($_SERVER['PHP_AUTH_USER'], $_SERVER['PHP_AUTH_PW']) = 
    10761076                                explode(':', base64_decode(substr($_SERVER['HTTP_AUTHORIZATION'], 6))); 
     1077                } else if (isset($_SERVER['REDIRECT_REMOTE_USER'])) { 
     1078                        list($_SERVER['PHP_AUTH_USER'], $_SERVER['PHP_AUTH_PW']) = 
     1079                                explode(':', base64_decode(substr($_SERVER['REDIRECT_REMOTE_USER'], 6))); 
    10771080                } 
    10781081 
    10791082                // If Basic Auth is working...