[milters] Archive

Lists Index Date Thread Search

Article: 1751
From: Anthony Howe
Date: 2007-09-30 14:22:25 -0400
Subject: Re: milter-sender regex

Removal...........: milters-request@milter.info?subject=remove
More information..: http://www.milter.info/#Support

Rose, Bobby wrote:
> Is it me or does the regex patterns are case sensitive?  I created a
> milter-sender-from: rule but it only seemed to work if the pattern was
> all caps which is how the actual address is.  I assumed that since the
> lhs was case insensitive that the test for the rhs would be also.  To
> make the regex case insensitive would it work if it was /pattern/i OK

No. What follows a pattern is treated as an "action", not RE flags.

> NEXT?  If not then how could it be made case insensitive?

Edit libsnert/1.65 com/snert/src/lib/mail/smf.c,

line 609:

	match = TextMatch(hay, pin+1, -1, 0);
	match = TextMatch(hay, pin+1, -1, 1);

line 715

	code = regcomp(&re, pin+1, REG_EXTENDED|REG_NOSUB);
	code = regcomp(&re, pin+1, REG_EXTENDED|REG_NOSUB|REG_ICASE);

Anthony C Howe          Skype: SirWumpus                    SnertSoft
+33 6 11 89 73 78         ICQ: 7116561          BarricadeMX & Milters

Lists Index Date Thread Search