mysql_db/user: Use password for my.cnf
According to the MySQL docs[0] the password should be stored after 'password=' instead of 'pass='. [0] http://dev.mysql.com/doc/refman/5.1/en/password-security-user.html
This commit is contained in:
parent
d5a236c53d
commit
2e904ae233
2 changed files with 2 additions and 2 deletions
2
mysql_db
2
mysql_db
|
@ -131,7 +131,7 @@ def load_mycnf():
|
||||||
return False
|
return False
|
||||||
try:
|
try:
|
||||||
config.readfp(open(mycnf))
|
config.readfp(open(mycnf))
|
||||||
creds = dict(user=config.get('client', 'user'),passwd=config.get('client', 'pass'))
|
creds = dict(user=config.get('client', 'user'),passwd=config.get('client', 'password'))
|
||||||
except (ConfigParser.NoOptionError, IOError):
|
except (ConfigParser.NoOptionError, IOError):
|
||||||
return False
|
return False
|
||||||
return creds
|
return creds
|
||||||
|
|
|
@ -230,7 +230,7 @@ def load_mycnf():
|
||||||
return False
|
return False
|
||||||
try:
|
try:
|
||||||
config.readfp(open(mycnf))
|
config.readfp(open(mycnf))
|
||||||
creds = dict(user=config.get('client', 'user'),password=config.get('client', 'pass'))
|
creds = dict(user=config.get('client', 'user'),password=config.get('client', 'password'))
|
||||||
except (ConfigParser.NoOptionError, IOError):
|
except (ConfigParser.NoOptionError, IOError):
|
||||||
return False
|
return False
|
||||||
return creds
|
return creds
|
||||||
|
|
Loading…
Reference in a new issue