Opened 11 years ago

Closed 11 years ago

#578 closed enhancement (invalid)

[patch] automatically do MD5 in admin backend

Reported by: Hein-Pieter van Braam <hp@…> Owned by: Adrian Holovaty
Component: contrib.admin Version:
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

can perhaps close #61, but that depends if this satisfies its requirements.

This patchs adds auto md5 encryption to the admin backend, it doesn't change anything else, so it's not 'good' yet, but its better.

I am lookin to implement a meta.PasswordField which would automagically do the md5crypt and display 2 password boxes through HTML.

this is a temporal workaround.

Attachments (2)

auto_admin_md5.diff (2.3 KB) - added by Hein-Pieter van Braam <hp@…> 11 years ago.
auto_admin_md5_fixed.diff (2.0 KB) - added by Hein-Pieter van Braam <hp@…> 11 years ago.

Download all attachments as: .zip

Change History (6)

Changed 11 years ago by Hein-Pieter van Braam <hp@…>

Attachment: auto_admin_md5.diff added

comment:1 Changed 11 years ago by Hein-Pieter van Braam <hp@…>

BTW, this changes api.

once you create a user object through users.create.user() you need to explicitly .save() it. I think this is OK, because all throughout the api this is also the case. I think user was the only exception.

feel free to comment ;) (or flame)

comment:2 Changed 11 years ago by Adrian Holovaty

Resolution: invalid
Status: newclosed

This isn't a great solution, because it calculates the MD5 each time the object is saved. That means, if you create an object, save it, retrieve it and save it again, it will have calculated the MD5 of the MD5.

Changed 11 years ago by Hein-Pieter van Braam <hp@…>

Attachment: auto_admin_md5_fixed.diff added

comment:3 Changed 11 years ago by Hein-Pieter van Braam <hp@…>

Resolution: invalid
Status: closedreopened

OK, I think I fixed that issue.

comment:4 Changed 11 years ago by Adrian Holovaty

Resolution: invalid
Status: reopenedclosed

No, the issue isn't fixed. The following will never be true:

password_md5 == md5.new(password_md5).hexdigest()

I don't see this patch as an improvement, so I'm closing this ticket again.

Note: See TracTickets for help on using tickets.
Back to Top