Re: [Exim] crypteq: Encryption type

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Philip Hazel
Dátum:  
Címzett: Jens Vonderheide
CC: exim-users
Tárgy: Re: [Exim] crypteq: Encryption type
On Thu, 29 Jun 2000, Jens Vonderheide wrote:

> I am using crypteq to compare a password against an MD5 hash in my database
> for AUTH SMTP. I am using the following command (without the DB lookup):
> server_condition = "\
>     ${if crypteq{$3}{\{md\}1a1dc91c907325c69271ddf0c944bc72} {1} {0} }"

>
> On each AUTH SMTP request, exim logs:
> Unable to authenticate at present: unknown encryption mechanism in "{md5"
>
> It seems that exim cuts away everything after \}, although it is quoted.
>
> Am I doing something wrong here or is this a bug in exim (v3.15)?


It's not quoted enough!

You have either to double those \ characters, or remove the enclosing "
from the string. The latter is easier. In 3.15 you can say

server_condition = \
    ${if crypteq{$3}{\{md\}1a1dc91c907325c69271ddf0c944bc72} {1} {0} }


Removing the " removes one level of quoting; because the arguments of
crypteq are pre-expanded, you need to quote at that level as well.

-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.