Bug #43287 mysql user's password exposed through mysql administrator
Submitted: 1 Mar 12:57 Modified: 3 Dec 11:54
Reporter: josh haglund
Status: Verified
Category:MySQL Workbench Severity:S2 (Serious)
Version:5.1 OS:Linux (Ubuntu 8.10)
Assigned to: Alexander Musienko Target Version:WB52
Tags: password, root, Security, CHECKED
Triage: Triaged: D1 (Critical) / R3 (Medium) / E3 (Medium)

[1 Mar 12:57] josh haglund
Description:
A user running the MySQL Administrator can expose their mysql account's password to other
users/processes in a system.

The problem is that the full connection info (with user/pass) is passed as an argument to
the terminal window used to start the MySQL Text Console.

When the MySQL Text Console is open, any user who can run ps can see the complete
connection information used to log into MySQL Administrator.

How to repeat:
Connect to a server using MySQL Administrator
Open 'Tools->MySQL Text Console'
Open a terminal window
 ~$ ps aux | grep mysql

and you will see a terminal process with all the connection info

Suggested fix:
write the mysql password to a temp file with permissions denying all but the current user
read/write.

Then initiate the terminal process feeding the password in as a file path argument -- in
the mysql argument list, after -p, instead of entering the password, put `cat
/path/to/tmp/file/with/pass`

then cleanup -- delete the password file after successfully logging into mysql
[1 Mar 13:02] josh haglund
On second thought, that suggested fix won't work.  pass would still be exposed.
[3 Mar 12:51] Susanne Ebrecht
Many thanks for writing a bug report. Because we are on the way to implement full
functionality of MySQL Administrator into MySQL Workbench we won't fix this anymore in
MySQL Administrator.

But you hint is very important for MySQL Workbench as well. 

So I will change category here and will test if our workbench release will be affected
too.
[19 Oct 9:04] Susanne Ebrecht
I will look if this still is true for Workbench 5.2