Skip to content


Subversion checkout URL

You can clone with
Download ZIP


Add plugin hook to set/modify database connection info #2870

anonymous-piwik-user opened this Issue · 5 comments

2 participants


You can find the datebase password in the config.ini.php.

Can you pls let piwik encrypt this password?

Thanks =)


we don't encrypt because MySQL requires a plaintext password for the connection. The file is protected by .htaccess and .php extension, so it can't be displayed by direct access or local file inclusion.

To decrypt on every php request would add some performance overhead. Also, the question then becomes where to securely store the decryption key?

We could also try allowing the connection info to be set via environment variables (eg in your virtualhost.config), but the password is still physically stored somewhere.


Attachment: patch to use environment variables


(In [5681]) refs #2870 - add a hook for plugins (or third party integration) to set database config before connection is made


(In [5686]) refs #2870

@anonymous-piwik-user anonymous-piwik-user added this to the 1.7 Piwik 1.7 milestone
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.