[imapfilter-devel] filtering :(((
Lefteris Chatzibarbas
lefcha at hellug.gr
Thu Jul 3 22:01:11 EEST 2003
On Mon, Jun 30, 2003 at 10:34:25AM +0600, Igor Klingen wrote:
> Hi All!
>
> I have following difficulty.
> I use Courier Imap v1.7.1 and imapfilter v0.8.9.
> Post messages get in INBOX some box.
> All fields of messages coded on RFC 1522 will be
> transformed to a form =?UTF-8?Q?...? =.
> For a filtration I use a part of a field 'From'
> and a part of a field 'Subject'.
> ( Names of folders are written by russian,
> therefore Courier Imap creates them in coding UTF-7):
>
> ----- imapfilterrc ---------------------------------------------------
> ...
> filter sort-subscribe-ems-1c and
> mask from ems.ru
> mask subject "=D0=9D=D0=BE=D0=B2=D0=BE=D1=81=D1=82=D0=B8 EMS | 1C:"
> action move &BB8EPgQ0BD8EOARBBDoEMA-/EMS 1C
> ...
> ----------------------------------------------------------------------
>
> In INBOX there is some letter with heading:
>
> ----- message in INBOX -----------------------------------------------
> ...
> Subject: =?UTF-8?Q?19.06.2003|
> =D0=9D=D0=BE=D0=B2=D0=BE=D1=81=D1=82=D0=B8 EMS | 1C:
> =D0=90=D0=B2=D1=82=D0=BE=D0=BC=D0=B0=D1=82=D0=B8=D0=B7=D0=B0=D1=86=D0=B8=D1=8F?=
> MIME-Version: 1.0
> Content-Type: multipart/mixed; boundary="=_71d770d162e31d25e4eff1f0601d99cc"
> From: webmaster at ems.ru
> ...
> ----------------------------------------------------------------------
>
> The report of an output imapfilter:
>
> ----- imapfilter -v ... ----------------------------------------------
> ...
> debug: FILTER: 'sort-subscribe-ems-1c' AND
> debug: MASK: 'FROM "ems.ru"'
> debug: MASK: 'SUBJECT "=D0=9D=D0=BE=D0=B2=D0=BE=D1=81=D1=82=D0=B8 EMS |
> 1C:"'
> debug: ACTION: 3 '' '&BB8EPgQ0BD8EOARBBDoEMA-/EMS' 0 '1C'
> ...
> Client request: SEARCH
> debug: sending command: F00006 SEARCH ALL FROM "ems.ru" SUBJECT
> "=D0=9D=D0=BE=D0=B2=D0=BE=D1=81=D1=82=D0=B8 EMS | 1C:"
>
> * SEARCH
> F00006 OK SEARCH done.
>
> Server response: OK SEARCH done.
> ...
> ----------------------------------------------------------------------
>
>
> QUESTIONS:
> 1) Why the filter does not find the letter?
With the CVS version of imapfilter (it supports the "charset" IMAP4rev1
parameter while searching) and using UTF8 as the charset, I was able to
succesfully filter a message with english, greek polytonic, russian and
german characters (I used a Unicode editor to compose the message and
create imapfilter's config file). The mail server must also support
other charsets than ASCII in order to do this. I don't know if trying
the CVS version with UTF8 as charset, will be of any help, though.
I can't really tell why the filter fails (i18n support and workarounds
such as RFC1522 tend to cause headaches), but can you try something
simpler in the filter? Trial and error might prove useful with your
problem...
> 2) I am confused with the form of record of a name of a folder in UTF-7
> in imapfilterrc. In file system this folder looks like
> '.&BB8EPgQ0BD8EOARBBDoEMA-.EMS 1C' (apostrophes mine).
> How correctly to write down such folder in imapfilterrc?
Use this:
...
action move "&BB8EPgQ0BD8EOARBBDoEMA-/EMS 1C"
PS. Please, subscribe to the list so I don't have to approve your
messages (the list is "members posting only").
More information about the Imapfilter-devel
mailing list