Re: sievec: Misleading error message

2023-08-25 Thread Markus Schönhaber
I concur with Horst that there's a typo in the error message that should be corrected. (trivial patch attached) Am 25.08.2023 um 12:38 schrieb Horst Prote: Hi, in a sieve script I just made a syntax error and got this error message on calling sievec:    error: the else command must follow an

Re: sievec: Misleading error message

2023-08-25 Thread Robert Nowotny via dovecot
bit more easy. Am 25.08.2023 um 12:38 schrieb Horst Prote: Hi, in a sieve script I just made a syntax error and got this error message on calling sievec: error: the else command must follow an if or elseif command. My first thougth was "Are you kidding me!" as I used &qu

sievec: Misleading error message

2023-08-25 Thread Horst Prote
Hi, in a sieve script I just made a syntax error and got this error message on calling sievec: error: the else command must follow an if or elseif command. My first thougth was "Are you kidding me!" as I used "elseif". But then I realized that the correct syntax is

Re: sievec *.sieve problem.

2019-11-05 Thread Reio Remma via dovecot
On 05/11/2019 10:03, Sami Ketola via dovecot wrote: On 5 Nov 2019, at 9.53, Reio Remma via dovecot <mailto:dovecot@dovecot.org>> wrote: Hello! For the second time I've tripped onto this banana peel. :) I had 2 sieve files in a directory that I wanted to compile: sievec *.sieve T

Re: sievec *.sieve problem.

2019-11-05 Thread Sami Ketola via dovecot
> On 5 Nov 2019, at 9.53, Reio Remma via dovecot wrote: > > Hello! > > For the second time I've tripped onto this banana peel. :) > > I had 2 sieve files in a directory that I wanted to compile: > > sievec *.sieve > > The result of this is that first.si

sievec *.sieve problem.

2019-11-04 Thread Reio Remma via dovecot
Hello! For the second time I've tripped onto this banana peel. :) I had 2 sieve files in a directory that I wanted to compile: sievec *.sieve The result of this is that first.sieve is compiled into second.sieve instead of first.svbin, thus destroying the source of second.sieve. Please

Re: sievec prints an error if no dovecot running with mail_plugins = stats

2018-06-25 Thread Stephan Bosch
Op 12/06/2018 om 19:28 schreef SATOH Fumiyasu: Dovecot 2.2.36 + Pigeonhole 0.4.24 Is this an intended behavior? ``` # service dovecot status dovecot is stopped # doveconf mail_plugins mail_plugins = stats # ls foo.* foo.sieve # sievec foo.sieve sievec(root): Error: stats: open(/var/run

sievec prints an error if no dovecot running with mail_plugins = stats

2018-06-12 Thread SATOH Fumiyasu
Dovecot 2.2.36 + Pigeonhole 0.4.24 Is this an intended behavior? ``` # service dovecot status dovecot is stopped # doveconf mail_plugins mail_plugins = stats # ls foo.* foo.sieve # sievec foo.sieve sievec(root): Error: stats: open(/var/run/dovecot/stats-mail) failed: No such device or address

Re: Problem in Pigeonhole sievec

2018-05-30 Thread Stephan Bosch
:is ["from","cc"] ["...", ..., "...@... GARBAGE", ...] {   fileinto "inbox.Trash";   stop; } Note the extra line break before GARBAGE. This script is obviously broken, but gets accepted by sievec and only fails later, at runtime with line X: error: fo

Re: Problem in Pigeonhole sievec

2018-05-28 Thread Thorsten Hater
t;...@... >> GARBAGE", ...] { >> fileinto "inbox.Trash"; >> stop; >> } >> >> Note the extra line break before GARBAGE. This script is obviously broken, >> but gets accepted by sievec and only fails later, at runtime with >> &g

Re: Problem in Pigeonhole sievec

2018-05-28 Thread Steffen Kaiser
","cc"] ["...", ..., "...@... GARBAGE", ...] { fileinto "inbox.Trash"; stop; } Note the extra line break before GARBAGE. This script is obviously broken, but gets accepted by sievec and only fails later, at runtime with line X: error: found stray carriage-return

Problem in Pigeonhole sievec

2018-05-28 Thread Thorsten Hater
"inbox.Trash"; stop; } Note the extra line break before GARBAGE. This script is obviously broken, but gets accepted by sievec and only fails later, at runtime with line X: error: found stray carriage-return (CR) character in quoted string started at line X. So, the question is whe

Re: Running sievec as user vmail

2017-04-07 Thread Robert Moskowitz
blem ended up a permissions problem. I ran sievec as root and .svbin needs vmail:mail ownership. I could always just add the chown command to my process, but I wonder if there is some 'clean' way to run sievec as user vmail while logged in as root? thanks

Re: Running sievec as user vmail

2017-04-07 Thread Florian Beer | 42dev
You could give # su -c MYSIEVESCRIPT vmail a try. Also: # man su Cheers, Florian _ 42dev e. U. - web solutions & hosting services http://42dev.eu On 2017-04-07 14:19, Robert Moskowitz wrote: My sieve problem ended up a permissions problem. I ran sievec as

Running sievec as user vmail

2017-04-07 Thread Robert Moskowitz
My sieve problem ended up a permissions problem. I ran sievec as root and .svbin needs vmail:mail ownership. I could always just add the chown command to my process, but I wonder if there is some 'clean' way to run sievec as user vmail while logged in as root? thanks

Re: sievec

2017-03-17 Thread Robert Moskowitz
o the 'create' modifier for 'fileinto'. Also, I would accomplish both things in the same rule using 'anyof' which should be slightly more efficient (which could make a big difference to server load depending on how many users you are supporting). https://support.tigertech.net/sieve Reading t

Re: sievec

2017-03-17 Thread Robert Moskowitz
On 03/17/2017 12:07 AM, Doug Barton wrote: On 03/16/2017 11:50 PM, Robert Moskowitz wrote: Doug, On 03/16/2017 11:23 PM, Doug Barton wrote: Your pattern seems a little too complicated. See below. I acquired this script from:

Re: sievec

2017-03-17 Thread chaouche yacine
All sieve scripts need to be compiled."default" means absence. So default scripts are used when user scripts don't exist. If users have their sieves scripts then the default won't be executed. If you want to impose your script on all users then use sieve_before not sieve_default. For example, I

Re: sievec

2017-03-17 Thread Doug Barton
On 03/16/2017 11:50 PM, Robert Moskowitz wrote: Doug, On 03/16/2017 11:23 PM, Doug Barton wrote: Your pattern seems a little too complicated. See below. I acquired this script from: http://www.campworld.net/thewiki/pmwiki.php/LinuxServersCentOS/Cent6VirtMailServer No telling where he got

Re: sievec

2017-03-17 Thread Robert Moskowitz
Doug, On 03/16/2017 11:23 PM, Doug Barton wrote: Your pattern seems a little too complicated. See below. I acquired this script from: http://www.campworld.net/thewiki/pmwiki.php/LinuxServersCentOS/Cent6VirtMailServer No telling where he got it from. So I greatly appreciate any and all

Re: sievec

2017-03-17 Thread Doug Barton
Your pattern seems a little too complicated. See below. On 03/16/2017 02:20 PM, Robert Moskowitz wrote: if exists "X-Spam-Flag" { This isn't needed. If the flag doesn't exist, the 'if header ...' line won't match. You're doing two tests for every message where one is all that's needed.

Re: sievec

2017-03-16 Thread Robert Moskowitz
e But in 90-sieve.conf there is the comment: # A path to a global sieve script file, which gets executed ONLY # if user's private Sieve script doesn't exist. Be sure to # pre-compile this script manually using the sievec command line # tool. #sieve_global_path = /var/lib/dovecot/sie

Re: sievec

2017-03-16 Thread Stephan Bosch
> > chown -R vmail:mail /home/sieve > > But in 90-sieve.conf there is the comment: > > # A path to a global sieve script file, which gets executed ONLY > # if user's private Sieve script doesn't exist. Be sure to > # pre-compile this script manually using the sievec c

sievec

2017-03-16 Thread Robert Moskowitz
d ONLY # if user's private Sieve script doesn't exist. Be sure to # pre-compile this script manually using the sievec command line # tool. #sieve_global_path = /var/lib/dovecot/sieve/default.sieve Do I run sievec on this script? And I found the following comment on a blog, about 3

sievec drops privileges unexpectedly

2014-06-25 Thread Matthijs Kooijman
/default need to be pre-compiled using the sievec tool Due to the lack of permissions, this is of course expected. However, when I then try to precompile the script using sievec, that also fails: # sievec /etc/dovecot/sieve/default sievec(root): Error: sieve: binary save: failed to create temporary

Re: sievec drops privileges unexpectedly

2014-06-25 Thread Stephan Bosch
Hi Matthijs, Matthijs Kooijman schreef op 25-6-2014 14:53: Now I wrote this, I realized that it might be related that I have specified mail_uid and mail_gid globally in my dovecot.conf file. Perhaps those are intended to only be put inside the protocol imap and protocol lda blocks? This would

Re: sievec drops privileges unexpectedly

2014-06-25 Thread Matthijs Kooijman
Hey Stephan, # 2.1.7: /etc/dovecot/dovecot.conf This is a very old and obsolete version. This problem was fixed almost two years ago: Ah, cool. This is what Debian/stable ships, so I'll probably stick to this version for a while. Good to hear it's already fixed, then I'll just work around

[Dovecot] recover .sieve plaintext from .sievec binary file

2012-07-09 Thread Florin Andrei
Hi, I upgraded a server from an old Linux distribution to a much newer one. In the process, Dovecot got upgraded from v1 to v2. By mistake, I deleted the .sieve plaintext file with all the Sieve filters, but I still do have the .sievec compiled binary. Is there any way to dump the binary

Re: [Dovecot] recover .sieve plaintext from .sievec binary file

2012-07-09 Thread Pascal Volk
On 07/09/2012 10:28 PM Florin Andrei wrote: … By mistake, I deleted the .sieve plaintext file with all the Sieve filters, but I still do have the .sievec compiled binary. Is there any way to dump the binary file back into plaintext format? Keep in mind, I'm running v2 now, and the binary

Re: [Dovecot] recover .sieve plaintext from .sievec binary file

2012-07-09 Thread Florin Andrei
On 07/09/2012 01:46 PM, Pascal Volk wrote: On 07/09/2012 10:28 PM Florin Andrei wrote: … By mistake, I deleted the .sieve plaintext file with all the Sieve filters, but I still do have the .sievec compiled binary. Is there any way to dump the binary file back into plaintext format? Keep in mind

Re: [Dovecot] recover .sieve plaintext from .sievec binary file

2012-07-09 Thread Stephan Bosch
On 7/9/2012 10:53 PM, Florin Andrei wrote: On 07/09/2012 01:46 PM, Pascal Volk wrote: On 07/09/2012 10:28 PM Florin Andrei wrote: … By mistake, I deleted the .sieve plaintext file with all the Sieve filters, but I still do have the .sievec compiled binary. Is there any way to dump the binary

Re: [Dovecot] recover .sieve plaintext from .sievec binary file

2012-07-09 Thread Florin Andrei
On 07/09/2012 03:00 PM, Stephan Bosch wrote: And then you still have a problem. The sieved tool does not reconstruct the sieve script that was used to create it; it produces an assembly-like output from the byte code. You'd have to manually translate that back to Sieve. :/ Looks like I'll

[Dovecot] sievec segfaults

2012-04-24 Thread interfaSys sàrl
Hello, sievec segfaults when it reads a file. I've tried with both the standard and gold linker. I've tried with various sieve files and they all make it crash. I've compiled pigeonhole with -ggdb, but I'm not getting much info Program received signal SIGSEGV, Segmentation fault

Re: [Dovecot] sievec segfaults

2012-04-24 Thread Stephan Bosch
Op 4/24/2012 6:31 PM, interfaSys sàrl schreef: Hello, sievec segfaults when it reads a file. I've tried with both the standard and gold linker. I've tried with various sieve files and they all make it crash. What version? Regards, Stephan.

Re: [Dovecot] sievec segfaults

2012-04-24 Thread interfaSys sàrl
I pulled the latest code from the dovecot-2.1-pigeonhole repository. Cheers, Olivier On 24/04/2012 18:10, Stephan Bosch wrote: Op 4/24/2012 6:31 PM, interfaSys sàrl schreef: Hello, sievec segfaults when it reads a file. I've tried with both the standard and gold linker. I've tried

Re: [Dovecot] sievec segfaults

2012-04-24 Thread interfaSys sàrl
schreef: Hello, sievec segfaults when it reads a file. I've tried with both the standard and gold linker. I've tried with various sieve files and they all make it crash. What version? Regards, Stephan.

Re: [Dovecot] sievec segfaults

2012-04-24 Thread Stephan Bosch
Op 4/24/2012 7:14 PM, interfaSys sàrl schreef: I pulled the latest code from the dovecot-2.1-pigeonhole repository. This is caused by the recent addition of dict database support for storing Sieve scripts. This should fix it: http://hg.rename-it.nl/dovecot-2.1-pigeonhole/rev/93bfa75d9ab9

Re: [Dovecot] sievec segfaults

2012-04-24 Thread interfaSys sàrl
It worked! :) Thank you. Olivier On 24/04/2012 18:34, Stephan Bosch wrote: Op 4/24/2012 7:14 PM, interfaSys sàrl schreef: I pulled the latest code from the dovecot-2.1-pigeonhole repository. This is caused by the recent addition of dict database support for storing Sieve scripts. This

Re: [Dovecot] sievec - manual compile of global sieve scripts?

2011-08-02 Thread Thomas Harold
On 8/1/2011 8:43 PM, Stephan Bosch wrote: On 8/1/2011 10:11 PM, Thomas Harold wrote: How do you compile global scripts using the sievec command without making the script directory owned (and group writable) by the vmail user? http://wiki2.dovecot.org/Pigeonhole/Sieve/Usage # cd /etc/dovecot

Re: [Dovecot] sievec - manual compile of global sieve scripts?

2011-08-02 Thread Stephan Bosch
On 8/2/2011 2:32 PM, Thomas Harold wrote: On 8/1/2011 8:43 PM, Stephan Bosch wrote: On 8/1/2011 10:11 PM, Thomas Harold wrote: How do you compile global scripts using the sievec command without making the script directory owned (and group writable) by the vmail user? http://wiki2

Re: [Dovecot] sievec - manual compile of global sieve scripts?

2011-08-02 Thread Patrick Domack
Mine has always behaved like this. It looks up the root user in the auth database from the dovecot config, and attemps to change to that user, and in this type of case that would be vmail. Then it attempts to check the mail_home and kind of fails, unless you give vmail permission to that

[Dovecot] sievec - manual compile of global sieve scripts?

2011-08-01 Thread Thomas Harold
How do you compile global scripts using the sievec command without making the script directory owned (and group writable) by the vmail user? http://wiki2.dovecot.org/Pigeonhole/Sieve/Usage # cd /etc/dovecot/sieve/before/ # (edit some script like spam.sieve that runs for everyone) # /usr/local

Re: [Dovecot] sievec - manual compile of global sieve scripts?

2011-08-01 Thread Stephan Bosch
On 8/1/2011 10:11 PM, Thomas Harold wrote: How do you compile global scripts using the sievec command without making the script directory owned (and group writable) by the vmail user? http://wiki2.dovecot.org/Pigeonhole/Sieve/Usage # cd /etc/dovecot/sieve/before/ # (edit some script like

Re: [Dovecot] Sieve 0.2.2 how to use sievec

2011-01-18 Thread Timo Sirainen
On 17.1.2011, at 10.02, Nikita Koshikov wrote: sievec(root): Error: user root: Initialization failed: Namespace '': mkdir(/root/data) failed: Permission denied (euid=8(mail) egid=12(mail) missing +w perm: /root, euid is not dir owner) Show your doveconf -n output.

Re: [Dovecot] Sieve 0.2.2 how to use sievec

2011-01-18 Thread Charles Marcus
On 2011-01-18 5:04 AM, Nikita Koshikov wrote: 2.6.26-gentoo-r4 i686 Gentoo Base System release 1.12.14 Why are you using a kernel that is no longer even in portage? -- Best regards, Charles

Re: [Dovecot] Sieve 0.2.2 how to use sievec

2011-01-18 Thread Nikita Koshikov
On Tue, 18 Jan 2011 06:23:42 -0500 Charles Marcus wrote: On 2011-01-18 5:04 AM, Nikita Koshikov wrote: 2.6.26-gentoo-r4 i686 Gentoo Base System release 1.12.14 Why are you using a kernel that is no longer even in portage? It just working and well tested under current server's hardware.

[Dovecot] Sieve 0.2.2 how to use sievec

2011-01-17 Thread Nikita Koshikov
Hello list, How can I compile sieve script under new 0.2.2 version from comandline? Under root: #sievec default-before.sieve sievec(root): Error: user root: Initialization failed: Namespace '': mkdir(/root/data) failed: Permission denied (euid=8(mail) egid=12(mail) missing +w perm: /root

Re: [Dovecot] Sieve 0.2.2 how to use sievec

2011-01-17 Thread fakessh @
I managed to run in the root folder lda and sievec . I add the group mail to root more +w flag and everything should work properly Le lundi 17 janvier 2011 à 10:02 +0200, Nikita Koshikov a écrit : Hello list, How can I compile sieve script under new 0.2.2 version from comandline? Under

Re: [Dovecot] Sieve 0.2.2 how to use sievec

2011-01-17 Thread Nikita Koshikov
On Tue, 18 Jan 2011 01:02:14 +0100 fakessh @ wrote: I managed to run in the root folder lda and sievec . I add the group mail to root more +w flag and everything should work properly My global scripts located in /etc/dovecot/sieve. IMHO it's not a good idea to allow write access

Re: [Dovecot] Roff typo in sievec.1.in

2010-08-27 Thread Stephan Bosch
Mike Abbott wrote: There is a roff typo in pigeonhole's sievec.1.in. Roff treats the leading apostrophe on line 54 as an invalid command and produces bad output: dump to be written to stdout. The out-file argument may also be omitted, which has the same effect

[Dovecot] Roff typo in sievec.1.in

2010-08-26 Thread Mike Abbott
There is a roff typo in pigeonhole's sievec.1.in. Roff treats the leading apostrophe on line 54 as an invalid command and produces bad output: dump to be written to stdout. The out-file argument may also be omitted, which has the same effect as for a com

[Dovecot] exit codes for 'sievec'

2010-05-03 Thread Jerry
As far as I can tell, 'sievec' always exits with '0' whether there is an error or not. If that is correct, I believe it should be modified to exit with some other code if the conversion and writing of the new file are not completed successfully. I have written a few script files and a 'make' file

Re: [Dovecot] exit codes for 'sievec'

2010-05-03 Thread Stephan Bosch
Jerry wrote: As far as I can tell, 'sievec' always exits with '0' whether there is an error or not. If that is correct, I believe it should be modified to exit with some other code if the conversion and writing of the new file are not completed successfully. I have written a few script files

Re: [Dovecot] exit codes for 'sievec'

2010-05-03 Thread Jerry
On Mon, 03 May 2010 20:05:45 +0200 Stephan step...@rename-it.nl articulated: Jerry wrote: As far as I can tell, 'sievec' always exits with '0' whether there is an error or not. If that is correct, I believe it should be modified to exit with some other code if the conversion and writing

Re: [Dovecot] sievec fails when last line is a comment without trailing \n

2009-10-11 Thread Peter Marschall
Hi, On Sunday, 4. October 2009, Stephan Bosch wrote: Peter Marschall wrote: [.. comment as last line in sieve files ... ] In the spirit of be generous in what you accept but strict in what you send, is it possible for sievec to not throw an error in this case, but simply compile

Re: [Dovecot] sievec fails when last line is a comment without trailing \n

2009-10-04 Thread Stephan Bosch
Peter Marschall wrote: Hi, when switching from Dovecot 1.1 + cmusieve to Dovecot 1.2 + sieve I stumbled upon the following problem: My sieve files, generated with Dovecot 1.1's managesieve, did not compile anymore with sieve's sievec. The error message was: error: end of file before end

[Dovecot] sievec fails when last line is a comment without trailing \n

2009-10-02 Thread Peter Marschall
Hi, when switching from Dovecot 1.1 + cmusieve to Dovecot 1.2 + sieve I stumbled upon the following problem: My sieve files, generated with Dovecot 1.1's managesieve, did not compile anymore with sieve's sievec. The error message was: error: end of file before end of hash comment

Re: [Dovecot] sievec error: fileinto require missing

2009-06-29 Thread Braden McDaniel
On Sun, 2009-06-28 at 11:33 +0200, Thomas Leuxner wrote: On Sun, Jun 28, 2009 at 05:25:28AM -0400, Braden McDaniel wrote: .dovecot.sieve just looks like this: $ cat .dovecot.sieve if header :contains [List-Id] [dovecot.dovecot.org] { fileinto

Re: [Dovecot] sievec error: fileinto require missing

2009-06-28 Thread Thomas Leuxner
On Sun, Jun 28, 2009 at 05:25:28AM -0400, Braden McDaniel wrote: .dovecot.sieve just looks like this: $ cat .dovecot.sieve if header :contains [List-Id] [dovecot.dovecot.org] { fileinto INBOX.dovecot; stop; } You need to include the