Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What kind of password encryption try postfix is used #21

Closed
lilongen1 opened this issue Jan 13, 2017 · 3 comments
Closed

What kind of password encryption try postfix is used #21

lilongen1 opened this issue Jan 13, 2017 · 3 comments
Labels

Comments

@lilongen1
Copy link

I wrote a change passwords in the roundcube plug-in, because don't know if postfix is use md5 encryption, so has been not modify the password and the system USES encryption mode matching.
thanks!

@lilongen1
Copy link
Author

lilongen1 commented Jan 13, 2017

I use this writing plus the {CRAM - MD5}
UPDATE mailbox SET password=CONCAT('{CRAM-MD5}',MD5(%q)) WHERE username=%u LIMIT 1
But save the string in the database after the new password encryption, namely {CRAM - MD5} behind, or not, because still can't login with new password in roundcube.

@cboltz
Copy link
Member

cboltz commented Jan 13, 2017

There's nothing like the encryption scheme.

You can choose which encryption scheme to use in the PostfixAdmin config ($CONF['encrypt']).

That said - I'd recommend not to modify the database manually. It's probably harmless when only changing the password (BTW - do you also update the 'modified' column and write something to the log table?), but it also means your plugin will need quite some code to handle the various encryption schemes.

PostfixAdmin comes with an xmlrpc interface which you might want to use.

@DavidGoodwin
Copy link
Member

The Squirrelmail plugin for Postfixadmin uses the XMLRPC interface to change the password. That way you don't have to worry about what hashing format is being used. The only downside is that you need to authenticate the end user with the xmlrpc interface - so you will probably need to ask them for their username/password in order to change it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants