Yahoo Groups archive

Milter-greylist

Index last updated: 2026-04-28 23:32 UTC

Thread

logical bug with extendedregex

logical bug with extendedregex

2005-10-28 by Alexey Popov

Hi.

As far as I understand, compilation of regular expressions in ACL's is
performed during config parsing. Therefore regexp can be compiled either
as extended or basic depending on position of the keyword
'extendedregex' in the config file.

Not sure what to do, but I think it should be documented or one should
put keyword 'extendedregex' in the beginning of sample config file. I
dont think this switch is useful at all. re_format(7) in FreeBSD calls
basic regex "obsolete" and says that it "mostly exist for backward
compatibility in some old programs".

I am using many ACL's based on client's hostname, so it is useful for me
to log hostnames along with "addr", "rcpt" and "from". If you also find
it usefull, see simple patch attached.

With Best Regards,
Alexey Popov

Re: [milter-greylist] logical bug with extendedregex

2005-10-28 by Matt Kettler

Alexey Popov wrote:
> Hi.
> 
> As far as I understand, compilation of regular expressions in ACL's is
> performed during config parsing. Therefore regexp can be compiled either
> as extended or basic depending on position of the keyword
> 'extendedregex' in the config file.
> 
> Not sure what to do, but I think it should be documented or one should
> put keyword 'extendedregex' in the beginning of sample config file. 

I agree. That's a substantial oversight in the greylist.conf manpage.

> I dont think this switch is useful at all. 

I disagree.. one thing to consider is that many versions of milter-greylist were
released without support for extended regex. So you have an existing userbase
that have configurations that rely on the basic regex syntax.

While this switch might be useless to you, it's very useful to folks who have
existing configurations. And this is, unfortunately, a very recent change for
milter-greylist. The feature was added (by me) on March 18, 2005.

The fact that the parsing changes depends on where you put it is more of a
side-effect of how the parser is implemented. That said, it does have the useful
benefit of allowing people to "tack on" extended regex acls to the end of their
existing config without rewriting.

But you're right, this effect of the feature should be documented.



>re_format(7) in FreeBSD calls
> basic regex "obsolete" and says that it "mostly exist for backward
> compatibility in some old programs".

It's not just FreeBSD that calls it obsolete, even POSIX calls it obsolete.

IMHO, even extended regex is obsolete, surpassed by the far more popular PCRE
(perl compatible regex). However, a conversion to PCRE would be a bit more
involved.

In the interim, at least we have extended regex support for those who need it.
Which is substantially better than the state of things back in March, when
milter-greylist did not support anything but basic regex.

Re: [milter-greylist] logical bug with extendedregex

2005-10-28 by Emmanuel Dreyfus

On Fri, Oct 28, 2005 at 10:49:16AM -0400, Matt Kettler wrote:
> But you're right, this effect of the feature should be documented.

Patch to greylist.conf(5) are welcome.

-- 
Emmanuel Dreyfus
manu@...

Re: [milter-greylist] logical bug with extendedregex

2005-11-01 by Alexey Popov

Hi.

Emmanuel Dreyfus wrote:
>>But you're right, this effect of the feature should be documented.
> Patch to greylist.conf(5) are welcome.
Here it is.

And what about my patch to log hostnames?

With Best Regards,
Alexey Popov

Re: [milter-greylist] logical bug with extendedregex

2005-11-01 by Emmanuel Dreyfus

On Tue, Nov 01, 2005 at 10:43:37AM +0300, Alexey Popov wrote:
> And what about my patch to log hostnames?

It's checked in with a small change: it logs things such as
addr = mailer.espci.fr[193.54.82.17]
instead of
addr = 193.54.82.17 hostname = mailer.espci.fr

-- 
Emmanuel Dreyfus
manu@...

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.