If you are not so firm with regexes, I recomend Regex Buddy, which makes even complex regexes easy to create and to understand! http://www.regexbuddy.com/
It's not free, but the 30€ are nothing compared to the pain broken regexes will create. Matti > How ever - there is a basic rule for all regexes: > than more a regex is generic (using \w+\W+ .* \S* or any negation of a > chunk of characters like [^\r\n]+) - than more false positives will be > detected. The only way to prevent this, is to build the regexes as strict > as needed and using some more of them, if one is too less. > It is important for ALL users of any assp version - to know : IF you > change any regular expression, you have to know EXACTLY what you are > doing. ONE single changed character in a regex could cause assp to die in > the most worth case. > I recommend everyone who wants to edit/create regular expression to learn > (not only to read) - I meen realy learn - > http://perldoc.perl.org/perlretut.html > Now, someone will ask me "when will I be ready to do regular expressions?" > - OK - if you can analyze the following regex line from "bombre.txt" > \b(?:\\\/|V)+\s?\S?\s?\W?[I1!|lt\xec-\xef]+\s?\s?\s?\w?[a\xa4\xe0-\...@]+\s?\s?\s?\w?g+\s?\s?\s?\w?r+\s?\s?\s?\w?[a\xa4\xe0-\xe6@]\b > and you can see, that this regex searches for the 'not red - not big - not > a suppository .....' - you are ready. There is nothing magic in that > string, no look ahead, no look back - it is not a simple but less generic, > full sequential regex. If you don't believe me - ask Dale (sorry Dale :) ) > - a single wrong set backslash could do realy realy strange things. > I don't want to look like a teacher with a wagging finger - but the last > weeks have shown - that many problems where caused by incorrect modified > regular expression files. > If I went too far or offended someone - I am sorry. > One last 'tip' - we have a feature 'testRe' in assp. If you want to know, > if your regular expression is ok - define it there and use the analyzer to > check if it is working like expected - before you change your production > files. > I wish all of you, a happy spam fighting - using assp. > Thomas > Von: "GrayHat" <[email protected]> > An: "ASSP development mailing list" <[email protected]> > Datum: 21.10.2010 16:46 > Betreff: Re: [Assp-test] URI Bug >> ASSP triggered on it, thinking it was a link to some javascript: >> >> BombData: 'http://www.tirerack.com/a..js' > hm... what about getting some ideas from > http://search.cpan.org/dist/URI/URI/Split.pm > to split and check the URIs ? > Some further (although maybe unrelated stuff) > http://search.cpan.org/~gaas/URI-1.56/URI.pm > http://fr2.rpmfind.net/linux/rpm2html/search.php?query=perl%28URI%3A%3AParseSearchString%29 > ------------------------------------------------------------------------------ > Nokia and AT&T present the 2010 Calling All Innovators-North America > contest > Create new apps & games for the Nokia N8 for consumers in U.S. and Canada > $10 million total in prizes - $4M cash, 500 devices, nearly $6M in > marketing > Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store > http://p.sf.net/sfu/nokia-dev2dev > _______________________________________________ > Assp-test mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/assp-test > DISCLAIMER: > ******************************************************* > This email and any files transmitted with it may be confidential, legally > privileged and protected in law and are intended solely for the use of the > individual to whom it is addressed. > This email was multiple times scanned for viruses. There should be no > known virus in this email! > ******************************************************* -- Matti Haack - Hit Haack IT Service Gmbh Poltlbauer Weg 4, D-94036 Passau Geschäftsführer: Henry Haack HRB Passau Nr. 5678 +49 851 50477-22 Fax: +49 851 50477-29 http://www.haack-it.de ------------------------------------------------------------------------------ Nokia and AT&T present the 2010 Calling All Innovators-North America contest Create new apps & games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev _______________________________________________ Assp-test mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/assp-test
