Re: sievescript is not working

2018-07-12 Thread Stephan Bosch




Op 22/06/2018 om 12:57 schreef ratatouille:

Benny Pedersen  schrieb am 22.06.18 um 03:32:26 Uhr:


ratatouille skrev den 2018-06-21 20:25:


# sieve-test ./managesieve.sieve ./testfile -D
sieve-test(andreas): Debug: sieve: Pigeonhole version 0.4.2
initializing
sieve-test(andreas): Debug: sieve: include: sieve_global_dir is not
set; it is currently not possible to include `:global' scripts.
debug: script binary ./managesieve.svbin is not up-to-date.
debug: script `managesieve' from ./managesieve.sieve successfully
compiled.

what happends if runned again now ?

it seem it was not compiled before

remember only content in svbin is used

Since I defined mailbox_command = /usr/lib/dovecot/dovecot-lda -f "$SENDER" -a 
"$RECIPIENT"
in main.cf of postfix I have some more problems.

Jun 22 12:36:45 bitmachine1 postfix/smtpd[31220]: connect from 
smtp.amimanera.de[2a02:248:2:3377:5054:ff:fe80:307]
Jun 22 12:36:45 bitmachine1 postfix/smtpd[31220]: Trusted TLS connection 
established from smtp.amimanera.de[2a02:248:2:3377:5054:ff:fe80:307]: TLSv1.2 
with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)
Jun 22 12:36:47 bitmachine1 postgrey[2377]: action=pass, reason=triplet found, 
client_name=smtp.amimanera.de, client_address=2a02:248:2:3377:5054:ff:fe80:307, 
sender=andr...@amimanera.de, recipient=a.me...@bitcorner.de
Jun 22 12:36:47 bitmachine1 postfix/smtpd[31220]: NOQUEUE: 
client=smtp.amimanera.de[2a02:248:2:3377:5054:ff:fe80:307]
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31224]: connect from 
localhost[127.0.0.1]
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31224]: 0DAC7219AE: 
client=localhost[127.0.0.1]
Jun 22 12:36:51 bitmachine1 postfix/cleanup[31225]: 0DAC7219AE: 
message-id=<20180622123414.08aac41d@workstation>
Jun 22 12:36:51 bitmachine1 postfix/qmgr[23073]: 0DAC7219AE: 
from=, size=1826, nrcpt=1 (queue active)
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31224]: disconnect from 
localhost[127.0.0.1]
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31220]: proxy-accept: END-OF-MESSAGE: 250 2.0.0 from 
MTA(smtp:[127.0.0.1]:10025): 250 2.0.0 Ok: queued as 0DAC7219AE; 
from= to= proto=ESMTP 
helo=
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31220]: disconnect from 
smtp.amimanera.de[2a02:248:2:3377:5054:ff:fe80:307]
Jun 22 12:36:51 bitmachine1 postfix/local[31226]: 0DAC7219AE: to=, 
relay=local, delay=0.31, delays=0.04/0.03/0/0.23, dsn=2.0.0, status=sent (delivered to command: 
/usr/lib/dovecot/dovecot-lda -f "$SENDER" -a "$RECIPIENT")
Jun 22 12:36:51 bitmachine1 postfix/qmgr[23073]: 0DAC7219AE: removed

But the mail is not stored in the mailbox of the user. This is from 
dovecot-debug.log:

Jun 22 12:36:51 lda(a.meyer): Debug: acl: initializing backend with data: vfile
Jun 22 12:36:51 lda(a.meyer): Debug: acl: acl username = a.meyer
Jun 22 12:36:51 lda(a.meyer): Debug: acl: owner = 0
Jun 22 12:36:51 lda(a.meyer): Debug: acl vfile: Global ACLs disabled
Jun 22 12:36:51 lda(a.meyer): Debug: userdb lookup skipped, username taken from 
USER environment
Jun 22 12:36:51 lda(a.meyer): Debug: Quota root: name=User quota 
backend=maildir args=
Jun 22 12:36:51 lda(a.meyer): Debug: Quota rule: root=User quota mailbox=* 
bytes=1073741824 messages=0
Jun 22 12:36:51 lda(a.meyer): Debug: Quota rule: root=User quota mailbox=Trash 
bytes=+21474836 (2%) messages=0
Jun 22 12:36:51 lda(a.meyer): Debug: Quota grace: root=User quota 
bytes=10737418 (1%)
Jun 22 12:36:51 lda(a.meyer): Debug: none: root=, index=, indexpvt=, control=, 
inbox=, alt=
Jun 22 12:36:51 lda(a.meyer): Debug: Destination address: a.me...@bitcorner.de 
(source: -a parameter)
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: Pigeonhole version 0.4.2 
initializing
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: include: sieve_global_dir is not 
set; it is currently not possible to include `:global' scripts.
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: script file 
/home/a.meyer/.dovecot.sieve not found
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: user's script ~/.dovecot.sieve 
doesn't exist (trying default script location instead)
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: no default script configured for 
user
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: user has no valid location for a 
personal script
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: no scripts to execute: reverting to 
default delivery.

 From dovecot-lda.log:

Jun 22 12:36:51 lda(a.meyer): Info: 
msgid=<20180622123414.08aac41d@workstation>: saved mail to INBOX


This means no Sieve script was found for this user.


But the mail is not there.


That is weird.. are you sure you're looking at the correct user?


I'll disable mailbox_command now until I understand how to enable sieve for 
systemusers.
For virtual users sieve works without problem.


That shouldn't really work differently.


The question is how do I enable sieve for systemusers. I guess it must be with 
the help of lda.


Either LDA or LMTP.

Regards,

Stephan.



Re: sievescript is not working

2018-06-22 Thread ratatouille
Benny Pedersen  schrieb am 22.06.18 um 03:32:26 Uhr:

> ratatouille skrev den 2018-06-21 20:25:
> 
> > # sieve-test ./managesieve.sieve ./testfile -D
> > sieve-test(andreas): Debug: sieve: Pigeonhole version 0.4.2 
> > initializing
> > sieve-test(andreas): Debug: sieve: include: sieve_global_dir is not
> > set; it is currently not possible to include `:global' scripts.
> > debug: script binary ./managesieve.svbin is not up-to-date.
> > debug: script `managesieve' from ./managesieve.sieve successfully 
> > compiled.  
> 
> what happends if runned again now ?
> 
> it seem it was not compiled before
> 
> remember only content in svbin is used

Since I defined mailbox_command = /usr/lib/dovecot/dovecot-lda -f "$SENDER" -a 
"$RECIPIENT"
in main.cf of postfix I have some more problems.

Jun 22 12:36:45 bitmachine1 postfix/smtpd[31220]: connect from 
smtp.amimanera.de[2a02:248:2:3377:5054:ff:fe80:307]
Jun 22 12:36:45 bitmachine1 postfix/smtpd[31220]: Trusted TLS connection 
established from smtp.amimanera.de[2a02:248:2:3377:5054:ff:fe80:307]: TLSv1.2 
with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)
Jun 22 12:36:47 bitmachine1 postgrey[2377]: action=pass, reason=triplet found, 
client_name=smtp.amimanera.de, client_address=2a02:248:2:3377:5054:ff:fe80:307, 
sender=andr...@amimanera.de, recipient=a.me...@bitcorner.de
Jun 22 12:36:47 bitmachine1 postfix/smtpd[31220]: NOQUEUE: 
client=smtp.amimanera.de[2a02:248:2:3377:5054:ff:fe80:307]
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31224]: connect from 
localhost[127.0.0.1]
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31224]: 0DAC7219AE: 
client=localhost[127.0.0.1]
Jun 22 12:36:51 bitmachine1 postfix/cleanup[31225]: 0DAC7219AE: 
message-id=<20180622123414.08aac41d@workstation>
Jun 22 12:36:51 bitmachine1 postfix/qmgr[23073]: 0DAC7219AE: 
from=, size=1826, nrcpt=1 (queue active)
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31224]: disconnect from 
localhost[127.0.0.1]
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31220]: proxy-accept: END-OF-MESSAGE: 
250 2.0.0 from MTA(smtp:[127.0.0.1]:10025): 250 2.0.0 Ok: queued as 0DAC7219AE; 
from= to= proto=ESMTP 
helo=
Jun 22 12:36:51 bitmachine1 postfix/smtpd[31220]: disconnect from 
smtp.amimanera.de[2a02:248:2:3377:5054:ff:fe80:307]
Jun 22 12:36:51 bitmachine1 postfix/local[31226]: 0DAC7219AE: 
to=, relay=local, delay=0.31, delays=0.04/0.03/0/0.23, 
dsn=2.0.0, status=sent (delivered to command: /usr/lib/dovecot/dovecot-lda -f 
"$SENDER" -a "$RECIPIENT")
Jun 22 12:36:51 bitmachine1 postfix/qmgr[23073]: 0DAC7219AE: removed

But the mail is not stored in the mailbox of the user. This is from 
dovecot-debug.log:

Jun 22 12:36:51 lda(a.meyer): Debug: acl: initializing backend with data: vfile
Jun 22 12:36:51 lda(a.meyer): Debug: acl: acl username = a.meyer
Jun 22 12:36:51 lda(a.meyer): Debug: acl: owner = 0
Jun 22 12:36:51 lda(a.meyer): Debug: acl vfile: Global ACLs disabled
Jun 22 12:36:51 lda(a.meyer): Debug: userdb lookup skipped, username taken from 
USER environment
Jun 22 12:36:51 lda(a.meyer): Debug: Quota root: name=User quota 
backend=maildir args=
Jun 22 12:36:51 lda(a.meyer): Debug: Quota rule: root=User quota mailbox=* 
bytes=1073741824 messages=0
Jun 22 12:36:51 lda(a.meyer): Debug: Quota rule: root=User quota mailbox=Trash 
bytes=+21474836 (2%) messages=0
Jun 22 12:36:51 lda(a.meyer): Debug: Quota grace: root=User quota 
bytes=10737418 (1%)
Jun 22 12:36:51 lda(a.meyer): Debug: none: root=, index=, indexpvt=, control=, 
inbox=, alt=
Jun 22 12:36:51 lda(a.meyer): Debug: Destination address: a.me...@bitcorner.de 
(source: -a parameter)
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: Pigeonhole version 0.4.2 
initializing
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: include: sieve_global_dir is not 
set; it is currently not possible to include `:global' scripts.
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: script file 
/home/a.meyer/.dovecot.sieve not found
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: user's script ~/.dovecot.sieve 
doesn't exist (trying default script location instead)
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: no default script configured for 
user
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: user has no valid location for a 
personal script
Jun 22 12:36:51 lda(a.meyer): Debug: sieve: no scripts to execute: reverting to 
default delivery.

From dovecot-lda.log:

Jun 22 12:36:51 lda(a.meyer): Info: 
msgid=<20180622123414.08aac41d@workstation>: saved mail to INBOX

But the mail is not there.

I'll disable mailbox_command now until I understand how to enable sieve for 
systemusers.
For virtual users sieve works without problem.

The question is how do I enable sieve for systemusers. I guess it must be with 
the help of lda.

Kind regards

  Andreas


Re: sievescript is not working

2018-06-21 Thread Benny Pedersen

ratatouille skrev den 2018-06-21 20:25:


# sieve-test ./managesieve.sieve ./testfile -D
sieve-test(andreas): Debug: sieve: Pigeonhole version 0.4.2 
initializing

sieve-test(andreas): Debug: sieve: include: sieve_global_dir is not
set; it is currently not possible to include `:global' scripts.
debug: script binary ./managesieve.svbin is not up-to-date.
debug: script `managesieve' from ./managesieve.sieve successfully 
compiled.


what happends if runned again now ?

it seem it was not compiled before

remember only content in svbin is used