Re: OpenSMTPD + rspamd to sign mail.

2021-08-12 Thread latincom
> On 8/12/21 5:09 AM, latin...@vcn.bc.ca wrote:
>> Hello
>>
>> After:
>> # pkg_add redis rspamd opensmtpd-filter-rspamd successfully
>>
>> i got:
>> # rcctl start rspamd
>> rspamd(failed)
>>
>> then I did:
>> # rspamd -d
>> 2021-08-12 09:23:41 #0(main) ; main; detect_priv: cannot run
>> rspamd workers as root user, please add -u and -g options to select a
>> proper unprivilleged user or specify --insecure flag
>>
>> How to interpret it please?
>>
>> I did # chown R spamd:_rspamd /etc/mail/dkim but it fails, then i did
>>   # chown -R root:_spamd /etc/mail/dkim and it worked; anyway i suppose
>> i
>> should do  rspamd:_rspamd to change -u and -g
>>
>> thanks for your attention.
>>
> What is the contents of your /etc/rc.d/rspamd file? It should include
> lines like:
>
>     daemon="/usr/local/bin/rspamd"
>     daemon_flags="-u _rspamd -g _rspamd"


#!/bin/ksh
#
# $OpenBSD: rspamd.rc,v 1.4 2019/10/29 22:50:14 sthen Exp $

daemon="/usr/local/bin/rspamd"
daemon_flags="-u _rspamd -g _rspamd"

. /etc/rc.d/rc.subr

pexp="rspamd: main process.*"

rc_pre() {
install -d /var/run/rspamd
}

rc_cmd $1


>
> Also, did you remember to enable the service with "rcctl enable rspamd"
>

Yes, i did it:

rcctl enable redis
rcctl enable rspamd

rcctl start redis
rcctl start rspamd

Thanks to respond.



Re: OpenSMTPD + rspamd to sign mail.

2021-08-12 Thread Chris Eidem

On 8/12/21 5:09 AM, latin...@vcn.bc.ca wrote:

Hello

After:
# pkg_add redis rspamd opensmtpd-filter-rspamd successfully

i got:
# rcctl start rspamd
rspamd(failed)

then I did:
# rspamd -d
2021-08-12 09:23:41 #0(main) ; main; detect_priv: cannot run
rspamd workers as root user, please add -u and -g options to select a
proper unprivilleged user or specify --insecure flag

How to interpret it please?

I did # chown R spamd:_rspamd /etc/mail/dkim but it fails, then i did
  # chown -R root:_spamd /etc/mail/dkim and it worked; anyway i suppose i
should do  rspamd:_rspamd to change -u and -g

thanks for your attention.

What is the contents of your /etc/rc.d/rspamd file? It should include 
lines like:


   daemon="/usr/local/bin/rspamd"
   daemon_flags="-u _rspamd -g _rspamd"

Also, did you remember to enable the service with "rcctl enable rspamd"



OpenSMTPD + rspamd to sign mail.

2021-08-12 Thread latincom
Hello

After:
# pkg_add redis rspamd opensmtpd-filter-rspamd successfully

i got:
# rcctl start rspamd
rspamd(failed)

then I did:
# rspamd -d
2021-08-12 09:23:41 #0(main) ; main; detect_priv: cannot run
rspamd workers as root user, please add -u and -g options to select a
proper unprivilleged user or specify --insecure flag

How to interpret it please?

I did # chown R spamd:_rspamd /etc/mail/dkim but it fails, then i did
 # chown -R root:_spamd /etc/mail/dkim and it worked; anyway i suppose i
should do  rspamd:_rspamd to change -u and -g

thanks for your attention.