diff --git a/config.sample.inc.php b/config.sample.inc.php index eedd3b308..a0225b26d 100644 --- a/config.sample.inc.php +++ b/config.sample.inc.php @@ -54,7 +54,7 @@ $cfg['Servers'][$i]['bs_temp_log_threshold'] = ''; // $cfg['Servers'][$i]['history'] = 'pma_history'; // $cfg['Servers'][$i]['designer_coords'] = 'pma_designer_coords'; /* Contrib / Swekey authentication */ -// $cfg['Servers'][$i]['auth_swekey_config'] = './swekey.conf'; +// $cfg['Servers'][$i]['auth_swekey_config'] = '/etc/swekey-pma.conf'; /* * End of servers configuration diff --git a/contrib/swekey.sample.conf b/contrib/swekey.sample.conf index 2c7088079..8ef706a57 100644 --- a/contrib/swekey.sample.conf +++ b/contrib/swekey.sample.conf @@ -1,12 +1,12 @@ # This is a typical file used to enable Swekey hardware authentication. # # To activate the Swekey authentication add the following line in your config.inc.php file. -# $cfg['Servers'][$i]['auth_swekey_config'] = './swekey.conf'; -# Then rename this file "swekey.conf" and copy it next to your config.inc.php file. +# $cfg['Servers'][$i]['auth_swekey_config'] = '/etc/swekey-pma.conf'; +# Then rename this file "swekey-pma.conf" and copy it in the /etc directory. # Add all the Swekey ids you want to grant access to in the file. # After each Swekey id put the corresponding user. # -# If you don't know the id of a Swekey just go on the http://auth-sample.musbe.com +# If you don't know the id of a Swekey just go on the http://www.swekey.com?sel=support # page while your Swekey is connected. # # If you need to purchase a Swekey please visit http://phpmyadmin.net/auth_key @@ -17,8 +17,29 @@ 000000000000000000000000000089E4:steve 0000000000000000000000000000231E:scott -# You can also uncomment the following lines if you want to use custom authentication servers +# +# Include following lines if you want to use authentication servers in ssl mode. +# Authentication is slower but more secure. +# -#SERVER_CHECK=http://auth-check.musbe.net -#SERVER_RNDTOKEN=http://auth-rnd-gen.musbe.net -#SERVER_STATUS=http://auth-status.musbe.net +SERVER_CHECK=https://auth-check-ssl.musbe.net +SERVER_RNDTOKEN=https://auth-rnd-gen-ssl.musbe.net +SERVER_STATUS=https://auth-status-ssl.musbe.net + + + +# +# In case of you want to use https servers you can set the path of the root certificate file +# + +#CA_FILE=/var/http-root/phpmyadmin/libraries/auth/swekey/musbe-ca.crt + +# +# If your sever receive lot of login requests, you can enable the random token caching to +# accelerate the authentication process. +# This is disabled by default because the cache file having full public access is vulnerable to +# a deny of service attack. +# You can enable it when your server is running in a secure environment. +# + +#ENABLE_TOKEN_CACHE=1 \ No newline at end of file diff --git a/libraries/auth/cookie.auth.lib.php b/libraries/auth/cookie.auth.lib.php index e2e4af24c..b2fcd6d9a 100644 --- a/libraries/auth/cookie.auth.lib.php +++ b/libraries/auth/cookie.auth.lib.php @@ -221,32 +221,7 @@ if (top != self) { // use fieldset, don't show doc link PMA_select_language(true, false); } - - // BEGIN Swekey Integration - $swekeyErr = Swekey_auth_error(); - if ($swekeyErr != null) { - PMA_Message::error($swekeyErr)->display(); - if ($GLOBALS['error_handler']->hasDisplayErrors()) { - echo '