Re: [Exim] Interpreting Subject: lines - opinions, please

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Dr Andrew C Aitchison
Fecha:  
A: Philip Hazel
Cc: exim-users
Asunto: Re: [Exim] Interpreting Subject: lines - opinions, please
On Fri, 4 Jul 2003, Philip Hazel wrote:

> The problem:
>
> Exim does not interpret header lines that are encoded. Thus, for
> example, if a message contains the line
>
>     Subject: Internet caf?

>
> it might actually appear in the message as
>
>     Subject: =?iso-8859-1?Q?Internet_caf=E9?=

>
> This means that a user's filter file with a test such as
>
>     if $h_subject: contains "Internet caf?"

>
> won't work properly. Note that a string without any special characters
> could be encoded this way just to confuse things.


I have two questions I'd need answering.

1 What encoding is the match string using ?
We can specify the encoding for the whole config or filter file, or
we could invent a syntax such as:
    if $h_subject: contains $encoding{iso-8859-1}{"Internet caf?"}
which would allow the encoding of the match string.


2 The same subject line could also be encoded as (I think)
    Subject: =?UTF-8?Q?Internet_caf=C3=A9?=


Do we want your test to match both of these subject lines, or just one ?

----
Non-ASCII readers will be in a better position than me to judge;
can the average user put a string like "Internet caf?" into their
filter file with their favourite editor and have the result in an
unambiguous encoding ?
(I can't really remember when one of my editors uses iso-8859-1
and when it uses UTF-8. Sometimes I needed iso-8859-15 anyway)

--
Dr. Andrew C. Aitchison        Computer Officer, DPMMS, Cambridge
A.C.Aitchison@???    http://www.dpmms.cam.ac.uk/~werdna