Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can anyone confirm that phpMyAdmin AllowNoPassword works with MySQL databases?

I have a version of phpMyAdmin located on my local Apache server.

I am trying to login without a password however phpMyAdmin keeps throwing the warning:

Login without a password is forbidden by configuration (see AllowNoPassword)

However in my config.php file for phpMyAdmin I have set:

$cfg['Servers'][$i]['AllowNoPassword'] = TRUE; 

So I don't know why the message is still appearing.

like image 775
diggersworld Avatar asked May 06 '11 08:05

diggersworld


People also ask

Is MySQL required for phpMyAdmin?

No. To use phpMyAdmin, you'll need a client (your local web browser), a web server, and a MySQL instance -- and those three can exist in any combination that works for you.

What databases does phpMyAdmin support?

Backup formats phpMyAdmin allows to take database backups in various formats like XML, CSV, SQL, PDF, OpenDocument Text, Excel, Word, and Spreadsheet, etc.

Should phpMyAdmin be publicly accessible?

phpmyadmin is too much of a beast to secure. You'd need mod_security and a week of time debugging the alerts just to disable half of the rules to ensure the functionality of phpmyadmin. Conclusion: Don't make it publicly accessible.


2 Answers

  1. Copy config.sample.inc.php to config.inc.php.

    In most cases you will find the config file

    • on linux: /etc/phpmyadmin/config.inc.php
    • on mac: /Library/WebServer/Documents/phpmyadmin/config.inc.php
  2. If you are trying to log in as root, you should have the following lines in your config:

    $cfg['Servers'][$i]['user'] = 'root';
    $cfg['Servers'][$i]['AllowNoPassword'] = true;

like image 177
DondeEstaMiCulo Avatar answered Sep 23 '22 13:09

DondeEstaMiCulo


According to this: https://www.simplified.guide/phpmyadmin/enable-login-without-password

This $cfg['Servers'][$i]['AllowNoPassword'] = TRUE; should be added twice in /etc/phpmyadmin/config.inc.php

if (!empty($dbname)) {     // other configuration options     $cfg['Servers'][$i]['AllowNoPassword'] = TRUE;     // it should be placed before the following line     $i++; }  // other configuration options $cfg['Servers'][$i]['AllowNoPassword'] = TRUE; 
like image 32
Malintha Avatar answered Sep 25 '22 13:09

Malintha