[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4688: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4690: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4691: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4692: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
Poco Forums • View topic - Deleting based on attachment file extention

Deleting based on attachment file extention

Discussion on Bayesian and standard junk mail filters

Moderators: Eric, Tomas, robin, Michael

Deleting based on attachment file extention

Postby FieldDir121 » Mon Nov 29, 2004 11:22 am

Is there a way to delete messages with specific file name extensions? I can delete .src by using "entire message". Deleting .com the same way presents problems. I am trying to think of a way to restrict the search to the attachment extension. Any suggestions?

Scott
FieldDir121
Resident Poster
 
Posts: 149
Joined: Mon Aug 02, 2004 5:18 pm

Postby Michael » Mon Nov 29, 2004 2:26 pm

This can be done using a script. Exact details will depend on if you want Poco to automatically delete the message as it arrives or if you want the chance to review it first.

Use the ReadAttached command to get a list of attachments in teh message. Scan them for the offending extension(s) - (Important, include the extension). If present then either prompt for delete verification or simply delete the message using the DeleteMessage command.
Michael
Moderator
 
Posts: 866
Joined: Mon Jul 26, 2004 12:14 pm
Location: Victoria BC, Canada

Postby FieldDir121 » Mon Nov 29, 2004 3:10 pm

Michael,

I have not used scripts. Is there a beginners example and description? Once I get started I can usually expand on that knowledge on my own.

Scott
FieldDir121
Resident Poster
 
Posts: 149
Joined: Mon Aug 02, 2004 5:18 pm

Postby Pete » Mon Nov 29, 2004 7:02 pm

Hi Scott, Pocomail does not automatically run attachments so in general you don't need to worry about this.

However, if you've disabled "Tools > Options > Encoding options > ... Leave Attachments Encoded...", then you might have a problem where these attachments remain in the Attach folder on your disk drive even though you've deleted the message.

I wrote a script a while ago to automatically delete incoming attachments with user-specified extensions. You can configure it to prompt you first if you want. If you're still interested, I can post it to the Pocoscript forum.
Pete
 

Postby Guest » Mon Nov 29, 2004 7:11 pm

Pete,

I am not worried about Pocomail running the attachments. Any attachment with .src, .com or a few others will always be spam and probably contain viruses. I would like to automatically delete them. There are some files that I need to let through, .zip, .vhd, .c, etc.

Yes I would be interested in your script. Thank you.

Scott
Guest
 

Postby Pete » Mon Nov 29, 2004 8:04 pm

I've posted the script at
http://pocosystems.com/forum/viewtopic.php?t=1351

You'll need to uncomment some of the lines in FF_MAIN. Just post to that topic if you want any assistance.
Pete
 


Return to Junk Mail Filtering Help and How-To

Who is online

Users browsing this forum: No registered users and 2 guests

cron