Nethserver-rspamd a new module

,

Hi,

I switched from mail to mail2, rspamd worked so far then I reinstalled the packages because there was a milter error and I was not able to send mail. Now sending mail works but I get a “403 Forbidden” error when I want to browse to rspamd web interface:

You don't have permission to access /cdsljqoeejfu908fuadsofji33458/ on this server.

It’s a VPS with one interface. For instance I could open phpmyadmin to the public by setting the access property to public. I didn’t find something similar for rspamd. Do you have an idea?

The milter error:

Feb 11 22:41:26 nethserver postfix/pickup[9722]: 4E10B3CCF: uid=0 from=<root>
Feb 11 22:41:26 nethserver postfix/cleanup[2566]: warning: connect to Milter service unix:/var/run/opendkim/milter: Permission denied
Feb 11 22:41:26 nethserver postfix/cleanup[2566]: 4E10B3CCF: milter-reject: CONNECT from localhost[127.0.0.1]: 4.7.1 Service unavailable - try again later; from=<root@nethserver.smart-ict.services>

As declared on the manual page,

For security reasons the connection is restricted to trusted networks only.

We cannot expose that application to Internet, you need an SSH tunnel or VPN.

Could you attach the error message?

Thanks, maybe I had an old version because I could reach the interface, today I updated and now it’s forbidden.

It was more a postfix milter dkim error that flooded the maillog but it’s not occuring anymore:

Feb 11 22:41:20 nethserver postfix/pickup[9722]: 4B5A43CCF: uid=0 from=<admin@smart-ict.services>
Feb 11 22:41:20 nethserver postfix/cleanup[2566]: warning: connect to Milter service unix:/var/run/opendkim/milter: Permission denied
Feb 11 22:41:20 nethserver postfix/cleanup[2566]: 4B5A43CCF: milter-reject: CONNECT from localhost[127.0.0.1]: 4.7.1 Service unavailable - try again later; from=<admin@smart-ict.services>
Feb 11 22:41:21 nethserver postfix/pickup[9722]: 4BBEC3CCF: uid=0 from=<admin@smart-ict.services>
Feb 11 22:41:21 nethserver postfix/cleanup[2566]: warning: connect to Milter service unix:/var/run/opendkim/milter: Permission denied
Feb 11 22:41:21 nethserver postfix/cleanup[2566]: 4BBEC3CCF: milter-reject: CONNECT from localhost[127.0.0.1]: 4.7.1 Service unavailable - try again later; from=<admin@smart-ict.services>
Feb 11 22:41:22 nethserver postfix/pickup[9722]: 4C2A6274F: uid=0 from=<admin@smart-ict.services>
Feb 11 22:41:22 nethserver postfix/cleanup[2566]: warning: connect to Milter service unix:/var/run/opendkim/milter: Permission denied
Feb 11 22:41:22 nethserver postfix/cleanup[2566]: 4C2A6274F: milter-reject: CONNECT from localhost[127.0.0.1]: 4.7.1 Service unavailable - try again later; from=<admin@smart-ict.services>

so, I guess, with a public IP, isn’t it?

Yes, it is.

I have to try the dummy interface in combination with openvpn to access internal web UIs smoothly and secure. It’s on my list.

A SSH local port forward of 980 should be enough in this case!

ssh -L 9980:localhost:980 <public IP>

Then connect to

https://localhost:9980
2 Likes

Thanks again. I use Windows so I did it with putty. Works like a charm!

1 Like

thank @mrmarkuz and @hucky for testing rspamd

3 Likes

I’m testing a plugin for thunderbird rspamd-spamness, it looks fun, the purpose is to display the rspamd score and the symbols directly in thunderbird

2 Likes

I tested it now and TB shows the rspamd score column but there are no values. Do I have to change something on the server side?

yes in /etc/rspamd/override.d/milter_headers.conf

add

extended_spam_headers = true;

restart rspamd

systemctl restart rspamd

I need to see with @davidep but I feel we have to put it by default (in locale.d).

you weill see a lot more headers in the email

1 Like

After a day i can say it seems to work, what i dont get are a few things. First i saw this morning a few Mails which was marked as spam (what was right) but i dont see them in the rspam history.

Second Thing is, that something happen to my DNS Konfiguration, i receive every second from evebox that a ET DNS Standard query response, Name Error. and it is blocked. No idea at the Moment why but it seems to be a general problem now with dns cause i also have probs to open websites then and when.

it should not, it takes the same dns configuration than the former nethserver-mail-filter

but it is that way, lol and i also have a high cpu load . but not complaining here, just saying :slight_smile:

1 Like

ok you hit a bug we know, I suppose it is when you was looking the history panel, can you confirm ?

we are in contact with the lead dev and a patch is on the way to rspamd…for now you could go to the old history tab

vim /etc/rspamd/override.d/history_redis.conf

enabled = false;

then restart rspamd

systemctl restart redis-rspamd rspamd

you change the history saved way so do not be worried if your history is empty

1 Like

enabled = false;

of course

thank for testing it :slight_smile:

2 Likes

i really adore your work @stephdl so iam glad to test it.

i see on rspamd this entry:
15.2.2018, 07:29:47 rspamd_proxy 14594 lua 5335b9 error querying dns: query timed out

think this is the reason why i have this kind of error in evebox

from time to time you can see this error in the history tab, spam hunt does a lot of queries to dns, some might not be reachable…if it is all the time it is an issue