Author Topic: Any 0.3.1 Mysql password changer?  (Read 10304 times)

Offline kknddandy

  • Newbie
  • *
  • Posts: 4
Any 0.3.1 Mysql password changer?
« on: January 24, 2010, 12:59:36 PM »
Hi all,

I am newbie here, just tried to install roundcube on my server, I used postfix + mysql to create virual domain and users.

Is there any plugin available for the 0.3.1 version?

thx

Offline JohnDoh

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2,850
Any 0.3.1 Mysql password changer?
« Reply #1 on: January 24, 2010, 01:59:27 PM »
There is a password plugin which ships with 0.3.1, it supports changing passwords in sql.
« Last Edit: January 25, 2010, 12:53:59 AM by rosali »
Roundcube Plugins: Contextmenu, SpamAssassin Prefs, and moreā€¦

Offline kknddandy

  • Newbie
  • *
  • Posts: 4
Any 0.3.1 Mysql password changer?
« Reply #2 on: January 28, 2010, 12:14:35 AM »
Hi, the password plugin is cool, and it could change the password, but the problem is the password stored in my database was encrypted in md5crypt format, and the password seem encrypt the password in DES, I guess, the encrypted password are shorter than original one.
    So, once the user changed their password in roundcube, roundcube could not send any mail any more, cuz the password is in different format I guess.

    Is there any way to make the plugin encrypt password into md5crypt format? Thanks!!!

Online SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,879
    • SKaero - Custom Roundcube development
Any 0.3.1 Mysql password changer?
« Reply #3 on: January 28, 2010, 01:17:17 AM »
I think they are encoded with md5 but there salted, just modify the sql driver to get it to mach your database.

Offline kknddandy

  • Newbie
  • *
  • Posts: 4
Any 0.3.1 Mysql password changer?
« Reply #4 on: January 28, 2010, 02:16:27 AM »
Thanks.



i tried to modify config.php.inc , to be like this
$rcmail_config['password_query'] = "UPDATE mailbox SET password = %c, modified=now() WHERE username = %u LIMIT 1;";
the password in database is now in format "$1$", but just something wrong,


I checked the drivers/sql.php, but it is really too hard for me, I don't know which line should be modified.

I used posfixadmin to create mailbox also the encrypted password, will you give me a little help on this?

Online SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,879
    • SKaero - Custom Roundcube development
Any 0.3.1 Mysql password changer?
« Reply #5 on: January 28, 2010, 02:34:50 AM »
Quote from: kknddandy;24967
Thanks.



i tried to modify config.php.inc , to be like this
$rcmail_config['password_query'] = "UPDATE mailbox SET password = %c, modified=now() WHERE username = %u LIMIT 1;";
the password in database is now in format "$1$", but just something wrong,


I checked the drivers/sql.php, but it is really too hard for me, I don't know which line should be modified.

I used posfixadmin to create mailbox also the encrypted password, will you give me a little help on this?

If you just need to be encoded with MD5 do:
$rcmail_config['password_query'] = "UPDATE mailbox SET password = md5(%p), modified=now() WHERE username = %u LIMIT 1;";

Offline kknddandy

  • Newbie
  • *
  • Posts: 4
Any 0.3.1 Mysql password changer?
« Reply #6 on: January 28, 2010, 03:17:25 AM »
Hi , Thanks for replying me so quick.

er.... the password created by postfix admin was encrypted in MD5CRYPT format
but the dovecot can read it, also can smtp it, the setting in dovecot is MD5-CRYPT

So the password must be encrypted in MD5crypt format not MD5 check sum.

Online SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,879
    • SKaero - Custom Roundcube development
Any 0.3.1 Mysql password changer?
« Reply #7 on: January 28, 2010, 03:42:29 AM »
Ah, I don't know as much about MD5-CRYPT, I don't see what wrong with the
Code: [Select]
$rcmail_config['password_query'] = "UPDATE mailbox SET password = %c, modified=now() WHERE username = %u LIMIT 1;"; Do you have a custom salt?

Offline Martian

  • Jr. Member
  • **
  • Posts: 35
Any 0.3.1 Mysql password changer?
« Reply #8 on: February 02, 2010, 09:16:47 AM »
You can change the password encryption format in both postfixadmin and dovecot.  Most SASL formats are supported by both programs.  I think MD5-Crypt is a Dovecot specific thing but I could be wrong.  The key will be finding one that Postfixadmin, Dovecot, and Roundcube can all understand.

I would recommend trying CRAM-MD5.  I know for a fact both Postfixadmin and Dovecot can handle that.  Perhaps Skaero will know how to use CRAM-MD5 in Roundcube.

Martian

Offline sasi

  • Jr. Member
  • **
  • Posts: 17
Any 0.3.1 Mysql password changer?
« Reply #9 on: August 02, 2010, 02:11:41 AM »
Quote from: kknddandy;24964
Hi, the password plugin is cool, and it could change the password, but the problem is the password stored in my database was encrypted in md5crypt format, and the password seem encrypt the password in DES, I guess, the encrypted password are shorter than original one.
    So, once the user changed their password in roundcube, roundcube could not send any mail any more, cuz the password is in different format I guess.

    Is there any way to make the plugin encrypt password into md5crypt format? Thanks!!!


HI KKnddandy,
     
              can you please explain how to enable the password plugin in roundcube 0.3.1

waqarhassan41

  • Guest
Any 0.3.1 Mysql password changer?
« Reply #10 on: August 06, 2010, 03:14:13 AM »
Very nice post thanks dear friends thanks agian
Webmaster Forum  Free software

Offline d3v4

  • Newbie
  • *
  • Posts: 1
Any 0.3.1 Mysql password changer?
« Reply #11 on: March 17, 2011, 01:05:45 AM »
Quote from: kknddandy;24967
Thanks.



i tried to modify config.php.inc , to be like this
$rcmail_config['password_query'] = "UPDATE mailbox SET password = %c, modified=now() WHERE username = %u LIMIT 1;";
the password in database is now in format "$1$", but just something wrong,


I checked the drivers/sql.php, but it is really too hard for me, I don't know which line should be modified.

I used posfixadmin to create mailbox also the encrypted password, will you give me a little help on this?


i'm using a little difference from your code
Code: [Select]

$rcmail_config['password_query'] = 'UPDATE mailbox SET password = %c, modified=now() WHERE username = %u LIMIT 1';


worked like a charm, thank you..............