HTTP authentication mode ΒΆ
-
Uses HTTP Basic authentication method and allows you to log in as any valid MySQL user.
-
Is supported with most PHP configurations. For IIS (ISAPI) support using CGI PHP see 1.32 Can I use HTTP authentication with IIS?, for using with Apache CGI see 1.35 Can I use HTTP authentication with Apache CGI?.
-
When PHP is running under Apache's mod_proxy_fcgi (e.g. with PHP-FPM),
Authorization
headers are not passed to the underlying FCGI application, such that your credentials will not reach the application. In this case, you can add the following configuration directive:SetEnvIf Authorization "(.*)" HTTP_AUTHORIZATION=$1
-
See also 4.4 phpMyAdmin always gives "Access denied" when using HTTP authentication. about not using the .htaccess mechanism along with 'HTTP' authentication mode.
Note
There is no way to do proper logout in HTTP authentication, most browsers will remember credentials until there is no different successful authentication. Because of this, this method has a limitation that you can not login with the same user after logout.