MySQL Plugin
Rotate and Connect to MySQL databases with Keeper Commander
Prerequisites
Install PyMySQL
pip3 install -Iv PyMySQL==0.10.1Prepare Records for Rotation
Create a record to store the MySQL username and password
Create a record using either the Keeper Vault UI, or Keeper Commander.

Set the Host and Port of the record

If using an untyped record, the host and port can be set to custom fields. See below.
Set the login and password values to the current database user values

replace 'XXX' with the current database password for this user
Optional Custom Fields
cmdr:plugin
mysql
Tells Commander to use MySQL rotation. This should be either set to the record, or supplied to the rotation command
cmdr:host
Hostname of your MySQL server. This can be set here if not set in the record's host field
cmdr:rules
# uppercase, # lowercase, # numeric, # special'
(e.g. 4,6,3,8)
Password generation rules
cmdr:port
MySQL port. 3306 assumed if omitted This can be set here if not set in the record's host field
cmdr:user_host
User host. '%' assumed if omitted

For Commander versions greater than 4.88
For Commander versions 4.88 and before
Rotate Passwords
Get Record UID
Find the UID in the record information popup

Use the search command to find the UID for your record. Replace "MySQL Example" with the name of your record.
Perform Rotation
To rotate MySQL passwords, use the rotate command in Commander. Pass the command a record title or UID (or use --match with a regular expression to rotate several records at once)
Output
After rotation is completed, the new password will be stored in the Password field of the record
Integration with the Keeper Commander's connect command
connect:xxx:env:MYSQL_PWD
${password}
connect:xxx
mysql -u${login} -h${cmdr:host}
Here's a screenshot of the Keeper Vault record for this use case:

Last updated
Was this helpful?

