0

on my centos 5 I've installed spamassassin and I want to execute it from php using the command line client.

The problem is that each time I run it, I get as result:

0/0

here is how I run it

echo "VIAGRA" | /usr/bin/spamc -c -F spamassasin.conf

this is my config file

# SpamAssassin config file for version 3.x
# NOTE: NOT COMPATIBLE WITH VERSIONS 2.5 or 2.6
# See http://www.yrex.com/spam/spamconfig25.php for earlier versions
# Generated by http://www.yrex.com/spam/spamconfig.php (version 1.50)

# How many hits before a message is considered spam.
required_score           7.5

# Encapsulate spam in an attachment (0=no, 1=yes, 2=safe)
report_safe             1

# Enable the Bayes system
use_bayes               1

# Enable Bayes auto-learning
bayes_auto_learn              1

# Enable or disable network checks
skip_rbl_checks         0
use_razor2              1
use_dcc                 1
use_pyzor               1

# Mail using languages used in these country codes will not be marked
# as being possibly spam in a foreign language.
# - english 
ok_languages            en 

# Mail using locales used in these country codes will not be marked
# as being possibly spam in a foreign language.
ok_locales              en 

any idea?

As always, thank you

Gabriel Sosa
  • 1,220
  • 1
  • 13
  • 13

3 Answers3

2

That's not an RFC822 e-mail, spamassassin may simply be giving up.

You might have some test mails in /usr/share/doc/spamassassin/examples/ that are a better test.

LapTop006
  • 6,496
  • 20
  • 26
1

the answer what pretty easy..... the spamassassin was down during testings :P

Gabriel Sosa
  • 1,220
  • 1
  • 13
  • 13
1

Rather than testing using the string 'VIAGRA', use sample spam (sample-spam.txt) or the GTUBE string:

XJS*C4JDBQADN1.NSBN3*2IDNEN*GTUBE-STANDARD-ANTI-UBE-TEST-EMAIL*C.34X

GTUBE is the anti-spam equivalent of EICAR.

MikeyB
  • 39,291
  • 10
  • 105
  • 189