Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing blowfish_secret length (too short) [phpMyAdmin] #1841

Merged
merged 4 commits into from Mar 23, 2019
Merged

Fixing blowfish_secret length (too short) [phpMyAdmin] #1841

merged 4 commits into from Mar 23, 2019

Conversation

lukapaunovic
Copy link
Contributor

@lukapaunovic lukapaunovic commented Mar 21, 2019

Fixing blowfish_secret length (too short) if not longer phpMyAdmin shows a warning:

The secret passphrase in configuration (blowfish_secret) is too short.

Luka Paunović added 2 commits March 21, 2019 16:50
phpMyAdmin "screams", we should be using length of 32 characters for blowfish_secret.
Fixing blowfish_secret length (too short)
Copy link
Collaborator

@anton-reutov anton-reutov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not working for CentOS 6

@lukapaunovic
Copy link
Contributor Author

lukapaunovic commented Mar 21, 2019

Not working for CentOS 6

What's not working? This fix will solve the problem only for new installations, I edited install scripts.
To fix it for existing, blowfish secret needs to be manually updated with 32long string in /etc/phpMyAdmin/config.inc.php

@anton-reutov
Copy link
Collaborator

Not working for CentOS 6

What's not working?

The configuration file now needs a secret passphrase (blowfish_secret)
config.inc.php
$cfg['blowfish_secret'] = '%blowfish_secret%'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */

Luka Paunović added 2 commits March 21, 2019 21:25
Copy link
Contributor Author

@lukapaunovic lukapaunovic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, fixed :)

@anton-reutov
Copy link
Collaborator

Ok, i will check it again )

@anton-reutov
Copy link
Collaborator

anton-reutov commented Mar 22, 2019

Sorry, not working for CentOS 6, but working if blowfish_secret to specify in this file /usr/share/phpMyAdmin/libraries/config.default.php
i don't see any problems in there /usr/share/phpMyAdmin/libraries/vendor_config.php
it's strange, maybe problem with chown for this file /etc/phpMyAdmin/config.inc.php , but not sure.

@anton-reutov anton-reutov self-requested a review March 22, 2019 12:10
@lukapaunovic
Copy link
Contributor Author

lukapaunovic commented Mar 22, 2019

I found the issue

define('CONFIG_DIR', '');
in /usr/share/phpMyAdmin/libraries/vendor_config.php
should be
define('CONFIG_DIR', '/etc/phpMyAdmin/');

When it's blank it's not loading /etc/phpMyAdmin/config.inc.php at all..

Please define, and you'll see warning disappeared.

Now we know what needs to be fixed for this patch to work properly. This fix I requested pull for is still needed as gen_pass is generating too short string to be used as blowfish_secret.

EDIT: I just checked /usr/share/phpMyAdmin/libraries/vendor_config.php at servers I recently installed, and I discovered variable is defined, so it must be a bug related to certain OS version, this was latest centos 7 64 bit.

@anton-reutov anton-reutov merged commit 2bde9c6 into outroll:master Mar 23, 2019
@anton-reutov
Copy link
Collaborator

Thank you for your help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants