more regex help

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

more regex help

Tim Evans-3
Speaking of regex help, can someone explain why this isn't working:
 
We're getting a lot of spam that has a lot of DIV /DIV tags in it (that's the only unique characteristic I've seen). I've been putting copies in the errors/spam folder, but they seem to be different enough that they're still getting thru. I'm trying to match
</DIV> (newline) <DIV
or
</DIV>(single char)<DIV
or
</DIV>(nothing)<DIV
with this RE in my Expression to identify Spam:
</DIV>.?<DIV
but it's not working.
 
Any suggestions where I'm going wrong?
 
...Tim
 
Reply | Threaded
Open this post in threaded view
|

Re: more regex help

Micheal Espinola Jr
To present a metacharacter as a data character standing for itself,
precede it with a "\" (backslash).

Examples:

\<applet
\<div
\<embed
\<iframe
\<object
\<script


On 1/18/06, Tim Evans <[hidden email]> wrote:

>
> Speaking of regex help, can someone explain why this isn't working:
>
> We're getting a lot of spam that has a lot of DIV /DIV tags in it (that's
> the only unique characteristic I've seen). I've been putting copies in the
> errors/spam folder, but they seem to be different enough that they're still
> getting thru. I'm trying to match
> </DIV> (newline) <DIV
> or
> </DIV>(single char)<DIV
> or
> </DIV>(nothing)<DIV
> with this RE in my Expression to identify Spam:
> </DIV>.?<DIV
> but it's not working.
>
> Any suggestions where I'm going wrong?
>
> ...Tim
>


--
ME2


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
<a href="http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642">http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
_______________________________________________
Assp-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/assp-user
Reply | Threaded
Open this post in threaded view
|

RE: more regex help

Tim Evans-3
In reply to this post by Tim Evans-3
Aha! < & > are metacharatcers, so it should be:
\</DIV\>.?\<DIV
Thanks


...Tim
 

-----Original Message-----
From: [hidden email]
[mailto:[hidden email]] On Behalf Of Micheal
Espinola Jr
Sent: Wednesday, January 18, 2006 1:45 PM
To: [hidden email]
Subject: Re: [Assp-user] more regex help

To present a metacharacter as a data character standing for itself,
precede it with a "\" (backslash).

Examples:

\<applet
\<div
\<embed
\<iframe
\<object
\<script


On 1/18/06, Tim Evans <[hidden email]> wrote:
>
> Speaking of regex help, can someone explain why this isn't working:
>
> We're getting a lot of spam that has a lot of DIV /DIV tags in it
(that's
> the only unique characteristic I've seen). I've been putting copies in
the
> errors/spam folder, but they seem to be different enough that they're
still

> getting thru. I'm trying to match
> </DIV> (newline) <DIV
> or
> </DIV>(single char)<DIV
> or
> </DIV>(nothing)<DIV
> with this RE in my Expression to identify Spam:
> </DIV>.?<DIV
> but it's not working.
>
> Any suggestions where I'm going wrong?
>
> ...Tim
>


--
ME2


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log
files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
<a href="http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642">http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
_______________________________________________
Assp-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/assp-user


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
<a href="http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642">http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
_______________________________________________
Assp-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/assp-user