Hello, I have this as my filter.sh file under postfix and it works just find.  The log 
file /tmp/currentspamlist.txt holds each transaction that we have.  What I would like 
to do is to also capture weather or not the email was a spam.  I was thinking that I 
could make a second call to spamc with the -c command and capture the STOUT but that 
would mean processing each message twice?  Is there a simple why to do what I am 
looking for?
 
I tried putting the -c into the script and I ended up getting a few emails containing 
the results.  I think its because it's piping the x/x code to STDOUT so sendmail is 
sending that instead.
 
#!/bin/sh
/usr/bin/spamc  |  /usr/sbin/sendmail -i "$@"
retval=$?
echo `date` "$@" "$retval" >> /tmp/currentspamlist.txt
retval=0
exit $retval

Gary Smith
†+w­zf¢–+,¦‰ìo"0¸§»îâj[yÊ&y©ÞÆ«¶)Ë Õ¢¸î²Û!jº^Ÿ*.®É"–[Š    î¥ú+ 
,·ž.)îÅ;­¢¸š–ÂÞj¹Þêò¶§úèšØ^m«!²¥–Ú,ÊÆš)Â'$žŒ!¶Úý§l¢Çgr‰¿iØ×nüjYhr'wßh¥ÉbrD©jf¬±«,Š{Z–IšŠX§‚X¬µ*Z™«,jË"žÖ’X¬¶Ë(º·~Šàzw­†Ûi³ÿåŠËl²‹«qç讧zßåŠËlþX¬¶)ßû)jf¬±«,Š{Z–

Reply via email to