How to hide password in configuration files

Is there a way to hide my password to access the database in the config.php configuration file?

What is the best way to do this?

I want to hide visitors and hosting admin :)

+3
source share
4 answers

You cannot hide them, because at some point they must be read by the application using it at runtime. Itโ€™s better to keep them safe so that they donโ€™t have the opportunity to be readable by anyone other than you (or authorized personnel).

, config.php html-, . website.com/config.php, , ( ). , PHP , , , , .

+10

.

- . , PHP-. , .

+4

, , , , . , , .

, , , , . ( Foxtrot).

+3

(. ), , , . , , , .

- , root-, .

+2

Source: https://habr.com/ru/post/1745472/


All Articles