For some reason razor-check and razor-report doesn't work at all with 
Spamassassin.  I am running Spamassassin 2.60 and Razor 2.36 on RH 9.0 
with Perl 5.8.1. SA (spamd) is being called from procmail using spamc.  
The Spamassassin daemon is running as 'spamd' without any root privileges.  
A patch I got from http://www.ijs.si/software/amavisd/Razor2.patch-quinlan 
I applied to the  razor source tree.  This didn't seem to help any.

Checking and reporting via razor works just fine at the command line.  
When SA attempts to report spam to razor I get the following error message 
every time,

/*BEGIN INCLUDED TEXT*/
razor2 report failed: No such file or directory IO::Socket::INET: 
Bad protocol 'udp'    ...propagated at 
/usr/lib/perl5/site_perl/5.8.1/Mail/SpamAssassin/Reporter.pm                          
line 120.
/*END INCLUDED TEXT*/

I was getting the error message below every time that SA uses razor to 
check if a message is spam or not.  Not sure what I did to make this go 
away (if indeed that is the case), but I believe that an invalid server 
in servers.discovery.lst was the problem.  After I ran "razor-admin -d 
-discover" as root I quit seeing this message apparently.  By the way, 
that command doesn't seem to work properly when I execute it as someone 
other than root.  When I run it I set HOME to "/home/spamd" first, the 
subdirectory where ".razor" is located, so that razor can find 
'razorhome'.

/*BEGIN INCLUDED TEXT*/
razor2 check skipped: Permission denied IO::Socket::INET: Bad protocol 
'udp' at /usr/lib/perl5/site_perl/5.8.1/Mail/SpamAssassin/Dns.pm line 409.
/*END INCLUDED TEXT*/

Below is a copy of my razor-agent.conf file, local.cf, and log entries in 
the mail log when spamd is restarted (only the lines relevant to razor 
have been included).
 
If someone could help me out here I would greatly appreciate it.  I have 
scoured the mailing lists and Google for an answer to this problem for 
more than a week now.  Pyzor and DCC are working just fine.  I just 
need to get Razor2 working then my "ultimate spam blocking system" 
will be in place. :)  Please let me know if I need to provide any 
additional information.  I have posted this message to spamassassin-talk 
and razor-users both in since I am unclear as to whether or not this 
problem is due to SA, Razor, or the both of these.

/*BEGIN INCLUDED TEXT*/
#
# Razor2 config file
# 
# Autogenerated by Razor-Agents v2.36 
# Sat Sep 27 16:49:40 2003
# Created with all default values 
# 
# see razor-agent.conf(5) man page 
#

razorhome              = /home/spamd/.razor
debuglevel             = 20
identity               = identity
ignorelist             = 0
listfile_catalogue     = servers.catalogue.lst
listfile_discovery     = servers.discovery.lst
listfile_nomination    = servers.nomination.lst
logfile                = razor-agent.log
logic_method           = 4
min_cf                 = ac + 10
razorzone              = razor2.cloudmark.com
rediscovery_wait       = 172800
report_headers         = 1
sort_by_distance       = 0
turn_off_discovery     = 0
use_engines            = 1,2,3,4
whitelist              = razor-whitelist
/*END INCLUDED TEXT*/

I see the following in /usr/var/maillog when I restart Spamassassin,

/*BEGIN INCLUDED TEXT*/
Oct  1 14:04:00 linux407 spamd[8105]: debug: Razor2 is available
Oct  1 14:04:00 linux407 spamd[8105]: debug: entering helper-app run mode
Oct  1 14:04:00 linux407 spamd[8105]: debug: razor2 check could not 
connect to any servers
Oct  1 14:04:00 linux407 spamd[8105]: debug: leaving helper-app run mode
Oct  1 14:04:00 linux407 spamd[8105]: debug: Razor2 results: spam? 0  
highest cf score: 0
Oct  1 14:04:00 linux407 spamd[8105]: debug: Razor2 is available
/*END INCLUDED TEXT*/

Here is my local.cf file (whitelist entries have been removed for 
brevity),

/*BEGIN INCLUDED TEXT*/
# SpamAssassin config file for version 2.5x
# generated by http://www.yrex.com/spam/spamconfig.php (version 1.01)
# Modifications made for version 2.60

# How many hits before a message is considered spam.
required_hits                           7.0

# Whether to change the subject of suspected spam
rewrite_subject                         1

# By default, a header field called ``X-Spam-Level'' will be added to the
# message, with its value set to a number of asterisks equal to the score 
of the message.
spam_level_stars                        1

# Text to prepend to subject if rewrite_subject is used
subject_tag                             *****SPAM*****

# Encapsulate spam in an attachment
report_safe                             1

# Use terse version of the spam report
use_terse_report                        0

always_add_report                       1

always_add_headers                      1

# By default, SpamAssassin checks the From: address for a valid MX three 
times, waiting 5 seconds each time.
check_mx_attempts                       3

#How many seconds to wait before retrying an MX check.  Default is 5 
seconds
check_mx_delay                          5

dns_available                           yes

# Enable the Bayes system
use_bayes                               1

# Enable Bayes auto-learning
auto_whitelist_factor                   0.5
bayes_auto_learn                        1
bayes_auto_learn_threshold_nonspam      0.75
bayes_auto_learn_threshold_spam         11.25
bayes_learn_during_report               1
bayes_min_ham_num                       500
bayes_min_spam_num                      500
bayes_path                              /home/spamd/.spamassassin/bayes
bayes_file_mode                         0700
bayes_use_hapaxes                       1
bayes_use_chi2_combining                1
bayes_journal_max_size                  102400
bayes_expiry_max_db_size                600000
bayes_auto_expire                       1
bayes_learn_to_journal                  0


#timelog_path                           /var/log/spamassassin

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

#dcc config
dcc_path                                /usr/local/bin/dccproc
dcc_timeout                             10
dcc_add_header                          1
dcc_body_max                            999999
dcc_fuz1_max                            999999
dcc_fuz2_max                            999999

#pyzor config
pyzor_path                              /usr/bin/pyzor
pyzor_timeout                           10
pyzor_max                               5
pyzor_add_header                        1

#razor config
razor_timeout                           10
razor_config                            
/home/spamd/.razor/razor-agent.conf

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

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

user_scores_dsn                         DBI:mysql:spamassassin:localhost
user_scores_sql_username                spamd
user_scores_sql_password                hooch
user_scores_sql_table                   userpref
user_scores_sql_field_username          username
user_scores_sql_field_preference        preference
user_scores_sql_field_value             value
user_scores_sql_field_scope             spamassassin

allow_user_rules                        1
/*END INCLUDED TEXT*/


Thanks in advance,
Scott



****************** Custom Web Promotions *********************
*                                                            *
*            "The Web Promotion Specialists"                 *
*                                                            *
*                  http://custweb.com/                       *
*                                                            *
*  Web Hosting | E-Commerce Applications | Custom Scripting  *
*  Website Development | Graphics Design | Market Research   *
*                                                            *
****************** Toll-Free: 888-287-8932 *******************






-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Spamassassin-talk mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/spamassassin-talk

Reply via email to