amElnagdy / salt-shaker

Salt Shaker allows you to change WP security keys and salt manually and automatically.
https://nagdy.net/salt-shaker/
9 stars 3 forks source link

Create the temporary file with a .php extension #7

Closed ghost closed 7 years ago

ghost commented 7 years ago

After a mail discussion with @amElnagdy, we agreed on publishing PRs fixing the vulnerabilities left and get it quickly merged and deployed.

This will prevent the potential disclosure of the wp-config.php, since the temporary file is created with the extension .tmp and it may be served by the web server without being passed to the PHP interpreter.

This is a quick workaround to prevent disclosure, I'll rewrite the whole method sooner or later.