summaryrefslogtreecommitdiff
path: root/imapd
diff options
context:
space:
mode:
authorSteffen Hansen <steffen@kdab.com>2005-04-20 23:09:35 (GMT)
committerSteffen Hansen <steffen@kdab.com>2005-04-20 23:09:35 (GMT)
commitfd6aa2be8b67394821f69931e6d60b5b2f3c2221 (patch)
treef36c93371814f12ca1f270f5ac5b411c0509b9b6 /imapd
parentd8727da4821b313f2a5c05c244449d6086bea262 (diff)
downloadserver-fd6aa2be8b67394821f69931e6d60b5b2f3c2221.tar.gz
"GOODCHAR" patch adapted and integrated
Diffstat (limited to 'imapd')
-rw-r--r--imapd/Makefile4
-rw-r--r--imapd/imapd-goodchars.patch (renamed from imapd/imapd-goodchars.diff)100
-rw-r--r--imapd/kolab.patch19
3 files changed, 67 insertions, 56 deletions
diff --git a/imapd/Makefile b/imapd/Makefile
index 8b9eebd..be22db2 100644
--- a/imapd/Makefile
+++ b/imapd/Makefile
@@ -20,9 +20,11 @@ all: $(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm
cp $(KOLABCVSDIR)/imapd.annotate.patch $(KOLABRPMSRC)/$(PACKAGE)/
cp $(KOLABCVSDIR)/kolab.patch $(KOLABRPMSRC)/$(PACKAGE)/ # Patch for imapd.spec
cp $(KOLABCVSDIR)/imapd.group2.patch $(KOLABRPMSRC)/$(PACKAGE)/ # Patch for case insensitive group match
+ cp $(KOLABCVSDIR)/imapd-goodchars.patch $(KOLABRPMSRC)/$(PACKAGE)/ # Patch for allowing special chars in mailbox names
cp $(KOLABCVSDIR)/kolab-ldap.patch $(KOLABRPMSRC)/$(PACKAGE)/
+
- cd $(KOLABRPMSRC)/$(PACKAGE) && patch < $(KOLABCVSDIR)/kolab.patch && $(RPM) -ba $(PACKAGE).spec --define 'with_group yes' --define 'with_atvdom yes' --define 'with_annotate yes' --define 'with_ldap yes'
+ cd $(KOLABRPMSRC)/$(PACKAGE) && patch < $(KOLABCVSDIR)/kolab.patch && $(RPM) -ba $(PACKAGE).spec --define 'with_group yes' --define 'with_atvdom yes' --define 'with_annotate yes' --define 'with_ldap yes' --define 'with_goodchars yes'
imapd-$(VERSION)-$(RELEASE).src.rpm:
wget -c $(KOLABPKGURI)/imapd-$(VERSION)-$(RELEASE).src.rpm
diff --git a/imapd/imapd-goodchars.diff b/imapd/imapd-goodchars.patch
index 45614d4..b338704 100644
--- a/imapd/imapd-goodchars.diff
+++ b/imapd/imapd-goodchars.patch
@@ -1,48 +1,52 @@
---- cyrus-imapd-2.2.10/imap/imapd.c 2004-11-17 17:29:03.000000000 -0500
-+++ cyrus-imapd-2.2.10p0/imap/imapd.c 2004-12-06 15:23:59.000000000 -0500
-@@ -3920,10 +3920,12 @@
- }
- }
-
-+#ifdef notdef
- /* verify that the mailbox doesn't have a wildcard in it */
- for (p = oldmailboxname; !r && *p; p++) {
- if (*p == '*' || *p == '%') r = IMAP_MAILBOX_BADNAME;
- }
-+#endif
-
- /* attempt to rename the base mailbox */
- if (!r) {
-
---- cyrus-imapd-2.2.10/imap/mboxlist.c 2004-07-26 14:08:03.000000000 -0400
-+++ cyrus-imapd-2.2.10p0/imap/mboxlist.c 2004-12-06 15:23:59.000000000 -0500
-@@ -476,10 +476,12 @@
- free(acl);
- return IMAP_PERMISSION_DENIED;
- }
-+#ifdef notdef
- /* disallow wildcards in userids with inboxes. */
- if (strchr(mbox, '*') || strchr(mbox, '%') || strchr(mbox, '?')) {
- return IMAP_MAILBOX_BADNAME;
- }
-+#endif
-
- /*
- * Users by default have all access to their personal mailbox(es),
---- cyrus-imapd-2.2.10/imap/mboxname.c 2004-07-13 11:02:08.000000000 -0400
-+++ cyrus-imapd-2.2.10p0/imap/mboxname.c 2004-12-06 15:23:59.000000000 -0500
-@@ -624,8 +624,13 @@
- /*
- * Apply site policy restrictions on mailbox names.
- * Restrictions are hardwired for now.
-- */
-+
-+ * original definition
- #define GOODCHARS " +,-.0123456789:=@ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz~"
-+ */
-+
-+#define GOODCHARS " #$%'()*+,-.0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[]^_`abcdefghijklmnopqrstuvwxyz{|}~"
-+
- int mboxname_policycheck(char *name)
- {
- unsigned i;
+diff -upr ../cyrus-imapd-2.2.12.orig/imap/imapd.c ./imap/imapd.c
+--- ../cyrus-imapd-2.2.12.orig/imap/imapd.c 2005-02-14 07:39:55.000000000 +0100
++++ ./imap/imapd.c 2005-04-21 00:59:50.865255448 +0200
+@@ -3923,10 +3923,12 @@ void cmd_rename(const char *tag,
+ }
+ }
+
++#ifdef notdef
+ /* verify that the mailbox doesn't have a wildcard in it */
+ for (p = oldmailboxname; !r && *p; p++) {
+ if (*p == '*' || *p == '%') r = IMAP_MAILBOX_BADNAME;
+ }
++#endif
+
+ /* attempt to rename the base mailbox */
+ if (!r) {
+Kun i ./imap: imapd.c.orig
+diff -upr ../cyrus-imapd-2.2.12.orig/imap/mboxlist.c ./imap/mboxlist.c
+--- ../cyrus-imapd-2.2.12.orig/imap/mboxlist.c 2004-07-26 20:08:03.000000000 +0200
++++ ./imap/mboxlist.c 2005-04-21 00:59:50.874254080 +0200
+@@ -476,10 +476,12 @@ mboxlist_mycreatemailboxcheck(char *name
+ free(acl);
+ return IMAP_PERMISSION_DENIED;
+ }
++#ifdef notdef
+ /* disallow wildcards in userids with inboxes. */
+ if (strchr(mbox, '*') || strchr(mbox, '%') || strchr(mbox, '?')) {
+ return IMAP_MAILBOX_BADNAME;
+ }
++#endif
+
+ /*
+ * Users by default have all access to their personal mailbox(es),
+diff -upr ../cyrus-imapd-2.2.12.orig/imap/mboxname.c ./imap/mboxname.c
+--- ../cyrus-imapd-2.2.12.orig/imap/mboxname.c 2005-02-14 07:39:57.000000000 +0100
++++ ./imap/mboxname.c 2005-04-21 00:59:50.879253320 +0200
+@@ -649,8 +649,13 @@ int mboxname_netnewscheck(char *name)
+ /*
+ * Apply site policy restrictions on mailbox names.
+ * Restrictions are hardwired for now.
+- */
++
++ * original definition
+ #define GOODCHARS " +,-.0123456789:=@ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz~"
++ */
++
++#define GOODCHARS " #$%'()*+,-.0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[]^_`abcdefghijklmnopqrstuvwxyz{|}~"
++
+ int mboxname_policycheck(char *name)
+ {
+ unsigned i;
+Kun i ./imap: mboxname.c.orig
diff --git a/imapd/kolab.patch b/imapd/kolab.patch
index 8ec525c..a647162 100644
--- a/imapd/kolab.patch
+++ b/imapd/kolab.patch
@@ -1,5 +1,5 @@
---- ../imapd.orig/imapd.spec 2004-07-02 17:17:54.000000000 +0200
-+++ imapd.spec 2004-10-09 00:34:37.000000000 +0200
+--- ../imapd.orig/imapd.spec 2005-02-21 18:02:27.000000000 +0100
++++ imapd.spec 2005-04-21 00:51:04.705243928 +0200
@@ -3,6 +3,9 @@
## Copyright (c) 2000-2005 The OpenPKG Project <http://www.openpkg.org/>
## Copyright (c) 2000-2005 Ralf S. Engelschall <rse@engelschall.com>
@@ -10,7 +10,7 @@
##
## Permission to use, copy, modify, and distribute this software for
## any purpose with or without fee is hereby granted, provided that
-@@ -34,13 +37,15 @@ Class: BASE
+@@ -34,13 +37,16 @@ Class: BASE
Group: Mail
License: BSD
Version: 2.2.12
@@ -28,20 +28,22 @@
+%option with_drac no
+%option with_annotate no
+%option with_ldap no
++%option with_goodchars no
# list of sources
Source0: ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/cyrus-imapd-%{version}.tar.gz
-@@ -50,6 +55,9 @@ Source3: imapd.conf
+@@ -50,6 +56,10 @@ Source3: imapd.conf
Source4: fsl.imapd
Patch0: imapd.patch
Patch1: imapd.patch.group
+Patch2: imapd.annotate.patch
+Patch3: kolab-ldap.patch
+Patch4: imapd.group2.patch
++Patch5: imapd-goodchars.patch
# build information
Prefix: %{l_prefix}
-@@ -62,6 +70,10 @@ PreReq: sasl, db >= 4.1.24, openss
+@@ -62,6 +72,10 @@ PreReq: sasl, db >= 4.2.52, openss
BuildPreReq: fsl >= 1.2.0
PreReq: fsl >= 1.2.0
%endif
@@ -52,7 +54,7 @@
AutoReq: no
AutoReqProv: no
-@@ -88,6 +100,7 @@ AutoReqProv: no
+@@ -88,6 +102,7 @@ AutoReqProv: no
%{l_shtool} subst \
-e 's;/etc/imapd\.group;%{l_prefix}/etc/imapd/imapd.group;' \
lib/auth_unix.c
@@ -60,7 +62,7 @@
%endif
%if "%{with_drac}" == "yes"
%{l_shtool} subst -e 's;@DRACLIBS@;-ldrac;g' contrib/drac_auth.patch
-@@ -95,6 +108,13 @@ AutoReqProv: no
+@@ -95,6 +110,16 @@ AutoReqProv: no
sleep 1
touch configure
%endif
@@ -70,6 +72,9 @@
+%if "%{with_ldap}" == "yes"
+ %patch -p0 -P 3
+%endif
++%if "%{with_goodchars}" == "yes"
++ %patch -p1 -P 5
++%endif
+
%{l_shtool} subst \
-e 's;-L/usr/local/lib;;g' \