| 310 | |
| 311 | == Changed field name and length for auth.User password_md5 field == |
| 312 | |
| 313 | As of an upcoming change, the {{{password_md5}}} field in the {{{auth.User}}} model, which is used for authentication in the Django admin, was renamed to {{{password}}}, and its length was changed from 32 to 128 to accomodate longer hashes and password metadata, such as which hash algorithm to use. This affects everybody who uses the Django authentication system -- including users of the Django admin. |
| 314 | |
| 315 | Execute the following SQL to restore auth functionality: |
| 316 | |
| 317 | {{{ |
| 318 | BEGIN; |
| 319 | ALTER TABLE auth_users ADD COLUMN password varchar(128); |
| 320 | UPDATE auth_users SET password = password_md5; |
| 321 | ALTER TABLE auth_users ALTER COLUMN password SET NOT NULL; |
| 322 | ALTER TABLE auth_users DROP COLUMN password_md5; |
| 323 | COMMIT; |
| 324 | }}} |