Warning: Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.

Ticket #1254 (closed enhancement: fixed)

Opened 12 years ago

Last modified 12 years ago

Support for user defined encryption algorithms

Reported by: renier Owned by: jtate
Priority: normal Milestone: 1.0.3
Component: Identity Version: 1.0
Severity: normal Keywords:
Cc:

Description

When creating a data model based on a database(s) that already exists, including user accounts, encryption algorithms will vary beyond md5 or sha1. In this situation, it would be ideal to let the user define his/her own encryption algorithm.

This could be configured in app.cfg with: identity.soprovider.encryption_algorithm = 'custom' identity.soprovider.custom_encryption = '${package}.model.encrypt_password'

The patch to soprovider.py that enables this is attached. Similar changes would be needed to other identity providers (e.g. saprovider.py).

Attachments

soprovider.py.custom_encryption.diff Download (1.1 KB) - added by renier 12 years ago.
__init__.py.custom_encryption.diff Download (1.2 KB) - added by renier 12 years ago.
Patch to add custom encrypt_password algorithm option

Change History

Changed 12 years ago by renier

comment:1 Changed 12 years ago by elvelind

  • Owner changed from anonymous to elvelind

comment:2 Changed 12 years ago by alberto

It would be nice if this enhancement also affected saprovider. Probably some refactoring is needed as both providers a duplicating too much code IMO.

Alberto

comment:3 Changed 12 years ago by alberto

  • Milestone changed from 1.0.2 to 1.0.3

comment:4 Changed 12 years ago by renier

The patch attached doesn't apply anymore as of 1.0.2.

comment:5 Changed 12 years ago by renier

I'm attaching a patch that works now for 1.0.2. Also, because of the decoupling of the encrypt_password from the specific providers, this patch works for any identity providers.

I think this ticket is now in a state that can be closed, after the patched is reviewed.

Changed 12 years ago by renier

Patch to add custom encrypt_password algorithm option

comment:6 Changed 12 years ago by renier

Forgot to add that a change from the ticket description above is that you can now say in the configuration: identity.custom_encryption = '${package}.model.encrypt_password'

instead of: identity.soprovider.custom_encryption = '${package}.model.encrypt_password'

comment:7 Changed 12 years ago by renier

  • Owner changed from elvelind to jtate
  • Component changed from unassigned to Identity

comment:8 Changed 12 years ago by renier

  • Status changed from new to closed
  • Resolution set to fixed
Note: See TracTickets for help on using tickets.