Codebase list cyrus-imapd / c1a1e89
Imported Upstream version 2.4.12 Ondřej Surý 12 years ago
85 changed file(s) with 639 addition(s) and 274 deletion(s). Raw diff Collapse all Expand all
6363 COMPILE_ET = @COMPILE_ET@
6464
6565 PACKAGE = cyrus-imapd
66 VERSION = 2.4.11
66 VERSION = 2.4.12
6767 GIT_VERSION = $(VERSION).git$(shell date +'%Y%m%d%H%M')
6868
6969 all:: xversion
72007200 fi
72017201
72027202
7203 if test "$ac_cv_header_pcreposix_h" == "yes"; then
7203 if test "$ac_cv_header_pcreposix_h" = "yes"; then
72047204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for utf8 enabled pcre" >&5
72057205 $as_echo_n "checking for utf8 enabled pcre... " >&6; }
72067206 if ${cyrus_cv_pcre_utf8+:} false; then :
72287228 fi
72297229 fi
72307230
7231 if test "$cyrus_cv_pcre_utf8" == "yes"; then
7231 if test "$cyrus_cv_pcre_utf8" = "yes"; then
72327232 LIBS="$LIBS -lpcre -lpcreposix";
72337233
72347234 $as_echo "#define ENABLE_REGEX /**/" >>confdefs.h
72497249
72507250 done
72517251
7252 if test "$ac_cv_header_rxposix_h" == "yes"; then
7252 if test "$ac_cv_header_rxposix_h" = "yes"; then
72537253 LIBS="$LIBS -lrx"
72547254
72557255 $as_echo "#define ENABLE_REGEX /**/" >>confdefs.h
402402
403403 if test "$testpcre" != "no"; then
404404 AC_CHECK_HEADER(pcreposix.h)
405 if test "$ac_cv_header_pcreposix_h" == "yes"; then
405 if test "$ac_cv_header_pcreposix_h" = "yes"; then
406406 AC_MSG_CHECKING(for utf8 enabled pcre)
407407 AC_CACHE_VAL(cyrus_cv_pcre_utf8, AC_TRY_CPP([#include <pcreposix.h>
408408 #ifndef REG_UTF8
414414 fi
415415 fi
416416
417 if test "$cyrus_cv_pcre_utf8" == "yes"; then
417 if test "$cyrus_cv_pcre_utf8" = "yes"; then
418418 LIBS="$LIBS -lpcre -lpcreposix";
419419 AC_DEFINE(ENABLE_REGEX, [], [Do we have a regex library?])
420420 AC_DEFINE(HAVE_PCREPOSIX_H, [], [Do we have usable pcre library?])
421421 else
422422 AC_CHECK_HEADERS(rxposix.h)
423 if test "$ac_cv_header_rxposix_h" == "yes"; then
423 if test "$ac_cv_header_rxposix_h" = "yes"; then
424424 LIBS="$LIBS -lrx"
425425 AC_DEFINE(ENABLE_REGEX, [],
426426 [Do we have a regex library?])
66 <title>Changes to the Cyrus IMAP Server</title>
77 </head>
88 <body>
9
10
11 <h1>Changes to the Cyrus IMAP Server since 2.4.11</h1>
12 <ul>
13 <li>Bug #3150 - fix issue with overview and messages without
14 a References header</li>
15 <li>fixed nntp login with tab and space in password</li>
16 <li>Bug #3501 - be more relaxed about names of DELETED folders</li>
17 <li>Bug #3553 - fix QRESYNC passing to murder backend - thanks
18 alec &lt;alec@alec.pl&gt;</li>
19 <li>Bug #3554 - only show ENABLED response the first time each
20 option is ENABLEd</li>
21 <li>Lots of cleanup of build process and backporting of APIs</li>
22 <li>Bug #3502 - make configure.in more portable - thanks
23 OBATA Akio &lt;obata@lins.jp&gt;</li>
24 <li>Bug #3533 - add missing break statements in sieve -
25 thanks Thomas Jarosch &lt;thomas.jarosch@intra2net.com&gt;</li>
26 <li>Bug #3550 - support wildcards for ACLS in cyradm -
27 thanks &lt;mark.cave-ayland@siriusit.co.uk&gt;</li>
28 <li>Bug #3556 - print remote server in mbpath -
29 thanks Wolfgang Breyha &lt;wbreyha@gmx.net&gt;</li>
30 <li>Bug #3559 - make XFER work with unlimited quota -
31 thanks Wolfgang Breyha &lt;wbreyha@gmx.net&gt;</li>
32 <li>Bug #3547 - use strconcat() in writefile()</li>
33 <li>fixed a case where skiplist library could write error
34 messages directly to stdout</li>
35 <li>Bug #3545 - fix sign extension in squat_decode_64</li>
36 <li>Bug #3558 - return error if backend doesn't support
37 LIST-EXTENDED</li>
38 <li>Bug #3565 - clean up in preparation for automake</li>
39 <li>fixed incomplete authentication checks in nntpd,
40 reported by Secunia as SA46093</li>
41 </ul>
942
1043 <h1>Changes to the Cyrus IMAP Server since 2.4.10</h1>
1144 <ul>
66 <body>
77
88 <h1>Upgrading From Previous Versions</h1>
9
10 <h1>Upgrading from 2.4.11</h2>
11 <ul>
12 <li>To support bug-interoperability with older versions of Cyrus,
13 the quota command now supports "-1" as a synonym for
14 unlimited storage</li>
15 </ul>
916
1017 <h1>Upgrading from 2.4.10</h2>
1118 <ul>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:38 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:49 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:38 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:49 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:38 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:49 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:38 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:49 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:38 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:49 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:38 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:49 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:39 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:50 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
10971097
10981098 <p style="margin-left:18%; margin-top: 1em">Allowed values:
10991099 <i>header</i>, <i>index</i>, <i>cache</i>, <i>expunge</i>,
1100 <i>squat</i>, <i>lock</i></p>
1100 <i>squat</i></p>
11011101
11021102 <p style="margin-left:11%;"><b>metapartition-name:</b>
11031103 &lt;none&gt;</p>
18981898 <p style="margin-left:18%;">Suppress the named capabilities
18991899 from any capability response. Use the exact case as it
19001900 appears in the response, e.g. &quot;suppress_capabilities:
1901 ESEARCH QRESYNC WITHIN XLIST&quot; if you have a murder with
1902 2.3.x backends and don&rsquo;t want clients being confused
1903 by new capabilities that some backends don&rsquo;t
1904 support.</p>
1901 ESEARCH QRESYNC WITHIN XLIST LIST-EXTENDED&quot; if you have
1902 a murder with 2.3.x backends and don&rsquo;t want clients
1903 being confused by new capabilities that some backends
1904 don&rsquo;t support.</p>
19051905
19061906 <p style="margin-left:11%;"><b>statuscache:</b> 0</p>
19071907
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:40 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:51 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:41 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:52 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:42 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:53 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:42 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:53 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:42 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:53 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:42 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:53 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:42 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:53 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:42 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:53 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:42 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:53 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
00 <!-- Creator : groff version 1.21 -->
1 <!-- CreationDate: Thu Sep 8 21:03:42 2011 -->
1 <!-- CreationDate: Tue Oct 4 22:03:53 2011 -->
22 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
33 "http://www.w3.org/TR/html4/loose.dtd">
44 <html>
0 Changes to the Cyrus IMAP Server since 2.4.11
1
2 * Bug #3150 - fix issue with overview and messages without a
3 References header
4 * fixed nntp login with tab and space in password
5 * Bug #3501 - be more relaxed about names of DELETED folders
6 * Bug #3553 - fix QRESYNC passing to murder backend - thanks alec
7 <alec@alec.pl>
8 * Bug #3554 - only show ENABLED response the first time each option
9 is ENABLEd
10 * Lots of cleanup of build process and backporting of APIs
11 * Bug #3502 - make configure.in more portable - thanks OBATA Akio
12 <obata@lins.jp>
13 * Bug #3533 - add missing break statements in sieve - thanks Thomas
14 Jarosch <thomas.jarosch@intra2net.com>
15 * Bug #3550 - support wildcards for ACLS in cyradm - thanks
16 <mark.cave-ayland@siriusit.co.uk>
17 * Bug #3556 - print remote server in mbpath - thanks Wolfgang Breyha
18 <wbreyha@gmx.net>
19 * Bug #3559 - make XFER work with unlimited quota - thanks Wolfgang
20 Breyha <wbreyha@gmx.net>
21 * Bug #3547 - use strconcat() in writefile()
22 * fixed a case where skiplist library could write error messages
23 directly to stdout
24 * Bug #3545 - fix sign extension in squat_decode_64
25 * Bug #3558 - return error if backend doesn't support LIST-EXTENDED
26 * Bug #3565 - clean up in preparation for automake
27 * fixed incomplete authentication checks in nntpd, reported by
28 Secunia as SA46093
29
030 Changes to the Cyrus IMAP Server since 2.4.10
131
232 * fixed replication recovery from different messages at the each end
346346 $(CC) $(LDFLAGS) -o $@ unexpunge.o $(CLIOBJS) \
347347 libimap.a $(DEPLIBS) $(LIBS)
348348
349 make_md5: make_md5.o libimap.a mutex_fake.o $(DEPLIBS)
350 $(CC) $(LDFLAGS) -o make_md5 make_md5.o libimap.a mutex_fake.o $(DEPLIBS) $(LIBS)
351
352 make_sha1: make_sha1.o libimap.a mutex_fake.o $(DEPLIBS)
353 $(CC) $(LDFLAGS) -o make_sha1 make_sha1.o libimap.a mutex_fake.o $(DEPLIBS) $(LIBS)
354
355349 sync_client: sync_client.o sync_support.o \
356350 backend.o tls.o imapparse.o libimap.a mutex_fake.o $(DEPLIBS)
357351 $(CC) $(LDFLAGS) -o \
14251425 theentry.value = value ? value : "NIL";
14261426
14271427 return write_entry(mboxname, entry, userid, &theentry, tid);
1428 }
1429
1430 int annotatemore_commit(struct txn *tid) {
1431 return tid ? DB->commit(anndb, tid) : 0;
1432 }
1433
1434 int annotatemore_abort(struct txn *tid) {
1435 return tid ? DB->abort(anndb, tid) : 0;
14281436 }
14291437
14301438 struct storedata {
22742282 ae = xmalloc(sizeof(struct annotate_st_entry));
22752283
22762284 p2 = p;
2277 for (; *p && (isalnum(*p) || *p=='.' || *p=='-' || *p=='_' || *p=='/');
2285 for (; *p && (isalnum(*p) ||
2286 *p=='.' || *p=='-' || *p=='_' || *p=='/' || *p==':');
22782287 p++);
22792288 /* TV-TODO: should test for empty */
22802289 ae->name = xstrndup(p2, p-p2);
142142 const char *value, const char *contenttype,
143143 size_t size, time_t modifiedsince,
144144 struct txn **tid);
145 int annotatemore_commit(struct txn *tid);
146 int annotatemore_abort(struct txn *tid);
145147
146148 /* rename the annotations for 'oldmboxname' to 'newmboxname'
147149 * if 'olduserid' is non-NULL then the private annotations
438438 static int subscribed_cb(const char *name, int matchlen, int maycreate,
439439 struct list_rock *rock);
440440 static void list_data(struct listargs *listargs);
441 static void list_data_remote(char *tag, struct listargs *listargs);
441 static int list_data_remote(char *tag, struct listargs *listargs);
442442
443443 extern int saslserver(sasl_conn_t *conn, const char *mech,
444444 const char *init_resp, const char *resp_prefix,
36573657 prot_printf(backend_current->out, "%s %s {" SIZE_T_FMT "+}\r\n%s",
36583658 tag, cmd, strlen(name), name);
36593659 if (v->uidvalidity) {
3660 prot_printf(backend_current->out, " (QRESYNC %lu " MODSEQ_FMT,
3660 prot_printf(backend_current->out, " (QRESYNC (%lu " MODSEQ_FMT,
36613661 v->uidvalidity, v->modseq);
36623662 if (v->sequence) {
36633663 prot_printf(backend_current->out, " %s", v->sequence);
36663666 prot_printf(backend_current->out, " (%s %s)",
36673667 v->match_seq, v->match_uid);
36683668 }
3669 prot_printf(backend_current->out, ")");
3669 prot_printf(backend_current->out, "))");
36703670 }
36713671 prot_printf(backend_current->out, "\r\n");
36723672
59965996 mailboxes locally (frontend) and the subscriptions remotely
59975997 (INBOX backend). We can only pass the buck to the INBOX backend
59985998 if its running a unified config */
5999 list_data_remote(tag, listargs);
5999 if (list_data_remote(tag, listargs))
6000 return;
60006001 } else {
60016002 list_data(listargs);
60026003 }
66336634 c = getword(imapd_in, &arg);
66346635 if (c != ' ' && c != ')') goto badlist;
66356636 if (arg.s[0] == '\0') goto badlist;
6636 newquota = 0;
6637 for (p = arg.s; *p; p++) {
6638 if (!Uisdigit(*p)) goto badlist;
6639 newquota = newquota * 10 + *p - '0';
6640 if (newquota < 0) goto badlist; /* overflow */
6637 /* accept "(storage -1)" as "()" to make move from unpatched cyrus possible */
6638 if (strcmp(arg.s, "-1") != 0) {
6639 newquota = 0;
6640 for (p = arg.s; *p; p++) {
6641 if (!Uisdigit(*p)) goto badlist;
6642 newquota = newquota * 10 + *p - '0';
6643 if (newquota < 0) goto badlist; /* overflow */
6644 }
66416645 }
66426646 if (c == ')') break;
66436647 }
88538857
88548858 /* note use of + to force the setting of a nonexistant
88558859 * quotaroot */
8856 prot_printf(xfer->be->out, "Q01 SETQUOTA {" SIZE_T_FMT "+}\r\n" \
8857 "+%s (STORAGE %d)\r\n",
8858 strlen(extname)+1, extname, quota.limit);
8860 if (quota.limit == -1) {
8861 prot_printf(xfer->be->out, "Q01 SETQUOTA {" SIZE_T_FMT "+}\r\n" \
8862 "+%s ()\r\n",
8863 strlen(extname)+1, extname);
8864 }
8865 else {
8866 prot_printf(xfer->be->out, "Q01 SETQUOTA {" SIZE_T_FMT "+}\r\n" \
8867 "+%s (STORAGE %d)\r\n",
8868 strlen(extname)+1, extname, quota.limit);
8869 }
88598870 r = getresult(xfer->be->in, "Q01");
88608871 if (r) syslog(LOG_ERR,
88618872 "Could not move mailbox: %s, " \
1031710328 * Retrieves the data and prints the untagged responses for a LIST command in
1031810329 * the case of a remote inbox.
1031910330 */
10320 static void list_data_remote(char *tag, struct listargs *listargs)
10331 static int list_data_remote(char *tag, struct listargs *listargs)
1032110332 {
1032210333 if ((listargs->cmd & LIST_CMD_EXTENDED) &&
1032310334 !CAPA(backend_inbox, CAPA_LISTEXTENDED)) {
1032410335 /* client wants to use extended list command but backend doesn't
1032510336 * support it */
10326 prot_printf(backend_inbox->out,
10337 prot_printf(imapd_out,
1032710338 "%s NO Backend server does not support LIST-EXTENDED\r\n",
1032810339 tag);
10329 return;
10340 return IMAP_MAILBOX_NOTSUPPORTED;
1033010341 }
1033110342
1033210343 /* print tag, command and list selection options */
1038210393 prot_printf(backend_inbox->out, "\r\n");
1038310394 pipe_lsub(backend_inbox, imapd_userid, tag, 0,
1038410395 (listargs->cmd & LIST_CMD_LSUB) ? "LSUB" : "LIST");
10396
10397 return 0;
1038510398 }
1038610399
1038710400 /* Reset the given sasl_conn_t to a sane state */
1099511008 {
1099611009 static struct buf arg;
1099711010 int c;
10998
10999 prot_printf(imapd_out, "* ENABLED");
11011 unsigned new_capa = imapd_client_capa;
1100011012
1100111013 do {
1100211014 c = getword(imapd_in, &arg);
1100711019 eatline(imapd_in, c);
1100811020 return;
1100911021 }
11010 lcase(arg.s);
11011 if (!strcmp(arg.s, "condstore")) {
11012 imapd_client_capa |= CAPA_CONDSTORE;
11013 prot_printf(imapd_out, " CONDSTORE");
11014 }
11015 else if (!strcmp(arg.s, "qresync")) {
11016 imapd_client_capa |= CAPA_QRESYNC | CAPA_CONDSTORE;
11017 if (imapd_index) imapd_index->qresync = 1;
11018 prot_printf(imapd_out, " QRESYNC CONDSTORE");
11019 }
11022 if (!strcasecmp(arg.s, "condstore"))
11023 new_capa |= CAPA_CONDSTORE;
11024 else if (!strcasecmp(arg.s, "qresync"))
11025 new_capa |= CAPA_QRESYNC | CAPA_CONDSTORE;
1102011026 } while (c == ' ');
11021
11022 prot_printf(imapd_out, "\r\n");
1102311027
1102411028 /* check for CRLF */
1102511029 if (c == '\r') c = prot_getc(imapd_in);
1103011034 return;
1103111035 }
1103211036
11037 prot_printf(imapd_out, "* ENABLED");
11038 if (!(imapd_client_capa & CAPA_CONDSTORE) &&
11039 (new_capa & CAPA_CONDSTORE)) {
11040 prot_printf(imapd_out, " CONDSTORE");
11041 }
11042 if (!(imapd_client_capa & CAPA_QRESYNC) &&
11043 (new_capa & CAPA_QRESYNC)) {
11044 prot_printf(imapd_out, " QRESYNC");
11045 /* RFC5161 says that enable while selected is actually bogus,
11046 * but it's no skin off our nose to support it */
11047 if (imapd_index) imapd_index->qresync = 1;
11048 }
11049 prot_printf(imapd_out, "\r\n");
11050
11051 /* track the new capabilities */
11052 imapd_client_capa = new_capa;
11053
1103311054 prot_printf(imapd_out, "%s OK %s\r\n", tag,
1103411055 error_message(IMAP_OK_COMPLETED));
1103511056 }
50415041 struct mailbox *mailbox = state->mailbox;
50425042 struct index_map *im = &state->map[msgno-1];
50435043
5044 /* flush any previous data */
5045 memset(&over, 0, sizeof(struct nntp_overview));
5046
50445047 if (mailbox_cacherecord(mailbox, &im->record))
50455048 return NULL; /* upper layers can cope! */
50465049
50965099
50975100 over.from = from;
50985101 }
5099 else
5100 over.from = NULL;
51015102
51025103 /* massage references */
51035104 refhdr.s = "references";
14321432 }
14331433
14341434 /*
1435 * bsearch() function to compare two index record buffers by UID
1436 */
1437 static int rec_compar(const void *key, const void *mem)
1438 {
1439 uint32_t uid = *((uint32_t *) key);
1440 struct index_record record;
1441 int r;
1442
1443 if ((r = mailbox_buf_to_index_record(mem, &record))) return r;
1444
1445 if (uid < record.uid) return -1;
1446 return (uid > record.uid);
1447 }
1448
1449 /*
1450 * Find the index record in mailbox corresponding to UID
1451 */
1452 int mailbox_find_index_record(struct mailbox *mailbox, uint32_t uid,
1453 struct index_record *record)
1454 {
1455 const void *mem, *base = mailbox->index_base + mailbox->i.start_offset;
1456 size_t num_records = mailbox->i.num_records;
1457 size_t size = mailbox->i.record_size;
1458 int r;
1459
1460 mem = bsearch(&uid, base, num_records, size, rec_compar);
1461 if (!mem) return CYRUSDB_NOTFOUND;
1462
1463 if ((r = mailbox_buf_to_index_record(mem, record))) return r;
1464
1465 record->recno = ((mem - base) / size) + 1;
1466
1467 return 0;
1468 }
1469
1470 /*
14351471 * Lock the index file for 'mailbox'. Reread index file header if necessary.
14361472 */
14371473 int mailbox_lock_index(struct mailbox *mailbox, int locktype)
456456 struct index_record *record);
457457 extern int mailbox_append_index_record(struct mailbox *mailbox,
458458 struct index_record *record);
459 extern int mailbox_find_index_record(struct mailbox *mailbox, uint32_t uid,
460 struct index_record *record);
459461
460462 extern int mailbox_set_acl(struct mailbox *mailbox, const char *acl,
461463 int dirty_modseq);
918918 * A thorough fix might remove the prefix and timestamp
919919 * then continue with the check
920920 */
921 if (!mboxname_isdeletedmailbox(name)) {
922 if (strlen(name) > MAX_MAILBOX_NAME)
923 return IMAP_MAILBOX_BADNAME;
924 }
921 if (mboxname_isdeletedmailbox(name))
922 return 0;
923
924 if (strlen(name) > MAX_MAILBOX_NAME)
925 return IMAP_MAILBOX_BADNAME;
926
925927 for (i = 0; i < NUM_BADMBOXPATTERNS; i++) {
926928 g = glob_init(badmboxpatterns[i], GLOB_ICASE);
927929 if (GLOB_TEST(g, name) != -1) {
134134
135135 if ((rc = mboxlist_lookup(buf, &mbentry, NULL)) == 0) {
136136 if (mbentry.mbtype & MBTYPE_REMOTE) {
137 fprintf(stderr, "Remote mailbox: %s\n", argv[i]);
137 printf("%s\n", mbentry.partition);
138138 } else {
139139 char *path = mboxname_metapath(mbentry.partition, mbentry.name, 0, 0);
140140 printf("%s\n", path);
8383 int encode;
8484 };
8585
86 /* cyrus.cache file item buffer */
87 struct ibuf {
88 char *start, *end, *last;
89 };
90
91 /*
92 * Parsed form of a body-part
93 */
94 struct body {
95 /* Content-* header information */
96 char *type;
97 char *subtype;
98 struct param *params;
99 char *id;
100 char *description;
101 char *encoding;
102 char *md5;
103 char *disposition;
104 struct param *disposition_params;
105 struct param *language;
106 char *location;
107
108 /* Location/size information */
109 long header_offset;
110 long header_size;
111 long header_lines;
112 long content_offset;
113 long content_size;
114 long content_lines;
115 long boundary_size; /* Size of terminating boundary */
116 long boundary_lines;
117
118 int numparts; /* For multipart types */
119 struct body *subpart; /* For message/rfc822 and multipart types */
120
121 /*
122 * Other header information.
123 * Only meaningful for body-parts at top level or
124 * enclosed in message/rfc-822
125 */
126 char *date;
127 char *subject;
128 struct address *from;
129 struct address *sender;
130 struct address *reply_to;
131 struct address *to;
132 struct address *cc;
133 struct address *bcc;
134 char *in_reply_to;
135 char *message_id;
136 char *received_date;
137
138 /*
139 * Cached headers. Only filled in at top-level
140 */
141 struct ibuf cacheheaders;
142
143 /*
144 * decoded body. Filled in as needed.
145 */
146 char *decoded_body;
147
148 /* Message GUID. Only filled in at top level */
149 struct message_guid guid;
150 };
151
152 /* List of Content-type parameters */
153 struct param {
154 struct param *next;
155 char *attribute;
156 char *value;
157 };
158
15986 /* List of pending multipart boundaries */
16087 struct boundary {
16188 char **id;
00 /* message.h -- Message parsing
11 *
2 * Copyright (c) 1994-2008 Carnegie Mellon University. All rights reserved.
2 * Copyright (c) 1994-2010 Carnegie Mellon University. All rights reserved.
33 *
44 * Redistribution and use in source and binary forms, with or without
55 * modification, are permitted provided that the following conditions
5757 #include "prot.h"
5858 #include "mailbox.h"
5959
60 /* cyrus.cache file item buffer */
61 struct ibuf {
62 char *start, *end, *last;
63 };
64
65 /*
66 * Parsed form of a body-part
67 */
68 struct body {
69 /* Content-* header information */
70 char *type;
71 char *subtype;
72 struct param *params;
73 char *id;
74 char *description;
75 char *encoding;
76 char *md5;
77 char *disposition;
78 struct param *disposition_params;
79 struct param *language;
80 char *location;
81
82 /* Location/size information */
83 long header_offset;
84 long header_size;
85 long header_lines;
86 long content_offset;
87 long content_size;
88 long content_lines;
89 long boundary_size; /* Size of terminating boundary */
90 long boundary_lines;
91
92 int numparts; /* For multipart types */
93 struct body *subpart; /* For message/rfc822 and multipart types */
94
95 /*
96 * Other header information.
97 * Only meaningful for body-parts at top level or
98 * enclosed in message/rfc-822
99 */
100 char *date;
101 char *subject;
102 struct address *from;
103 struct address *sender;
104 struct address *reply_to;
105 struct address *to;
106 struct address *cc;
107 struct address *bcc;
108 char *in_reply_to;
109 char *message_id;
110 char *received_date;
111
112 /*
113 * Cached headers. Only filled in at top-level
114 */
115 struct ibuf cacheheaders;
116
117 /*
118 * decoded body. Filled in as needed.
119 */
120 char *decoded_body;
121
122 /* Message GUID. Only filled in at top level */
123 struct message_guid guid;
124 };
125
126 /* List of Content-type parameters */
127 struct param {
128 struct param *next;
129 char *attribute;
130 char *value;
131 };
60132 extern int message_copy_strict P((struct protstream *from, FILE *to,
61133 unsigned size, int allow_null));
62134
213213 static void cmdloop(void);
214214 static int open_group(char *name, int has_prefix,
215215 struct backend **ret, int *postable);
216 static int getuserpass(struct protstream *in, struct buf *buf);
216217 static int parserange(char *str, uint32_t *uid, uint32_t *last,
217218 char **msgid, struct backend **be);
218219 static time_t parse_datetime(char *datestr, char *timestr, char *gmt);
898899
899900 /* Only Authinfo/Capabilities/Check/Head/Help/Ihave/List Active/
900901 Mode/Quit/Starttls/Stat/Takethis allowed when not logged in */
901 if (!nntp_userid && !allowanonymous &&
902 if (!nntp_authstate && !allowanonymous &&
902903 !strchr("ACHILMQST", cmd.s[0])) goto nologin;
903904
904905 /* In case a [LIST]GROUP fails or
908909 switch (cmd.s[0]) {
909910 case 'A':
910911 if (!strcmp(cmd.s, "Authinfo")) {
911 arg2.len = arg3.len = 0;
912912 if (c != ' ') goto missingargs;
913913 c = getword(nntp_in, &arg1); /* subcommand */
914914 if (c == EOF) goto missingargs;
915915
916916 lcase(arg1.s);
917917
918 if (strcmp(arg1.s, "generic") && c != ' ') {
919 /* arg2 is required for all subcommands except generic */
920 goto missingargs;
918 if (!strcmp(arg1.s, "user") || !strcmp(arg1.s, "pass")) {
919 if (c != ' ') goto missingargs;
920 c = getuserpass(nntp_in, &arg2); /* user/pass */
921 if (c == EOF) goto missingargs;
922
923 if (c == '\r') c = prot_getc(nntp_in);
924 if (c != '\n') goto extraargs;
925
926 if (arg1.s[0] == 'u')
927 cmd_authinfo_user(arg2.s);
928 else
929 cmd_authinfo_pass(arg2.s);
921930 }
922 if (c == ' ') {
923 c = getword(nntp_in, &arg2); /* argument/sasl mech */
924 if (c == EOF) goto missingargs;
925 }
926
927 if (!strcmp(arg1.s, "sasl") && c == ' ') {
928 c = getword(nntp_in, &arg3); /* init response (optional) */
929 if (c == EOF) goto missingargs;
930 }
931 if (c == '\r') c = prot_getc(nntp_in);
932 if (c != '\n') goto extraargs;
933
934 if (!strcmp(arg1.s, "user"))
935 cmd_authinfo_user(arg2.s);
936 else if (!strcmp(arg1.s, "pass"))
937 cmd_authinfo_pass(arg2.s);
938 else if (!strcmp(arg1.s, "sasl") || !strcmp(arg1.s, "generic"))
931 else if (!strcmp(arg1.s, "sasl") || !strcmp(arg1.s, "generic")) {
932 arg2.len = arg3.len = 0;
933
934 /* mech name required for SASL but not GENERIC */
935 if ((arg1.s[0] == 's') && (c != ' ')) goto missingargs;
936
937 if (c == ' ') {
938 c = getword(nntp_in, &arg2); /* mech name */
939 if (c == EOF) goto missingargs;
940
941 if (c == ' ') {
942 c = getword(nntp_in, &arg3); /* init response */
943 if (c == EOF) goto missingargs;
944 }
945 }
946
947 if (c == '\r') c = prot_getc(nntp_in);
948 if (c != '\n') goto extraargs;
949
939950 cmd_authinfo_sasl(arg1.s, arg2.len ? arg2.s : NULL,
940951 arg3.len ? arg3.s : NULL);
952 }
941953 else
942954 prot_printf(nntp_out,
943955 "501 Unrecognized AUTHINFO command\r\n");
944956 }
945957 else if (!(nntp_capa & MODE_READ)) goto noperm;
946 else if (!nntp_userid && !allowanonymous) goto nologin;
958 else if (!nntp_authstate && !allowanonymous) goto nologin;
947959 else if (!strcmp(cmd.s, "Article")) {
948960 char *msgid;
949961
11351147 cmd_help();
11361148 }
11371149 else if (!(nntp_capa & MODE_READ)) goto noperm;
1138 else if (!nntp_userid && !allowanonymous) goto nologin;
1150 else if (!nntp_authstate && !allowanonymous) goto nologin;
11391151 else if (!strcmp(cmd.s, "Hdr")) {
11401152 char *msgid;
11411153
12141226 goto prevgroup; /* In case we did LIST [ACTIVE] */
12151227 }
12161228 else if (!(nntp_capa & MODE_READ)) goto noperm;
1217 else if (!nntp_userid && !allowanonymous) goto nologin;
1229 else if (!nntp_authstate && !allowanonymous) goto nologin;
12181230 else if (!strcmp(cmd.s, "Last")) {
12191231 if (c == '\r') c = prot_getc(nntp_in);
12201232 if (c != '\n') goto extraargs;
14141426 mode = ARTICLE_STAT;
14151427 goto article;
14161428 }
1417 else if (!nntp_userid && !allowanonymous) goto nologin;
1429 else if (!nntp_authstate && !allowanonymous) goto nologin;
14181430 else if (!strcmp(cmd.s, "Slave")) {
14191431 if (c == '\r') c = prot_getc(nntp_in);
14201432 if (c != '\n') goto extraargs;
15861598 }
15871599
15881600 return 1;
1601 }
1602
1603 /*
1604 * Parse a username or password (token which may contain SP or TAB)
1605 */
1606 #define MAX_NNTP_ARG 497
1607 static int getuserpass(struct protstream *in, struct buf *buf)
1608 {
1609 int c;
1610
1611 buf_reset(buf);
1612 for (;;) {
1613 c = prot_getc(in);
1614 if (c == EOF || c == '\r' || c == '\n') {
1615 buf_cstring(buf); /* appends a '\0' */
1616 return c;
1617 }
1618 buf_putc(buf, c);
1619 if (buf_len(buf) > MAX_NNTP_ARG) {
1620 fatal("argument too long", EC_IOERR);
1621 }
1622 }
15891623 }
15901624
15911625 static int parserange(char *str, uint32_t *uid, uint32_t *last,
17651799 if (newserver) {
17661800 /* remote group */
17671801 backend_next = proxy_findserver(newserver, &nntp_protocol,
1768 nntp_userid ? nntp_userid : "anonymous",
1802 nntp_authstate ? nntp_userid : "anonymous",
17691803 &backend_cached, &backend_current,
17701804 NULL, nntp_in);
17711805 if (!backend_next) return IMAP_SERVER_UNAVAILABLE;
17761810 /* local group */
17771811 struct index_init init;
17781812 memset(&init, 0, sizeof(struct index_init));
1779 init.userid = nntp_userid;
1813 init.userid = nntp_authstate ? nntp_userid : NULL;
17801814 init.authstate = nntp_authstate;
17811815 r = index_open(name, &init, &group_state);
17821816 if (r) return r;
18231857 if (mechcount) prot_printf(nntp_out, "%s", mechlist);
18241858
18251859 /* add the reader capabilities/extensions */
1826 if ((nntp_capa & MODE_READ) && (nntp_userid || allowanonymous)) {
1860 if ((nntp_capa & MODE_READ) && (nntp_authstate || allowanonymous)) {
18271861 prot_printf(nntp_out, "READER\r\n");
18281862 prot_printf(nntp_out, "POST\r\n");
18291863 if (config_getswitch(IMAPOPT_ALLOWNEWNEWS))
18411875
18421876 /* add the LIST variants */
18431877 prot_printf(nntp_out, "LIST ACTIVE%s\r\n",
1844 ((nntp_capa & MODE_READ) && (nntp_userid || allowanonymous)) ?
1878 ((nntp_capa & MODE_READ) && (nntp_authstate || allowanonymous)) ?
18451879 " HEADERS NEWSGROUPS OVERVIEW.FMT" : "");
18461880
18471881 prot_printf(nntp_out, ".\r\n");
23202354 {
23212355 prot_printf(nntp_out, "100 Supported commands:\r\n");
23222356
2323 if ((nntp_capa & MODE_READ) && (nntp_userid || allowanonymous)) {
2357 if ((nntp_capa & MODE_READ) && (nntp_authstate || allowanonymous)) {
23242358 prot_printf(nntp_out, "\tARTICLE [ message-id | number ]\r\n"
23252359 "\t\tRetrieve entirety of the specified article.\r\n");
23262360 }
23352369 prot_printf(nntp_out, "\tAUTHINFO PASS password\r\n"
23362370 "\t\tPresent clear-text password for authentication.\r\n");
23372371 }
2338 if ((nntp_capa & MODE_READ) && (nntp_userid || allowanonymous)) {
2372 if ((nntp_capa & MODE_READ) && (nntp_authstate || allowanonymous)) {
23392373 prot_printf(nntp_out, "\tBODY [ message-id | number ]\r\n"
23402374 "\t\tRetrieve body of the specified article.\r\n");
23412375 }
23452379 prot_printf(nntp_out, "\tCHECK message-id\r\n"
23462380 "\t\tCheck if the server wants the specified article.\r\n");
23472381 }
2348 if ((nntp_capa & MODE_READ) && (nntp_userid || allowanonymous)) {
2382 if ((nntp_capa & MODE_READ) && (nntp_authstate || allowanonymous)) {
23492383 prot_printf(nntp_out, "\tDATE\r\n"
23502384 "\t\tRequest the current server UTC date and time.\r\n");
23512385 prot_printf(nntp_out, "\tGROUP group\r\n"
23622396 prot_printf(nntp_out, "\tIHAVE message-id\r\n"
23632397 "\t\tPresent/transfer the specified article to the server.\r\n");
23642398 }
2365 if ((nntp_capa & MODE_READ) && (nntp_userid || allowanonymous)) {
2399 if ((nntp_capa & MODE_READ) && (nntp_authstate || allowanonymous)) {
23662400 prot_printf(nntp_out, "\tLAST\r\n"
23672401 "\t\tSelect the previous article.\r\n");
23682402 }
23692403 prot_printf(nntp_out, "\tLIST [ ACTIVE wildmat ]\r\n"
23702404 "\t\tList the (subset of) valid newsgroups.\r\n");
2371 if ((nntp_capa & MODE_READ) && (nntp_userid || allowanonymous)) {
2405 if ((nntp_capa & MODE_READ) && (nntp_authstate || allowanonymous)) {
23722406 prot_printf(nntp_out, "\tLIST HEADERS [ MSGID | RANGE ]\r\n"
23732407 "\t\tList the headers and metadata items available via HDR.\r\n");
23742408 prot_printf(nntp_out, "\tLIST NEWSGROUPS [wildmat]\r\n"
24012435 prot_printf(nntp_out, "\tTAKETHIS message-id\r\n"
24022436 "\t\tTransfer the specified article to the server.\r\n");
24032437 }
2404 if ((nntp_capa & MODE_READ) && (nntp_userid || allowanonymous)) {
2438 if ((nntp_capa & MODE_READ) && (nntp_authstate || allowanonymous)) {
24052439 prot_printf(nntp_out, "\tXPAT header message-id|range wildmat\r\n"
24062440 "\t\tList the specified article(s) in which the contents\r\n"
24072441 "\t\tof the specified header/metadata matches the wildmat.\r\n");
24692503 char *result;
24702504
24712505 be = proxy_findserver(server, &nntp_protocol,
2472 nntp_userid ? nntp_userid : "anonymous",
2506 nntp_authstate ? nntp_userid : "anonymous",
24732507 &backend_cached, &backend_current, NULL, nntp_in);
24742508 if (!be) return;
24752509
26042638 strcpy(pattern, newsprefix);
26052639 strcat(pattern, "*");
26062640 list_cb(NULL, 0, 0, NULL);
2607 mboxlist_findall(NULL, pattern, 0, nntp_userid, nntp_authstate,
2641 mboxlist_findall(NULL, pattern, 0,
2642 nntp_authstate ? nntp_userid : NULL, nntp_authstate,
26082643 list_cb, &lrock);
26092644
26102645 /* proxy to the backends */
26262661 prot_printf(nntp_out, "502 Permission denied\r\n");
26272662 return;
26282663 }
2629 else if (!nntp_userid && !allowanonymous) {
2664 else if (!nntp_authstate && !allowanonymous) {
26302665 prot_printf(nntp_out, "480 Authentication required\r\n");
26312666 return;
26322667 }
26632698 strcpy(pattern, newsprefix);
26642699 strcat(pattern, "*");
26652700 list_cb(NULL, 0, 0, NULL);
2666 mboxlist_findall(NULL, pattern, 0, nntp_userid, nntp_authstate,
2701 mboxlist_findall(NULL, pattern, 0,
2702 nntp_authstate ? nntp_userid : NULL, nntp_authstate,
26672703 list_cb, &lrock);
26682704
26692705 /* proxy to the backends */
32393275 char buf[4096];
32403276
32413277 be = proxy_findserver(d->server, &nntp_protocol,
3242 nntp_userid ? nntp_userid : "anonymous",
3278 nntp_authstate ? nntp_userid : "anonymous",
32433279 &backend_cached, &backend_current,
32443280 NULL, nntp_in);
32453281 if (!be) return IMAP_SERVER_UNAVAILABLE;
33173353 continue;
33183354 }
33193355
3320 r = append_setup(&as, rcpt, nntp_userid, nntp_authstate, ACL_POST, 0);
3356 r = append_setup(&as, rcpt,
3357 nntp_authstate ? nntp_userid : NULL,
3358 nntp_authstate, ACL_POST, 0);
33213359
33223360 if (!r) {
33233361 prot_rewind(msg->data);
135135
136136
137137
138 #define MAX(x, y) (x > y ? x : y)
139138
140139 /* Comparator function that sorts ranges by the low value,
141140 and coalesces intersecting ranges to have the same high value */
196196 skip && *skip && strcasecmp(name, *skip); skip++);
197197 if (!skip || !*skip) {
198198 /* write the header name to the output */
199 fputs(name, fout);
199 if (fout) fputs(name, fout);
200200 skip = NULL;
201201 }
202202 s = (c == ':' ? BODY_START : COLON);
219219 } else if (c != ' ' && c != '\t') {
220220 /* i want to avoid confusing dot-stuffing later */
221221 while (c == '.') {
222 if (!skip) fputc(c, fout);
222 if (fout && !skip) fputc(c, fout);
223223 c = prot_getc(fin);
224224 }
225225 r = IMAP_MESSAGE_BADHEADER;
240240
241241 peek = prot_getc(fin);
242242
243 if (!skip) {
243 if (fout && !skip) {
244244 fputc('\r', fout);
245245 fputc('\n', fout);
246246 }
281281 }
282282
283283 /* copy this to the output */
284 if (s != NAME && !skip) fputc(c, fout);
284 if (fout && s != NAME && !skip) fputc(c, fout);
285285 }
286286
287287 /* if we fall off the end of the loop, we hit some sort of error
7171 return s + 4;
7272 }
7373
74 SquatInt64 squat_decode_64(char const* s) {
75 unsigned char* v = (unsigned char*)s;
76 return ((SquatInt64)v[0] << 56) | ((SquatInt64)v[1] << 48)
77 | ((SquatInt64)v[2] << 40) | ((SquatInt64)v[3] << 32)
78 | (((SquatInt32)v[4] << 24) | ((SquatInt32)v[5] << 16)
79 | ((SquatInt32)v[6] << 8) | (SquatInt32)v[7]);
74 SquatInt64 squat_decode_64(char const *s)
75 {
76 unsigned char* v = (unsigned char*)s;
77 return ((SquatInt64)v[0] << 56) | ((SquatInt64)v[1] << 48) |
78 ((SquatInt64)v[2] << 40) | ((SquatInt64)v[3] << 32) |
79 ((SquatInt64)v[4] << 24) | ((SquatInt64)v[5] << 16) |
80 ((SquatInt64)v[6] << 8) | (SquatInt64)v[7];
8081 }
8182
8283 char* squat_encode_64(char* s, SquatInt64 v) {
101101 LIBCYRM_HDRS = $(srcdir)/hash.h $(srcdir)/mpool.h $(srcdir)/xmalloc.h \
102102 $(srcdir)/xstrlcat.h $(srcdir)/xstrlcpy.h $(srcdir)/util.h \
103103 $(srcdir)/strhash.h $(srcdir)/libconfig.h $(srcdir)/assert.h \
104 imapopts.h $(srcdir)/crc32.h
104 imapopts.h
105105 LIBCYRM_OBJS = libconfig.o imapopts.o hash.o mpool.o xmalloc.o strhash.o \
106 xstrlcat.o xstrlcpy.o assert.o util.o signals.o crc32.o @IPV6_OBJS@
106 xstrlcat.o xstrlcpy.o assert.o util.o signals.o @IPV6_OBJS@
107107
108108 all: $(BUILTSOURCES) libcyrus_min.a libcyrus.a
109109
19391939 offset = FORWARD(ptr, i);
19401940
19411941 if (offset > db->map_size) {
1942 fprintf(stdout,
1942 syslog(LOG_ERR,
19431943 "skiplist inconsistent: %04X: ptr %d is %04X; "
19441944 "eof is %04X\n",
19451945 (unsigned int) (ptr - db->map_base),
19551955
19561956 cmp = db->compar(KEY(ptr), KEYLEN(ptr), KEY(q), KEYLEN(q));
19571957 if (cmp >= 0) {
1958 fprintf(stdout,
1958 syslog(LOG_ERR,
19591959 "skiplist inconsistent: %04X: ptr %d is %04X; "
19601960 "db->compar() = %d\n",
19611961 (unsigned int) (ptr - db->map_base),
684684 { "mboxname_lockpath", NULL, STRING }
685685 /* Path to mailbox name lock files (default $conf/lock) */
686686
687 { "metapartition_files", "", BITFIELD("header", "index", "cache", "expunge", "squat", "lock") }
687 { "metapartition_files", "", BITFIELD("header", "index", "cache", "expunge", "squat") }
688688 /* Space-separated list of metadata files to be stored on a
689689 \fImetapartition\fR rather than in the mailbox directory on a spool
690690 partition. */
11991199 { "suppress_capabilities", NULL, STRING }
12001200 /* Suppress the named capabilities from any capability response. Use the
12011201 exact case as it appears in the response, e.g.
1202 "suppress_capabilities: ESEARCH QRESYNC WITHIN XLIST" if you have
1203 a murder with 2.3.x backends and don't want clients being confused
1204 by new capabilities that some backends don't support. */
1202 "suppress_capabilities: ESEARCH QRESYNC WITHIN XLIST LIST-EXTENDED"
1203 if you have a murder with 2.3.x backends and don't want clients being
1204 confused by new capabilities that some backends don't support. */
12051205
12061206 { "statuscache", 0, SWITCH }
12071207 /* Enable/disable the imap status cache. */
416416 { "cache" , IMAP_ENUM_METAPARTITION_FILES_CACHE },
417417 { "expunge" , IMAP_ENUM_METAPARTITION_FILES_EXPUNGE },
418418 { "squat" , IMAP_ENUM_METAPARTITION_FILES_SQUAT },
419 { "lock" , IMAP_ENUM_METAPARTITION_FILES_LOCK },
420419 { NULL, IMAP_ENUM_ZERO } } },
421420 { IMAPOPT_MUPDATE_AUTHNAME, "mupdate_authname", 0, OPT_STRING,
422421 {(void *)(NULL)},
282282 IMAP_ENUM_METAPARTITION_FILES_CACHE = (1<<2),
283283 IMAP_ENUM_METAPARTITION_FILES_EXPUNGE = (1<<3),
284284 IMAP_ENUM_METAPARTITION_FILES_SQUAT = (1<<4),
285 IMAP_ENUM_METAPARTITION_FILES_LOCK = (1<<5),
286285 IMAP_ENUM_MUPDATE_CONFIG_STANDARD = 0,
287286 IMAP_ENUM_MUPDATE_CONFIG_UNIFIED,
288287 IMAP_ENUM_MUPDATE_CONFIG_REPLICATED,
8585 * Create a new protection stream for file descriptor 'fd'. Stream
8686 * will be used for writing iff 'write' is nonzero.
8787 */
88 struct protstream *prot_new(fd, write)
89 int fd;
90 int write;
88 struct protstream *prot_new(int fd, int write)
9189 {
9290 struct protstream *newstream;
9391
104102 if(write)
105103 newstream->cnt = PROT_BUFSIZE;
106104
107 newstream->can_unget = 0;
108 newstream->bytes_in = 0;
109 newstream->bytes_out = 0;
105 return newstream;
106 }
107
108 /* Create a protstream which is just an interface to a mapped piece of
109 * memory, allowing prot commands to be used to read from it */
110 struct protstream *prot_readmap(const char *buf, uint32_t len)
111 {
112 struct protstream *newstream;
113
114 newstream = (struct protstream *) xzmalloc(sizeof(struct protstream));
115 /* dodgy, but the alternative is two pointers */
116 newstream->ptr = (unsigned char *)buf;
117 newstream->cnt = len;
118 newstream->fixedsize = 1;
119 newstream->fd = PROT_NO_FD;
120 newstream->logfd = PROT_NO_FD;
121 newstream->big_buffer = PROT_NO_FD;
110122
111123 return newstream;
112124 }
133145 if (s->zbuf) free(s->zbuf);
134146 #endif
135147
136 free((char*)s);
148 free(s);
137149
138150 return 0;
139151 }
565577 /* Zero errno just in case */
566578 errno = 0;
567579
580 if (s->fixedsize) s->eof = 1;
568581 if (s->eof || s->error) return EOF;
569582
570583 do {
16911704 {
16921705 assert(!s->write);
16931706
1707 if (c == EOF) return EOF;
1708
16941709 if (!s->can_unget)
16951710 fatal("Can't unwind any more", EC_SOFTWARE);
16961711
16971712 s->cnt++;
16981713 s->can_unget--;
16991714 s->bytes_in--;
1700 *--(s->ptr) = c;
1715 s->ptr--;
1716 if (*s->ptr != c)
1717 fatal("Trying to unput wrong character", EC_SOFTWARE);
17011718
17021719 return c;
17031720 }
112112 /* Status Flags */
113113 int eof;
114114 int boundary; /* Type of data is about to change */
115 int fixedsize;
115116 char *error;
116117
117118 /* Parameters */
181182
182183 /* Allocate/free the protstream structure */
183184 extern struct protstream *prot_new(int fd, int write);
185 extern struct protstream *prot_readmap(const char *buf, uint32_t len);
184186 extern int prot_free(struct protstream *s);
185187
186188 /* Set the telemetry logfile for a given protstream */
526526 *len = buf->len;
527527 }
528528
529 unsigned buf_len(struct buf *buf)
529 unsigned buf_len(const struct buf *buf)
530530 {
531531 return buf->len;
532532 }
537537 buf->flags &= ~BUF_CSTRING;
538538 }
539539
540 void buf_setcstr(struct buf *buf, char *str)
540 void buf_truncate(struct buf *buf, unsigned int len)
541 {
542 if (len > buf->alloc) {
543 /* grow the buffer and zero-fill the new bytes */
544 unsigned int more = len - buf->len;
545 buf_ensure(buf, more);
546 memset(buf->s + buf->len, 0, more);
547 }
548 buf->len = len;
549 buf->flags &= ~BUF_CSTRING;
550 }
551
552 void buf_setcstr(struct buf *buf, const char *str)
541553 {
542554 buf_setmap(buf, str, strlen(str));
543555 }
544556
545 void buf_setmap(struct buf *buf, char *base, int len)
557 void buf_setmap(struct buf *buf, const char *base, int len)
546558 {
547559 buf_reset(buf);
548560 if (len) {
552564 }
553565 }
554566
555 void buf_copy(struct buf *dst, struct buf *src)
567 void buf_copy(struct buf *dst, const struct buf *src)
556568 {
557569 buf_setmap(dst, src->s, src->len);
558570 }
559571
560 void buf_append(struct buf *dst, struct buf *src)
572 void buf_append(struct buf *dst, const struct buf *src)
561573 {
562574 buf_appendmap(dst, src->s, src->len);
563575 }
564576
565 void buf_appendcstr(struct buf *buf, char *str)
577 void buf_appendcstr(struct buf *buf, const char *str)
566578 {
567579 buf_appendmap(buf, str, strlen(str));
568580 }
574586 buf_appendmap(buf, item, 4);
575587 }
576588
577 void buf_appendmap(struct buf *buf, char *base, int len)
589 void buf_appendmap(struct buf *buf, const char *base, int len)
578590 {
579591 if (len) {
580592 buf_ensure(buf, len);
589601 buf_ensure(buf, 1);
590602 buf->s[buf->len++] = c;
591603 buf->flags &= ~BUF_CSTRING;
604 }
605
606 void buf_printf(struct buf *buf, const char *fmt, ...)
607 {
608 va_list args;
609 int room;
610 int n;
611
612 /* Add some more room to the buffer. We just guess a
613 * size and rely on vsnprintf() to tell us if it
614 * needs to overrun the size. */
615 buf_ensure(buf, 1024);
616
617 room = buf->alloc - buf->len - 1;
618 va_start(args, fmt);
619 n = vsnprintf(buf->s + buf->len, room+1, fmt, args);
620 va_end(args);
621
622 if (n > room) {
623 /* woops, we guessed wrong...retry */
624 buf_ensure(buf, n-room);
625 va_start(args, fmt);
626 n = vsnprintf(buf->s + buf->len, n+1, fmt, args);
627 va_end(args);
628 }
629
630 buf->len += n;
631 /* vsnprintf() gave us a trailing NUL, so we may as well remember
632 * that for later */
633 buf->flags |= BUF_CSTRING;
634 }
635
636 /**
637 * Replace all instances of the string literal @match in @buf
638 * with the string @replace, which may be NULL to just remove
639 * instances of @match.
640 * Returns: the number of substitutions made.
641 */
642 unsigned int buf_replace_all(struct buf *buf, const char *match,
643 const char *replace)
644 {
645 unsigned int n = 0;
646 int matchlen = strlen(match);
647 int replacelen = (replace ? strlen(replace) : 0);
648 char *p;
649
650 /* we need buf to be a nul terminated string now please */
651 buf_cstring(buf);
652
653 p = buf->s;
654 while ((p = strstr(p, match))) {
655 if (replacelen > matchlen) {
656 /* string will need to expand */
657 int dp = (p - buf->s);
658 buf_ensure(buf, replacelen - matchlen);
659 p = buf->s + dp;
660 }
661 if (matchlen != replacelen) {
662 memmove(p+replacelen, p+matchlen,
663 buf->len - (p - buf->s) - matchlen + replacelen + 1);
664 buf->len += (replacelen - matchlen);
665 }
666 if (replace)
667 memcpy(p, replace, replacelen);
668 n++;
669 p += replacelen;
670 }
671
672 return n;
673 }
674
675 /*
676 * Compare two struct bufs bytewise. Returns a number
677 * like strcmp(), suitable for sorting e.g. with qsort(),
678 */
679 int buf_cmp(const struct buf *a, const struct buf *b)
680 {
681 unsigned len = MIN(a->len, b->len);
682 int r = 0;
683
684 if (len)
685 r = memcmp(a->s, b->s, len);
686
687 if (!r) {
688 if (a->len < b->len)
689 r = -1;
690 else if (a->len > b->len)
691 r = 1;
692 }
693
694 return r;
695 }
696
697 void buf_init(struct buf *buf)
698 {
699 buf->alloc = 0;
700 buf->len = 0;
701 buf->flags = 0;
702 buf->s = NULL;
703 }
704
705 /*
706 * Initialise a struct buf to point to read-only data. The key here is
707 * setting buf->alloc=0 which indicates CoW is in effect, i.e. the data
708 * pointed to needs to be copied should it ever be modified.
709 */
710 void buf_init_ro(struct buf *buf, const char *base, int len)
711 {
712 buf->alloc = 0;
713 buf->len = len;
714 buf->flags = 0;
715 buf->s = (char *)base;
592716 }
593717
594718 void buf_free(struct buf *buf)
599723 buf->s = NULL;
600724 buf->len = 0;
601725 buf->flags = 0;
726 }
727
728 void buf_move(struct buf *dst, struct buf *src)
729 {
730 if (dst->alloc)
731 free(dst->s);
732 *dst = *src;
733 buf_init(src);
602734 }
603735
604736 char *strconcat(const char *s1, ...)
9191 #define TOUPPER(c) (convert_to_uppercase[(unsigned char)(c)])
9292 #define TOLOWER(c) (convert_to_lowercase[(unsigned char)(c)])
9393
94 #ifndef MAX
95 #define MAX(x, y) ((x) > (y) ? (x) : (y))
96 #endif
97 #ifndef MIN
98 #define MIN(x, y) ((x) < (y) ? (x) : (y))
99 #endif
100
94101 typedef struct keyvalue {
95102 char *key, *value;
96103 } keyvalue;
172179 unsigned alloc;
173180 int flags;
174181 };
182 #define BUF_INITIALIZER { NULL, 0, 0, 0 }
175183
176184 const char *buf_cstring(struct buf *buf);
185 void buf_ensure(struct buf *buf, int morebytes);
177186 void buf_getmap(struct buf *buf, const char **base, int *len);
178 unsigned buf_len(struct buf *buf);
187 unsigned buf_len(const struct buf *buf);
179188 void buf_reset(struct buf *buf);
180 void buf_setcstr(struct buf *buf, char *str);
181 void buf_setmap(struct buf *buf, char *base, int len);
182 void buf_copy(struct buf *dst, struct buf *src);
183 void buf_append(struct buf *dst, struct buf *src);
184 void buf_appendcstr(struct buf *buf, char *str);
189 void buf_truncate(struct buf *buf, unsigned int len);
190 void buf_setcstr(struct buf *buf, const char *str);
191 void buf_setmap(struct buf *buf, const char *base, int len);
192 void buf_copy(struct buf *dst, const struct buf *src);
193 void buf_append(struct buf *dst, const struct buf *src);
194 void buf_appendcstr(struct buf *buf, const char *str);
185195 void buf_appendbit32(struct buf *buf, bit32 num);
186 void buf_appendmap(struct buf *buf, char *base, int len);
196 void buf_appendmap(struct buf *buf, const char *base, int len);
187197 void buf_putc(struct buf *buf, char c);
198 void buf_printf(struct buf *buf, const char *fmt, ...)
199 __attribute__((format(printf,2,3)));
200 unsigned int buf_replace_all(struct buf *buf, const char *match,
201 const char *replace);
202 int buf_cmp(const struct buf *, const struct buf *);
203 void buf_init(struct buf *buf);
204 void buf_init_ro(struct buf *buf, const char *base, int len);
188205 void buf_free(struct buf *buf);
206 void buf_move(struct buf *dst, struct buf *src);
189207
190208 /* use getpassphrase on machines which support it */
191209 #ifdef HAVE_GETPASSPHRASE
588588 \fImetapartition\fR rather than in the mailbox directory on a spool
589589 partition.
590590
591 Allowed values: \fIheader\fR, \fIindex\fR, \fIcache\fR, \fIexpunge\fR, \fIsquat\fR, \fIlock\fR
591 Allowed values: \fIheader\fR, \fIindex\fR, \fIcache\fR, \fIexpunge\fR, \fIsquat\fR
592592 .IP "\fBmetapartition-name:\fR <none>" 5
593593 The pathname of the metadata partition \fIname\fR, corresponding to
594594 spool partition \fBpartition-name\fR. For any mailbox residing in
10161016 .IP "\fBsuppress_capabilities:\fR <none>" 5
10171017 Suppress the named capabilities from any capability response. Use the
10181018 exact case as it appears in the response, e.g.
1019 "suppress_capabilities: ESEARCH QRESYNC WITHIN XLIST" if you have
1020 a murder with 2.3.x backends and don't want clients being confused
1021 by new capabilities that some backends don't support.
1019 "suppress_capabilities: ESEARCH QRESYNC WITHIN XLIST LIST-EXTENDED"
1020 if you have a murder with 2.3.x backends and don't want clients being
1021 confused by new capabilities that some backends don't support.
10221022 .IP "\fBstatuscache:\fR 0" 5
10231023 Enable/disable the imap status cache.
10241024 .IP "\fBstatuscache_db:\fR skiplist" 5
123123 .\" ========================================================================
124124 .\"
125125 .IX Title "SIEVESHELL 1"
126 .TH SIEVESHELL 1 "2011-09-08" "perl v5.12.4" "User Contributed Perl Documentation"
126 .TH SIEVESHELL 1 "2011-10-04" "perl v5.12.4" "User Contributed Perl Documentation"
127127 .\" For nroff, turn off justification. Always turn off hyphenation; it makes
128128 .\" way too many mistakes in technical documents.
129129 .if n .ad l
11761176 my $name = $mbx->[0];
11771177 my $flags = $mbx->[1];
11781178 next if($flags =~ /(\\noselect|\\nonexistent|\\placeholder)/i);
1179 # If id of '*' is passed then delete all existing acls
1180 if ($nargv[1] eq '*') {
1181 my %acl = $$cyrref->listaclmailbox($name);
1182 if (defined $$cyrref->error) {
1183 print($$cyrref->error, "\n");
1184 next;
1185 }
1186 pop(@nargv);
1187 foreach my $acl (keys %acl) {
1188 push(@nargv, $acl, $acl{$acl});
1189 }
1190 }
11791191 print "Deleting acl on $name...";
11801192 $nargv[0] = $name;
11811193 my $rc = $$cyrref->deleteacl(@nargv);
11871199 }
11881200 }
11891201 } else {
1202 # If id of '*' is passed then delete all existing acls
1203 if ($nargv[1] eq '*') {
1204 my %acl = $$cyrref->listaclmailbox($nargv[0]);
1205 if (defined $$cyrref->error) {
1206 print($$cyrref->error, "\n");
1207 next;
1208 }
1209 pop(@nargv);
1210 foreach my $acl (keys %acl) {
1211 push(@nargv, $acl, $acl{$acl});
1212 }
1213 }
11901214 $$cyrref->deleteacl(@nargv) ||
11911215 die "deleteaclmailbox: " . $$cyrref->error . "\n";
11921216 }
546546
547547 char *scrname;
548548
549 scrname=malloc(strlen(name)+10);
550 strcpy(scrname, name);
551 strcat(scrname, ".script");
549 scrname = strconcat(name, ".script", (char *)NULL);
552550
553551 stream=fopen(scrname,"w");
554552
105105 # $(LEX) -t -Paddr $(srcdir)/addr-lex.l > $@
106106
107107 addr.c addr.h: addr.y
108 $(YACC) $(YFLAGS) -p addr $(srcdir)/addr.y
108 $(YACC) $(YFLAGS) $(srcdir)/addr.y
109109 mv -f y.tab.c addr.c
110110 mv -f y.tab.h addr.h
111111
6969 %}
7070
7171 %token ATOM QTEXT DTEXT
72
72 %name-prefix "addr"
7373 %%
7474 sieve_address: addrspec /* simple address */
7575 | phrase '<' addrspec '>' /* name & addr-spec */
11651165 {
11661166 case B_LOW:
11671167 priority="low";
1168 break;
11681169 case B_NORMAL:
11691170 priority="normal";
11701171 break;
12141215 {
12151216 case B_LOW:
12161217 priority="low";
1218 break;
12171219 case B_NORMAL:
12181220 priority="normal";
12191221 break;
0 /* Release cyrus-imapd-2.4.11 */
1 #define _CYRUS_VERSION "v2.4.11"
2 #define CYRUS_GITVERSION "e9b02f20 2011-09-08"
0 /* Release cyrus-imapd-2.4.12 */
1 #define _CYRUS_VERSION "v2.4.12"
2 #define CYRUS_GITVERSION "63b65d1c 2011-10-04"