SpamExperts / OrangeAssassin

OrangeAssassin
https://orangeassassin.org
Apache License 2.0
59 stars 19 forks source link

Hi issues when testing orange assasin #76

Open FrankJ1122 opened 7 years ago

FrankJ1122 commented 7 years ago

Version information

We are currently testing orangeassasin as a replacement for spamassasin. We are unable to find any docs related to the installation steps, but however we have started the installation process. We are using orangeassasin to be setup on the Cpanel server. We have both python2.7 and python3 installed on the server along with the pip.

I would like to know if there is any valid documentation of orange assasin to be used in cpanel server

Note: we cannot interfere the default python version on the server as it would break yum packages on the server.

Currently as a part of the test we are using test scripts

Steps to replicate

use script py.test tests/unit/

root@orangeassassin [/]# cd /usr/src/Python-2.7.6/OrangeAssassin/ root@orangeassassin [/usr/src/Python-2.7.6/OrangeAssassin]# py.test tests/unit/ =============================================================================================== test session starts =============================================================================================== platform linux2 -- Python 2.7.6, pytest-3.0.7, py-1.4.33, pluggy-0.4.0 rootdir: /usr/src/Python-2.7.6/OrangeAssassin, inifile: plugins: cov-2.4.0 collected 1004 items / 3 errors

===================================================================================================== ERRORS ====================================================================================================== _ ERROR collecting tests/unit/test_daemon.py __ tests/unit/test_daemon.py:12: in import scripts.oad scripts/oad.py:16: in import oa.server oa/server.py:34: in class RequestHandler(spoon.server.Gulp): E AttributeError: 'module' object has no attribute 'Gulp' _ ERROR collecting tests/unit/test_server.py __ tests/unit/test_server.py:14: in import oa.server oa/server.py:34: in class RequestHandler(spoon.server.Gulp): E AttributeError: 'module' object has no attribute 'Gulp' __ ERROR collecting tests/unit/test_plugins/test_spf.py ___ ImportError while importing test module '/usr/src/Python-2.7.6/OrangeAssassin/tests/unit/test_plugins/test_spf.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: tests/unit/test_plugins/test_spf.py:11: in import oa.plugins.spf oa/plugins/spf.py:8: in import spf /usr/local/lib/python2.7/site-packages/spf.py:110: in import DNS # http://pydns.sourceforge.net E ImportError: No module named DNS !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 3 errors during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ============================================================================================= 3 error in 3.36 seconds =============================================================================================

bitsikas commented 7 years ago

Hello, if you need to run the tests you can use http://orangeassassin.readthedocs.io/en/latest/intro.html as a guide You seem to be missing the spoon==1.0.1 (looks like you have another version) and pydns==2.3.6

You don't need to change your python version, ideally you would create a virtualenv and install the dependencies for OA there. for python2.7 you would need to install

We plan to provide Debian and CentOS packages, and if you wish you can follow that work here https://github.com/SpamExperts/OrangeAssassin-build

FrankJ1122 commented 7 years ago

Hi,

As we are dealing with huge spam volumes and we have spamassasin installed on the server. Could you let us know an insight into how should we proceed incorporating the OA rules on the server. Appreciate your thoughts on this.

bitsikas commented 7 years ago

Hello,

OrangeAssassin is supposed to be a drop-in replacement for SpamAssassin. So you would use the same rules for both of them.

You can take a look at our Documentation, especially at the Configuration and Writing Tests sections for more information.

Ideally you should not need to do anything more besides giving the appropriate paths to the -S and -C daemon options.

FrankJ1122 commented 7 years ago

Hi, Thanks for your reply. I have followed the doc http://orangeassassin.readthedocs.io/en/latest/intro.html as recommended but stuck with the below errors on testing.

==== ==================================================================================================== FAILURES ===================================================================================================== _ TestDaemon.test_check_content_lenerror

self =

def test_check_content_len_error(self):
    """Check invalid content-length input error"""
    process_row = "CHECK"
    content_row = "Content-length: %s\r\n" % '-100000'
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command)

tests/functional/test_daemon.py:322:


self = text = 'CHECK SPAMC/1.2\r\nContent-length: -100000\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/testdaemon.py:161: ConnectionRefusedError ---------------------------------------------------------------------------------------------- Captured stderr setup ---------------------------------------------------------------------------------------------- Traceback (most recent call last): File "scripts/oad.py", line 16, in import oa.server File "/usr/local/lib/python2.7/site-packages/oa/server.py", line 34, in class RequestHandler(spoon.server.Gulp): AttributeError: 'module' object has no attribute 'Gulp' ____ TestDaemon.test_check_non_spam __

self =

def test_check_non_spam(self):
    """Just check if the passed message isn't spam and verify the result"""
    process_row = "CHECK"
    content_row = "Content-length: %s\r\n" % self.len_test_msg
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, TEST_MSG))
  result = self.send_to_proc(command).split("\r\n", 4)

tests/functional/test_daemon.py:332:


self = text = 'CHECK SPAMC/1.2\r\nContent-length: 103\r\n\r\nSubject: Email Flow Test\nFrom: Geo test@example.com\nTo: jimi@example.com\n\n\nThis is a test message.\n\n\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError ___ TestDaemon.test_check_spam ____

self =

def test_check_spam(self):
    """Just check if the passed message is spam and verify the result"""
    process_row = "CHECK"
    content_row = "Content-length: %s\r\n" % self.content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command).split("\r\n", 4)

tests/functional/test_daemon.py:311:


self = text = 'CHECK SPAMC/1.2\r\nContent-length: 86\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError __ TestDaemon.test_ping ___

self =

def test_ping(self):
    """Return a confirmation that oad.py/spamd is alive."""
    process = "PING"
    command = "%s SPAMC/1.2\r\n" % process
  result = self.send_to_proc(command)

tests/functional/test_daemon.py:191:


self = , text = 'PING SPAMC/1.2\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError ___ TestDaemon.test_ping_error ____

self =

def test_ping_error(self):
    """Check unknown process input error"""
    process = "PINasdfG"
    command = "%s SPAMC/1.2\r\n" % process
  result = self.send_to_proc(command)

tests/functional/test_daemon.py:198:


self = , text = 'PINasdfG SPAMC/1.2\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError __ TestDaemon.test_process_content_body_non_spam __

self =

def test_process_content_body_non_spam(self):
    process_row = "PROCESS"
    content_row = "Content-length: %s\r\n" % self.len_test_msg
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, TEST_MSG))
  result = self.send_to_proc(command).split("\r\n\r\n", 1)[1]

tests/functional/test_daemon.py:299:


self = text = 'PROCESS SPAMC/1.2\r\nContent-length: 103\r\n\r\nSubject: Email Flow Test\nFrom: Geo test@example.com\nTo: jimi@example.com\n\n\nThis is a test message.\n\n\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError ____ TestDaemon.test_process_content_body_spam ____

self =

def test_process_content_body_spam(self):
    process_row = "PROCESS"
    content_row = "Content-length: %s\r\n" % self.content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command).split("\r\n\r\n", 1)[1]

tests/functional/test_daemon.py:277:


self = text = 'PROCESS SPAMC/1.2\r\nContent-length: 86\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError ___ TestDaemon.test_process_content_disposition ___

self =

def test_process_content_disposition(self):
    """Process this message as described above and return content
        disposition """
    process_row = "PROCESS"
    content_row = "Content-length: %s\r\n" % self.content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command).split("\r\n\r\n", 1)[1]

tests/functional/test_daemon.py:239:


self = text = 'PROCESS SPAMC/1.2\r\nContent-length: 86\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError ____ TestDaemon.test_process_content_disposition2_spam ____

self =

def test_process_content_disposition2_spam(self):
    process_row = "PROCESS"
    content_row = "Content-length: %s\r\n" % self.content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command).split("\r\n\r\n", 1)[1]

tests/functional/test_daemon.py:265:


self = text = 'PROCESS SPAMC/1.2\r\nContent-length: 86\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError ____ TestDaemon.test_process_content_encoding_non_spam ____

self =

def test_process_content_encoding_non_spam(self):
    """Process this multi-part message and return the content transfer
         encoding"""
    process_row = "PROCESS"
    content_row = "Content-length: %s\r\n" % self.multipart_content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, MULTIPART_MSG))
  result = self.send_to_proc(command).split("\r\n\r\n", 1)[1]

tests/functional/test_daemon.py:253:


self = text = 'PROCESS SPAMC/1.2\r\nContent-length: 1205\r\n\r\nFrom: Marco Antonio Islas Cruz marco@seinternal.com\nContent-Type:...">

\nTesting rule one-two-three\n
\n--Apple-Mail=_9311E301-2E56-423D-B730-30A522F3844C--\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError ____ TestDaemon.test_process_content_len_error ____

self =

def test_process_content_len_error(self):
    """Check invalid content-length input error"""
    process_row = "PROCESS"
    missing = ''
    content_row = "Content-length: %s\r\n" % missing
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command)

tests/functional/test_daemon.py:290:


self = text = 'PROCESS SPAMC/1.2\r\nContent-length: \r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError __ TestDaemon.test_process_content_type ___

self =

def test_process_content_type(self):
    """Process this message as described above and return modified
        message"""
    process_row = "PROCESS"
    content_row = "Content-length: %s\r\n" % self.content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command).split("\r\n\r\n", 1)[1]

tests/functional/test_daemon.py:208:


self = text = 'PROCESS SPAMC/1.2\r\nContent-length: 86\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError __ TestDaemon.test_process_content_type_non_spam __

self =

def test_process_content_type_non_spam(self):
    """Process this multipart-message and return the content-type
        message"""
    process_row = "PROCESS"
    content_row = "Content-length: %s\r\n" % self.multipart_content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, MULTIPART_MSG))
  result = self.send_to_proc(command).split("\r\n\r\n", 1)[1]

tests/functional/test_daemon.py:221:


self = text = 'PROCESS SPAMC/1.2\r\nContent-length: 1205\r\n\r\nFrom: Marco Antonio Islas Cruz marco@seinternal.com\nContent-Type:...">

\nTesting rule one-two-three\n
\n--Apple-Mail=_9311E301-2E56-423D-B730-30A522F3844C--\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/testdaemon.py:161: ConnectionRefusedError ____ TestDaemon.test_report_if_spam __

self =

def test_report_if_spam(self):
    """Check if message is not spam, and see no score plus report"""
    process_row = "REPORT_IFSPAM"
    content_row = "Content-length: %s\r\n" % self.multipart_content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, MULTIPART_MSG))
  result = self.send_to_proc(command).split("\r\n")

tests/functional/test_daemon.py:411:


self = text = 'REPORT_IFSPAM SPAMC/1.2\r\nContent-length: 1205\r\n\r\nFrom: Marco Antonio Islas Cruz marco@seinternal.com\nContent...">

\nTesting rule one-two-three\n
\n--Apple-Mail=_9311E301-2E56-423D-B730-30A522F3844C--\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError _ TestDaemon.test_report_if_spamtrue

self =

def test_report_if_spam_true(self):
    """Check if message is spam, and return score plus report if
        the message is spam"""
    process_row = "REPORT_IFSPAM"
    content_row = "Content-length: %s\r\n" % self.content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command)

tests/functional/test_daemon.py:425:


self = text = 'REPORT_IFSPAM SPAMC/1.2\r\nContent-length: 86\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError _ TestDaemon.test_reportspam

self =

def test_report_spam(self):
    """Check if message is spam or not, and return score plus report"""
    process_row = "REPORT"
    content_row = "Content-length: %s\r\n" % self.content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command)

tests/functional/test_daemon.py:396:


self = text = 'REPORT SPAMC/1.2\r\nContent-length: 86\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/testdaemon.py:161: ConnectionRefusedError ____ TestDaemon.test_symbols_bad_headerline ____

self =

def test_symbols_bad_header_line(self):
    """Check bad command sent scenario """
    process_row = "SYMBOL"
    content_row = "Content-length: %s\r\n" % self.content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command)

tests/functional/test_daemon.py:371:


self = text = 'SYMBOL SPAMC/1.2\r\nContent-length: 86\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError ____ TestDaemon.test_symbols_missing_key_content_error ____

self =

def test_symbols_missing_key_content_error(self):
    """Check missing ":" in content-length input error"""

    process_row = "SYMBOLS"
    content_row = "Content-length %s\r\n" % self.content_len
    command = ("%s SPAMC/1.2\r\n%s\r\n%s\r\n" %
               (process_row, content_row, GTUBE_MSG))
  result = self.send_to_proc(command)

tests/functional/test_daemon.py:361:


self = text = 'SYMBOLS SPAMC/1.2\r\nContent-length 86\r\n\r\nSubject: test\n\nXJSC4JDBQADN1.NSBN32IDNENGTUBE-STANDARD-ANTI-UBE-TEST-EMAILC.34X\n\r\n'

def send_to_proc(self, text):
    connection = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    connection.settimeout(5)
  connection.connect(("localhost", self.port))

E ConnectionRefusedError: [Errno 111] Connection refused

tests/functional/test_daemon.py:161: ConnectionRefusedError ____ TestDaemon.test_symbols_nonspam ____

can you help me trouble shoot. I have installed all the requirements and necessary plugins. Since I am using cpanel test environment the MINI-DNS-Server-master was cloned and installed manually. apart from that the installation is as per described on the docs. Could you recommend any suggestions to trouble shoot.

bitsikas commented 7 years ago

Hello,

would it be easy to post the result of pip freeze and python -VV ? It looks like an issue with the spoon package but I can't reproduce it locally.

FrankJ1122 commented 7 years ago

I am using python3.6 that is custom compiled on the server. Please have a check.

root@orangeassassin [/]# /usr/local/bin/python3.6 -VV Python 3.6.1 (default, May 3 2017, 11:21:07) [GCC 4.4.7 20120313 (Red Hat 4.4.7-18)]

root@orangeassassin [/]# /usr/local/bin/pip3.6 freeze contextlib2==0.5.5 coverage==4.4 dill==0.2.5 dkimpy==0.5.6 dnslib==0.9.6 dnspython3==1.12.0 future==0.15.2 langdetect==1.0.6 memory-profiler==0.47 Mini-DNS==1.2.0 mock==2.0.0 olefile==0.44 OrangeAssassin==1.0b0 pbr==3.0.0 pep8==1.7.0 Pillow==4.0.0 psutil==5.2.2 py==1.4.33 py3dns==3.1.0 pygeoip==0.3.2 PyMySQL==0.7.11 PyPDF2==1.25.1 pyspf==2.0.12 pytest==2.9.1 pytest-cov==2.2.1 python-coveralls==2.7.0 python-dateutil==2.6.0 PyYAML==3.12 pyzor==1.0.0 raven==5.13.0 requests==2.14.2 se-profile==1.0.0 sh==1.12.13 six==1.10.0 spoon==1.0.1 SQLAlchemy==1.0.12

bitsikas commented 7 years ago

They seem fine, there are a couple of differences but they should not be important. Is there any reason the server would not be able to start/bind port 30783 in your test environment ?

FrankJ1122 commented 7 years ago

We have no firewall rules that may block onto the ports in an allowed range that includes the mentioned port number. But to clarify could you please let us know if you mean to configure the bind( or named) with port 30783.

Also as it turns to be tedious I am currently trying to incorporate the OA rule sets to Spamassasin. Could you let us know if there would be any special settings needed to enable this feature. I am aware that we could use the .cf rules to be added to make the rule sets added on the Spamassasin. ( am I correct in my approach?)

tonyandrewmeyer commented 7 years ago

Also as it turns to be tedious I am currently trying to incorporate the OA rule sets to Spamassasin.

OA does not have any rule sets, as mentioned earlier. It's a replacement for the daemon, intended to be used with regular SA rule sets.

bitsikas commented 7 years ago

@FrankJ1122 You need to get the relevant rules (.pre files and .cf files) from spamassassin and then point the daemons -C/-S options to the location of those files. We will provide them when we release our own .deb/.rpm packages but until then that's the only way to get them

as for port 30783. The tests are attempting to run the server on that port and for some reason are failing. By default the daemon binds on 783.

if you want to debug this you can start by running this command

oad.py -p 30783 --log-file /tmp/logfile.log -C /tmp/ -S /tmp/ -D

It should show 2017-05-22 13:53:28,970 [28388] DEBUG Listening on ('0.0.0.0', 30783) and no errors

FrankJ1122 commented 7 years ago

Thanks for the reply. Let me try it out

FrankJ1122 commented 7 years ago

I get the below results

root@orangeassassin [/usr/src/Python-2.7.6/OrangeAssassin/scripts]# oad.py -p 30783 --log-file /tmp/logfile.log -C /tmp/ -S /tmp/ -D 2017-05-22 04:05:35,876 [18077] DEBUG Listening on ('0.0.0.0', 30783) 2017-05-22 04:05:35,877 [18077] DEBUG Unable to set IPV6_V6ONLY to false [Errno 92] Protocol not available 2017-05-22 04:05:35,878 [18077] INFO Using default nameservers 2017-05-22 04:05:35,878 [18077] INFO 0 rules loaded