xcat2 / xcat-extensions

Repos to store scripts for special user cases
4 stars 8 forks source link

xcatha.py set up weak password for database access by default #25

Open neo954 opened 6 years ago

neo954 commented 6 years ago

This bug is against xcatha.py commit 6e4c13e9227f86372b5333947f58e3dbe6281213.

When the end user choose to use xcatha.py -s to set up his/her xCAT management with MariaDB or PostgreSQL database, the script xcatha.py with use a plain word cluster as the database password. I believe this behavior is improper, and may lead the security problem.

I suggest use a random and strong word as the database password. And it will be write to xCAT configuration file /etc/xcat/cfgloc. This will be much better.

xcatdb_password={'XCATPGPW':'cluster','XCATMYSQLADMIN_PW':'cluster','XCATMYSQLROOT_PW':'cluster'}
neo954 commented 6 years ago

Refer to xcat2/xcat2-task-management#163

bybai commented 6 years ago

The pr is low.