Package: dovecot-sieve Version: 1:2.2.18-1 Severity: normal Dear Maintainer,
On my system, sieve-test segfaults on the following minified Sieve script: require ["editheader"]; addheader "foo" "bar"; if header :is "foo" "baz" { } To reproduce, put the above script in script.sieve and do the following: echo > mail cat > dovecot.conf <<EOF plugin { sieve_extensions = +editheader } EOF sieve-test -c dovecot.conf script.sieve mail The sieve-test command should segfault. Here is a backtrace: #0 strlen () at ../sysdeps/x86_64/strlen.S:106 #1 0x00007ffff7b747c7 in _header_right_trim (raw=0x3 <error: Cannot access memory at address 0x3>) at sieve-message.c:492 #2 sieve_message_header_stringlist_next_item (_strlist=0x55555575d120, str_r=0x7fffffffe940) at sieve-message.c:556 #3 0x00007ffff7b8b371 in sieve_stringlist_next_item (str_r=0x7fffffffe940, strlist=0x55555575d120) at sieve-stringlist.h:44 #4 sieve_match (renv=renv@entry=0x555555791ab0, mcht=mcht@entry=0x7fffffffe9d0, cmp=cmp@entry=0x7fffffffe9b0, value_list=0x55555575d120, key_list=0x55555575d0c8, exec_status=exec_status@entry=0x7fffffffe99c) at sieve-match.c:181 #5 0x00007ffff7b91730 in tst_header_operation_execute (renv=0x555555791ab0, address=0x555555791af8) at tst-header.c:193 #6 0x00007ffff7b828f7 in sieve_interpreter_operation_execute (interp=0x555555791a80) at sieve-interpreter.c:542 #7 sieve_interpreter_continue (interp=interp@entry=0x555555791a80, interrupted=interrupted@entry=0x0) at sieve-interpreter.c:573 #8 0x00007ffff7b82a4a in sieve_interpreter_start (interp=interp@entry=0x555555791a80, result=<optimized out>, interrupted=interrupted@entry=0x0) at sieve-interpreter.c:604 #9 0x00007ffff7b82a7b in sieve_interpreter_run (interp=0x555555791a80, result=0x555555798e00) at sieve-interpreter.c:615 #10 0x00007ffff7b94f8f in sieve_run (sbin=0x55555577aeb0, result=result@entry=0x7fffffffeae0, msgdata=0x7fffffffebc0, senv=senv@entry=0x7fffffffebf0, ehandler=0x5555557799e0, flags=<optimized out>) at sieve.c:335 #11 0x00007ffff7b959cc in sieve_test (sbin=<optimized out>, msgdata=<optimized out>, senv=0x7fffffffebf0, ehandler=<optimized out>, stream=0x55555578b6f0, flags=<optimized out>, keep=0x0) at sieve.c:496 #12 0x00005555555577d7 in main (argc=6, argv=0x555555764390) at sieve-test.c:295 sieve-test used to work fine on the (non-minified) script on which it now segfaults, so this bug was probably introduced by a recent version. -- Package-specific info: dovecot configuration --------------------- # 2.2.18: /etc/dovecot/dovecot.conf # OS: Linux 4.0.0-2-amd64 x86_64 Debian stretch/sid mail_location = mbox:~/mail:INBOX=/var/mail/%u namespace inbox { inbox = yes location = mailbox Drafts { special_use = \Drafts } mailbox Junk { special_use = \Junk } mailbox Sent { special_use = \Sent } mailbox "Sent Messages" { special_use = \Sent } mailbox Trash { special_use = \Trash } prefix = } passdb { driver = pam } plugin { sieve = ~/.dovecot.sieve sieve_dir = ~/sieve } ssl = no userdb { driver = passwd } -- System Information: Debian Release: stretch/sid Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 4.0.0-2-amd64 (SMP w/4 CPU cores) Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) Versions of packages dovecot-sieve depends on: ii dovecot-core 1:2.2.18-1 ii libc6 2.19-18 ii ucf 3.0030 dovecot-sieve recommends no packages. dovecot-sieve suggests no packages. Versions of packages dovecot-sieve is related to: ii dovecot-core [dovecot-common] 1:2.2.18-1 ii dovecot-dbg 1:2.2.18-1 pn dovecot-dev <none> pn dovecot-gssapi <none> pn dovecot-imapd <none> pn dovecot-ldap <none> pn dovecot-lmtpd <none> pn dovecot-managesieved <none> pn dovecot-mysql <none> pn dovecot-pgsql <none> pn dovecot-pop3d <none> ii dovecot-sieve 1:2.2.18-1 pn dovecot-sqlite <none> -- no debconf information -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org