Windows BBS The Place for Microsoft Windows Support! Windows, Support, Help Site

Go Back   Windows BBS > Internet & Networking > Courier Email Client

Courier Email Client Support forum for the Courier Email Client.

Register your FREE account to unlock additional features at WindowsBBS.com
Register
Welcome to WindowsBBS.com
Microsoft Windows Support

Mission Statement

WindowsBBS is an online community dedicated to easily accessible technical support for those using Microsoft operating systems and other Windows software.

Our goal is to become the leading resource for computer users that require assistance with their day-to-day computer usage, including full support for networking PC's, virus & malware removal, system upgrades and general support questions.


Discussion Forums
Operating Systems
Windows 7 Windows 7
Windows Vista Windows Vista
Windows XP Windows XP
Windows Server System Windows Server System
Windows 2000 Windows 2000
Windows 95/98/Me/NT Windows 95/98/Me/NT
Internet & Networking
Networking
Internet Explorer
Microsoft Mail
Firefox, Thunderbird
      & SeaMonkey

General Internet
Security
General Security
Malware and Virus
     Removal

Other
Other Software
Hardware
Test Posts
Community
Introductions
General Discussions
Comments
      & Suggestions

News @ WindowsBBS

Reply
 
LinkBack Thread Tools
Old 19th March 2004   #1
Inactive
 
Profile:
Join Date: Nov 2003
Location: Netherlands
Posts: 111
Computer Experience:
Intermediate
Tureluur Reputation Level


RegExp (again)

I have a rule with this RegExp:

.+IMG.*SRC=.?.?.?HTTP|\.ASP\?|PHP\?

It is supposed to catch mail that downloads an image from another server. (An old SPAMmers trick)

However it did not catch a mail with this in the HTML:

<img src=http://waf.ck.chuasash.com/2/>

What am I doing wrong here?

This is the entire rule:

Filter Rule 5:
Created: 14-3-2004 10:58
Last Hit:
Hits: 0
Mode: Incoming
Case: Off
Pattern 1: .+IMG.*SRC=.?.?.?HTTP|\.ASP\?|PHP\?
Objects: Message body
RegExp: On
Action: Move to folder: 'JunkYard'
Mark as read
Assign color marker: 'SPAM'
Delete attachment(s)
Strip HTML

Tureluur is offline   Reply With Quote
Didn't find the information you thought to find?
Check out these Similar Threads
Old 20th March 2004   #2
Inactive
 
Profile:
Join Date: Mar 2004
Posts: 18
Computer Experience:
Experienced
chris319 Reputation Level


Why do you need a regular expression for this? Why not just look for the string:

img src=

in the message body?

chris319 is offline   Reply With Quote
Old 20th March 2004   #3
Inactive
 
Profile:
Join Date: Nov 2003
Location: Netherlands
Posts: 111
Computer Experience:
Intermediate
Tureluur Reputation Level


Well... SPAMmers put stuff between legitimate HTML code,

So it could look like this: img <lotsofspammerstuff> scr

And it would not be detected by a filter for just "img scr="

Tureluur is offline   Reply With Quote
Old 20th March 2004   #4
Inactive
 
Profile:
Join Date: Mar 2004
Posts: 18
Computer Experience:
Experienced
chris319 Reputation Level


Quote:
Well... SPAMmers put stuff between legitimate HTML code,

So it could look like this: img <lotsofspammerstuff> scr

And it would not be detected by a filter for just "img scr="
I just conducted an experiment, inserting a comment like so:

img<!--my_comment_here-->src=

and IE wouldn't display the picture. Also tried it with spaces:

img <!--my_comment_here--> src=

and still no picture. Take out the comment and the picture is there. So if you are a spammer and you want your picture to be displayed, you can't bust up the img src= tag with a comment like that. Still and all, you could filter for just "src=" using no regular expression.

chris319 is offline   Reply With Quote
Old 21st March 2004   #5
Inactive
 
Profile:
Join Date: Nov 2003
Location: Netherlands
Posts: 111
Computer Experience:
Intermediate
Tureluur Reputation Level


Thanks!

You went to a lot of trouble to fix this problem for me!
I really appreciate that!

"remote images" don't happen too often. SO I'll just have to wait for another SPAM email with "img scr=" to see what happens.....

Tureluur is offline   Reply With Quote
Old 22nd March 2004   #6
Member
 
Profile:
Join Date: Feb 2004
Posts: 39
Computer Experience:
Experienced
JRobert Reputation Level


Quote:
I have a rule with this RegExp:

.+IMG.*SRC=.?.?.?HTTP|\.ASP\?|PHP\?

[...]

However it did not catch a mail with this in the HTML:

<img src=http://waf.ck.chuasash.com/2/>


What is .?.?.? meant to catch - some whitespace perhaps? How about " *" (space, asterisk) - zero or more spaces?

I read the whole expression as:

One or more characters, "IMG", zero or more characters, "SRC=", zero to three more characters, and "HTTP"
or
".ASP?"
or
"PHP?" (may or may not have a leading '.')

Why the match on any ".ASP?" or "PHP?" (any line containing either of those strings)? Not saying it's wrong; I'm just not sure what the second two expressions were meant to accomplish and wondering if says what you intended.

-jeff-


Last edited by JRobert; 22nd March 2004 at 20:17.
JRobert is offline   Reply With Quote
Old 22nd March 2004   #7
Inactive
 
Profile:
Join Date: Nov 2003
Location: Netherlands
Posts: 111
Computer Experience:
Intermediate
Tureluur Reputation Level


Never mind!
Courier does not filter on HTML code.
So this rule is useless anyway............

Tureluur is offline   Reply With Quote
Reply

Thread Tools



All times are GMT +1. The time now is 03:58.






Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.2.0
Copyright © 2002 - 2008 WindowsBBS.com. All rights reserved.
Terms of Use, Legal Information & Privacy Policy
[]