[MDEV-6177] FR: Throw a warning if password line in cnf file contains hash character (#) Created: 2014-04-25 Updated: 2015-01-24 Resolved: 2015-01-24 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | OTHER |
| Fix Version/s: | N/A |
| Type: | Task | Priority: | Minor |
| Reporter: | Robert Voje | Assignee: | Unassigned |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | client, cnf, connection | ||
| Description |
|
When I have a # character in my password, and try to use a .cnf file for auto login, the parser seems to strip all characters after the hash in the cnf file. |
| Comments |
| Comment by Robert Voje [ 2014-04-25 ] | |||
|
Forgot to add example of my cnf file. Working: Not working: | |||
| Comment by Elena Stepanova [ 2014-04-26 ] | |||
|
As usually with valid yet not completely innocent symbols, enclosing the string into quotation marks solves the problem:
It is also explicitly documented in MySQL manual: https://dev.mysql.com/doc/refman/5.5/en/option-files.html
| |||
| Comment by Robert Voje [ 2014-04-26 ] | |||
|
Would be nice if it worked, but it doesn't. At least not my 10.0.10 server | |||
| Comment by Robert Voje [ 2014-04-26 ] | |||
|
Forgot to add correct host while testing. | |||
| Comment by Robert Voje [ 2014-04-26 ] | |||
|
It would be nice to be able to turn this bug into a feature request, but I can't find the way.. | |||
| Comment by Sergei Golubchik [ 2015-01-24 ] | |||
|
This is valid and documented behavior. MariaDB doesn't have any way to distinguish between an intentional comment or an unquoted hash character, so it has to rely on the user for that. |