Virtual Users And Domains With Postfix, Courier, MySQL And SquirrelMail (MD5?)

Discussion in 'HOWTO-Related Questions' started by emo0boy, Mar 1, 2011.

  1. emo0boy

    emo0boy New Member

    Hi!

    First sorry for my english :)

    I've made a mail server exactly like in this tutorial:
    http://www.howtoforge.com/virtual-users-and-domains-with-postfix-courier-mysql-and-squirrelmail-ubuntu-10.10

    Everything works great. My next task is to import into database from another database over 200 accounts. I can write a script to do that, problem is that passwords in old database are md5 crypted and in new database (from tutorial) passwords are crypted with Unix crypt.

    My question is: is there any solution how to change configuration from tutorial to use md5 crypted passwords from database?

    Thanks for any help.

    EDIT

    So I have a user with MD5 crypted password. I force SMTP to use MD5 crypted password by changing /etc/pam.d/smtp

    from:
    Code:
    auth    required   pam_mysql.so user=mail_admin passwd=mail_admin_password host=127.0.0.1 db=mail table=users usercolumn=email passwdcolumn=password crypt=1
    account sufficient pam_mysql.so user=mail_admin passwd=mail_admin_password host=127.0.0.1 db=mail table=users usercolumn=email passwdcolumn=password crypt=1
    to:
    Code:
    auth    required   pam_mysql.so user=mail_admin passwd=mail_admin_password host=127.0.0.1 db=mail table=users usercolumn=email passwdcolumn=password crypt=3
    account sufficient pam_mysql.so user=mail_admin passwd=mail_admin_password host=127.0.0.1 db=mail table=users usercolumn=email passwdcolumn=password crypt=3
    and sending mail works OK, but then I can't get any mail because POP3 auth error. I tried paste the same code to /etc/pam.d/pop3 but no effect still POP3 auth error.

    So the question is now: how to force POP3 to use MD5 crypted passwords form MySQL database?
     
    Last edited: Mar 1, 2011

Share This Page