Re: [Boston.pm] OT - A SpamAssassin question

2004-11-04 Thread John Saylor
hi

( 04.11.03 21:29 -0800 ) Ranga Nathan:
 Needless to say 99% is spam!

 I have some 28MB worth of mail sitting somewhere, waiting to be
 delivered. I want that 28MB mail to be filtered and forwarded to my
 cox.net address.

so 28MB * 0.99 = 27.72MB of SPAM, 0.28MB of HAM

let's say the average mail is 3KB [conservative estimate]
280KB / 3KB = 93.3 mails

hmm ... 93 mails was more than i was anticipating, but i still think you
should just throw them all away. how many times do you get an
opportunity like this where you can lose mail with a plausable technical
explanation? i mean, usually, you can just say- 'o, it must have gotten
eaten by my filter' or 'i must have deleted it accidentally when i was
cleaning out my inbox'.

-- 
\js oblique strategy: change nothing and continue with immaculate consistency
___
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm


Re: [Boston.pm] OT - A SpamAssassin question

2004-11-04 Thread Gyepi SAM
On Wed, Nov 03, 2004 at 09:29:02PM -0800, Ranga Nathan wrote:
 I want to filter my mail from sendmail through SpamAssassin but redirect 
 to my cox.net address.

 I understand that SpamAssassin requires filtering via procmail.

SpamAssassin does *not* require procmail. You are using procmail here as a
Mail Delivery Agent (MDA).

 So I set 
 up /etc/.procmailrc to say:
 DROPPRIVS=yes 
 :0fw
 *  256000 
 | /usr/bin/spamc 

Now you need to forward

:0
! [EMAIL PROTECTED]

 and then brought up the /usr/bin/spamc daemon.
 
 What do I have to tell Sendmail to filter this 28MB of mail through 
 procmail, and then forward only non-SPAM mail to my cox.net address?

This depends on where the mail is stored.

If it is still in the sendmail mail queue (doubtful), you invoke sendmail to deliver 
it,
I stopped using sendmail years ago, so I can't help there.

If it has already been delivered, then you have to invoke procmail
manually. Note that in that instance, it may be wise to rename the mail file first.

formail -s procmail  /mail/file

-Gyepi
___
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm


Re: [Boston.pm] OT - A SpamAssassin question

2004-11-04 Thread Uri Guttman
 DA == Daniel Allen [EMAIL PROTECTED] writes:

  DA formail -s command splits standard-input into valid messages and
  DA executes command on each.

  DA procmail -m conf-file runs procmail for a nonstandard conf file.

  DA So for your procmailrc in the nonstandard location of
  DA /etc/.procmailrc, you'd want:

  DA cat bigfileofspamandham | formail -s 'procmail -m /etc/.procmailrc'

useless use of cat.

formail -s 'procmail -m /etc/.procmailrc'  bigfileofspamandham

uri

-- 
Uri Guttman  --  [EMAIL PROTECTED]   http://www.stemsystems.com
--Perl Consulting, Stem Development, Systems Architecture, Design and Coding-
Search or Offer Perl Jobs    http://jobs.perl.org
___
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm


Re: [Boston.pm] OT - A SpamAssassin question

2004-11-04 Thread Daniel R. Allen


On Thu, 4 Nov 2004, Uri Guttman wrote:

 useless use of cat.

   formail -s 'procmail -m /etc/.procmailrc'  bigfileofspamandham

different strokes.  by the same measure, it's a useless pipeline, plus the
single-quotes are superfluous. but the added clarity (to me) is worth the
extra characters, and the slowest part is most definitely not the cat or
the pipe, it's procmail.

--
http://kw.pm.org/ - Kitchener-Waterloo Perl Mongers - [EMAIL PROTECTED]
http://coder.com/ - Prescient Code Solutions - (519) 575-3733 [EMAIL PROTECTED]



 uri

 --
 Uri Guttman  --  [EMAIL PROTECTED]   http://www.stemsystems.com
 --Perl Consulting, Stem Development, Systems Architecture, Design and Coding-
 Search or Offer Perl Jobs    http://jobs.perl.org


___
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm


Re: [Boston.pm] OT - A SpamAssassin question

2004-11-04 Thread Anthony R. J. Ball

  Not sure how you could get sendmail to do it, but with perl you could
probably do it in about 20-50 lines. Just pull the messages one by one,
if spamc exits 0, send it along.

On Wed, Nov 03, 2004 at 09:29:02PM -0800, Ranga Nathan wrote:
 I want to filter my mail from sendmail through SpamAssassin but redirect 
 to my cox.net address.
 
 Using Sendmail, I used to  redirect all my mail to my cox.net address. 
 Needless to say 99% is spam! Since I stopped redirecting, I have some 28MB 
 worth of mail sitting somewhere, waiting to be delivered. I want that 28MB 
 mail to be filtered and forwarded to my cox.net address.
 
 I understand that SpamAssassin requires filtering via procmail. So I set 
 up /etc/.procmailrc to say:
 DROPPRIVS=yes 
 :0fw
 *  256000 
 | /usr/bin/spamc 
 
 and then brought up the /usr/bin/spamc daemon.
 
 What do I have to tell Sendmail to filter this 28MB of mail through 
 procmail, and then forward only non-SPAM mail to my cox.net address?
 
 No matter what I do, I have to filter the existing 28MB of mail before 
 doing anything else.
 
 Can someone help this idiot?
 
 Thanks
 
 
 __
 Ranga Nathan / CSG
 Systems Programmer - Specialist; Technical Services; 
 BAX Global Inc. Irvine-California
 Tel: 714-442-7591   Fax: 714-442-2840
 
 ___
 Boston-pm mailing list
 [EMAIL PROTECTED]
 http://mail.pm.org/mailman/listinfo/boston-pm
 

-- 
 www.suave.net - Anthony Ball - [EMAIL PROTECTED]
OSB - http://rivendell.suave.net/Beer
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Wheel of Morality, turn turn turn -- Wakko

___
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm


Re: [Boston.pm] OT - A SpamAssassin question

2004-11-04 Thread Brian Reichert
On Thu, Nov 04, 2004 at 10:08:56AM -0500, Anthony R. J. Ball wrote:
 
   Not sure how you could get sendmail to do it, but with perl you could
 probably do it in about 20-50 lines. Just pull the messages one by one,
 if spamc exits 0, send it along.

If you already have all of this mail rattling around, then use
'formail' to cause it to be re-delivered.  This is part of the
procmail distribution.

-- 
Brian Reichert  [EMAIL PROTECTED]
37 Crystal Ave. #303Daytime number: (603) 434-6842
Derry NH 03038-1713 USA BSD admin/developer at large
___
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm


Re: [Boston.pm] OT - A SpamAssassin question

2004-11-04 Thread Gyepi SAM
 If you already have all of this mail rattling around, then use
 'formail' to cause it to be re-delivered.

Technically, using formail for mail that's already rattling around is
just processing, not delivery. Only the MTA can deliver mail, perhaps
by using an external MDA. The distinction becomes very important if you re-inject
previously delivered messages back to the MTA: many will balk and bounce them.

Pedantry makes few friends, but the point must be made nonetheless ;)

-Gyepi
___
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm