On Sun, Feb 13, 2005 at 10:00:44AM +0000, Brian Candler wrote:
I trust you have noticed that authmysqlrc has a section labelled
"MYSQL_CHPASS_CLAUSE:0" which is COMMENTED OUT in the default configuration.
That means you have to do some work yourself to make password changing
happen, by writing a SQL clause which is appropriate to your particular
database schema.
I've just checked the source. To be more precise, if you leave this item
commented out, then a default update query will be sent, something along the
lines of:
UPDATE <MYSQL_USER_TABLE> SET
<MYSQL_CLEAR_PWFIELD>='newpass', -- if MYSQL_CLEAR_PWFIELD set
<MYSQL_CRYPT_PWFIELD>='cryptedpass' -- if MYSQL_CRYPT_PWFIELD set
WHERE <MYSQL_LOGIN_FIELD or id>='userame'
AND <MYSQL_WHERE_CLAUSE> -- if MYSQL_WHERE_CLAUSE set
Turning on authentication debugging should show exactly what it sends, and
therefore whether there is a problem with the code or with your authmysql
configuration.
I can see one potential problem - there may be a spurious comma in the query
if you are using MYSQL_CLEAR_PWFIELD without MYSQL_CRYPT_PWFIELD.
Brian.