[Exim] Plain authenticator.

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Guillermo Llenas
Ημερομηνία:  
Προς: exim-users
Αντικείμενο: [Exim] Plain authenticator.
This is a multi-part message in MIME format.
--
[ Picked text/plain from multipart/alternative ]

Hi,

    Is there any way to implement smtp authentication against a mysql
where the passwords are in plain (for example 1234) and in Md5 (for
example 59f2443a4317918ce29ad28a14e1bdb7).



    I must use this, for a plain password (pass 1234):


    server_condition = "${if and { \
                      {!eq{$1}{}} \
                      {!eq{$2}{}} \
                      {eq{$2}{${lookup mysql{SELECT password FROM users
\
                       WHERE username='${local_part:$1}' \
                       AND domainname='${domain:$1}'}{$value}fail}}} \
                     } {yes}{no}}"
 server_set_id = $1



        and for md5 stored password(59f2443a4317918ce29ad28a14e1bdb7)
this works fine:




server_condition = "${if and { \
                      {!eq{$1}{}} \
                      {!eq{$2}{}} \
                      {crypteq{$2}{\\{md5\\}${lookup mysql{SELECT
password FROM users \
                       WHERE username='${local_part:$1}' \
                       AND domainname='${domain:$1}'}{$value}fail}}} \
                     } {yes}{no}}"
 server_set_id = $1





            But the question is how integrate both of them in the exim
's config for the users,  don't matter in what format is stored the
password can sent mails ?




Guille.
--