[arch-commits] Commit in dovecot/repos (14 files)

Andreas Radke andyrtr at archlinux.org
Tue Apr 28 19:14:18 UTC 2015


    Date: Tuesday, April 28, 2015 @ 21:14:18
  Author: andyrtr
Revision: 238229

archrelease: copy trunk to extra-i686, extra-x86_64

Added:
  dovecot/repos/extra-i686/CVE-2015-3420.patch
    (from rev 238228, dovecot/trunk/CVE-2015-3420.patch)
  dovecot/repos/extra-i686/PKGBUILD
    (from rev 238228, dovecot/trunk/PKGBUILD)
  dovecot/repos/extra-i686/dovecot.install
    (from rev 238228, dovecot/trunk/dovecot.install)
  dovecot/repos/extra-i686/dovecot.tmpfilesd
    (from rev 238228, dovecot/trunk/dovecot.tmpfilesd)
  dovecot/repos/extra-x86_64/CVE-2015-3420.patch
    (from rev 238228, dovecot/trunk/CVE-2015-3420.patch)
  dovecot/repos/extra-x86_64/PKGBUILD
    (from rev 238228, dovecot/trunk/PKGBUILD)
  dovecot/repos/extra-x86_64/dovecot.install
    (from rev 238228, dovecot/trunk/dovecot.install)
  dovecot/repos/extra-x86_64/dovecot.tmpfilesd
    (from rev 238228, dovecot/trunk/dovecot.tmpfilesd)
Deleted:
  dovecot/repos/extra-i686/PKGBUILD
  dovecot/repos/extra-i686/dovecot.install
  dovecot/repos/extra-i686/dovecot.tmpfilesd
  dovecot/repos/extra-x86_64/PKGBUILD
  dovecot/repos/extra-x86_64/dovecot.install
  dovecot/repos/extra-x86_64/dovecot.tmpfilesd

----------------------------------+
 /PKGBUILD                        |  202 +++++++++++++++++++++++++++++++++++++
 /dovecot.install                 |   20 +++
 /dovecot.tmpfilesd               |    2 
 extra-i686/CVE-2015-3420.patch   |   58 ++++++++++
 extra-i686/PKGBUILD              |   96 -----------------
 extra-i686/dovecot.install       |   10 -
 extra-i686/dovecot.tmpfilesd     |    1 
 extra-x86_64/CVE-2015-3420.patch |   58 ++++++++++
 extra-x86_64/PKGBUILD            |   96 -----------------
 extra-x86_64/dovecot.install     |   10 -
 extra-x86_64/dovecot.tmpfilesd   |    1 
 11 files changed, 340 insertions(+), 214 deletions(-)

Copied: dovecot/repos/extra-i686/CVE-2015-3420.patch (from rev 238228, dovecot/trunk/CVE-2015-3420.patch)
===================================================================
--- extra-i686/CVE-2015-3420.patch	                        (rev 0)
+++ extra-i686/CVE-2015-3420.patch	2015-04-28 19:14:18 UTC (rev 238229)
@@ -0,0 +1,58 @@
+
+diff -r a2d342257b25 -r 86f535375750 src/login-common/ssl-proxy-openssl.c
+--- a/src/login-common/ssl-proxy-openssl.c	Sat Apr 25 12:16:07 2015 +0300
++++ b/src/login-common/ssl-proxy-openssl.c	Tue Apr 28 11:27:04 2015 +0200
+@@ -80,6 +80,7 @@
+ 	unsigned int cert_broken:1;
+ 	unsigned int client_proxy:1;
+ 	unsigned int flushing:1;
++	unsigned int failed:1;
+ };
+ 
+ struct ssl_parameters {
+@@ -131,6 +132,12 @@
+ static int ssl_proxy_ctx_get_pkey_ec_curve_name(const struct master_service_ssl_settings *set);
+ #endif
+ 
++static void ssl_proxy_destroy_failed(struct ssl_proxy *proxy)
++{
++	proxy->failed = TRUE;
++	ssl_proxy_destroy(proxy);
++}
++
+ static unsigned int ssl_server_context_hash(const struct ssl_server_context *ctx)
+ {
+ 	unsigned int i, g, h = 0;
+@@ -462,7 +469,7 @@
+ 
+ 	if (errstr != NULL) {
+ 		proxy->last_error = i_strdup(errstr);
+-		ssl_proxy_destroy(proxy);
++		ssl_proxy_destroy_failed(proxy);
+ 	}
+ 	ssl_proxy_unref(proxy);
+ }
+@@ -492,7 +499,7 @@
+ 
+ 	if (proxy->handshake_callback != NULL) {
+ 		if (proxy->handshake_callback(proxy->handshake_context) < 0)
+-			ssl_proxy_destroy(proxy);
++			ssl_proxy_destroy_failed(proxy);
+ 	}
+ }
+ 
+@@ -822,7 +829,8 @@
+ 	if (proxy->destroyed || proxy->flushing)
+ 		return;
+ 	proxy->flushing = TRUE;
+-	ssl_proxy_flush(proxy);
++	if (!proxy->failed && proxy->handshaked)
++		ssl_proxy_flush(proxy);
+ 	proxy->destroyed = TRUE;
+ 
+ 	ssl_proxy_count--;
+
+
+
+
+

Deleted: extra-i686/PKGBUILD
===================================================================
--- extra-i686/PKGBUILD	2015-04-28 19:13:10 UTC (rev 238228)
+++ extra-i686/PKGBUILD	2015-04-28 19:14:18 UTC (rev 238229)
@@ -1,96 +0,0 @@
-# $Id$
-# Maintainer: Andreas Radke <andyrtr at archlinux.org>
-# Contributor: Paul Mattal <paul at mattal.com>
-# Contributor: Federico Quagliata (quaqo) <quaqo at despammed.com>
-# Contributor: GARETTE Emmanuel <gnunux at laposte dot net>
-
-
-# --->>> remember to rebuild/bump pigeonhole in one step <<<---
-
-pkgname=dovecot
-pkgver=2.2.16
-pkgrel=1
-pkgdesc="An IMAP and POP3 server written with security primarily in mind"
-arch=('i686' 'x86_64')
-url="http://dovecot.org/"
-license=("LGPL")
-depends=('krb5' 'openssl' 'sqlite' 'libmariadbclient'
-        'postgresql-libs' 'bzip2' 'lz4' 'expat' 'curl')
-makedepends=('pam' 'libcap' 'libldap' 'clucene')
-optdepends=('libldap: ldap plugin'
-            'xz: imap zlib  plugin'
-            'clucene: alternative FTS indexer')
-provides=('imap-server' 'pop3-server')
-install=$pkgname.install
-source=(http://dovecot.org/releases/2.2/${pkgname}-${pkgver}.tar.gz{,.sig}
-        dovecot.tmpfilesd)
-md5sums=('8dba21e817b4239e462d98a925233418'
-         'SKIP'
-         '342a28251d40f983c98c0d1f1bf3d07d')
-validpgpkeys=('E643F0BDFDCD04D9FFCB6279C948525140558AC9') # Timo Sirainen <tss at iki.fi>
-
-prepare() {
-  cd $pkgname-$pkgver
-
-  # fix path in helper script
-  sed -i 's:OPENSSLCONFIG=${OPENSSLCONFIG-dovecot-openssl.cnf}:OPENSSLCONFIG=${OPENSSLCONFIG- /etc/ssl/dovecot-openssl.cnf}:' doc/mkcert.sh
-}
-
-build() {
-  cd $pkgname-$pkgver
-  # configure with openssl, mysql, and postgresql support
-  ./configure --prefix=/usr --sysconfdir=/etc \
-    --sbindir=/usr/bin \
-    --localstatedir=/var \
-  	--libexecdir=/usr/lib \
-  	--with-moduledir=/usr/lib/dovecot/modules \
-  	--with-systemdsystemunitdir=/usr/lib/systemd/system \
-	--disable-static \
-	--with-nss \
-	--with-pam \
-	--with-mysql \
-	--with-pgsql \
-	--with-sqlite \
-	--with-ssl=openssl \
-	--with-ssldir=/etc/ssl \
-	--with-gssapi \
-	--with-ldap=plugin \
-	--with-zlib \
-	--with-bzlib \
-	--with-lzma \
-	--with-lz4 \
-	--with-libcap \
-	--with-solr \
-	--with-lucene \
-	--with-docs #--help
-  make
-}
-
-check() {
-  cd $pkgname-$pkgver
-  make
-}
-
-package() {
-	
-  # system user/group dovenull - 74
-  # system user/group dovecot  - 76
-  
-  cd $pkgname-$pkgver
-  make DESTDIR=${pkgdir} install
-
-  # install example conf files and ssl.conf
-  install -d -m755 ${pkgdir}/etc/dovecot/conf.d
-  install -m 644 ${pkgdir}/usr/share/doc/dovecot/example-config/dovecot.conf ${pkgdir}/etc/dovecot/dovecot.conf.sample
-  install -d -m755 ${pkgdir}/etc/ssl
-  install -m 644  ${srcdir}/$pkgname-$pkgver/doc/dovecot-openssl.cnf ${pkgdir}/etc/ssl/dovecot-openssl.cnf.sample
-
-  # install mkcert helper script
-  install -m 755  ${srcdir}/$pkgname-$pkgver/doc/mkcert.sh ${pkgdir}/usr/lib/dovecot/mkcert.sh
-
-  rm ${pkgdir}/etc/dovecot/README
-  
-  # systemd tmpfile
-  install -d -m755 ${pkgdir}/usr/lib/tmpfiles.d
-  install -m 644  ${srcdir}/dovecot.tmpfilesd ${pkgdir}/usr/lib/tmpfiles.d/dovecot.conf
-}

Copied: dovecot/repos/extra-i686/PKGBUILD (from rev 238228, dovecot/trunk/PKGBUILD)
===================================================================
--- extra-i686/PKGBUILD	                        (rev 0)
+++ extra-i686/PKGBUILD	2015-04-28 19:14:18 UTC (rev 238229)
@@ -0,0 +1,101 @@
+# $Id$
+# Maintainer: Andreas Radke <andyrtr at archlinux.org>
+# Contributor: Paul Mattal <paul at mattal.com>
+# Contributor: Federico Quagliata (quaqo) <quaqo at despammed.com>
+# Contributor: GARETTE Emmanuel <gnunux at laposte dot net>
+
+
+# --->>> remember to rebuild/bump pigeonhole in one step <<<---
+
+pkgname=dovecot
+pkgver=2.2.16
+pkgrel=2
+pkgdesc="An IMAP and POP3 server written with security primarily in mind"
+arch=('i686' 'x86_64')
+url="http://dovecot.org/"
+license=("LGPL")
+depends=('krb5' 'openssl' 'sqlite' 'libmariadbclient'
+        'postgresql-libs' 'bzip2' 'lz4' 'expat' 'curl')
+makedepends=('pam' 'libcap' 'libldap' 'clucene')
+optdepends=('libldap: ldap plugin'
+            'xz: imap zlib  plugin'
+            'clucene: alternative FTS indexer')
+provides=('imap-server' 'pop3-server')
+install=$pkgname.install
+source=(http://dovecot.org/releases/2.2/${pkgname}-${pkgver}.tar.gz{,.sig}
+        CVE-2015-3420.patch
+        dovecot.tmpfilesd)
+md5sums=('8dba21e817b4239e462d98a925233418'
+         'SKIP'
+         '730366bb5895a3092f1b6511e254709a'
+         '342a28251d40f983c98c0d1f1bf3d07d')
+validpgpkeys=('E643F0BDFDCD04D9FFCB6279C948525140558AC9') # Timo Sirainen <tss at iki.fi>
+
+prepare() {
+  cd $pkgname-$pkgver
+  
+  # https://bugs.archlinux.org/task/44757
+  patch -Np1 -i ${srcdir}/CVE-2015-3420.patch
+  
+  # fix path in helper script
+  sed -i 's:OPENSSLCONFIG=${OPENSSLCONFIG-dovecot-openssl.cnf}:OPENSSLCONFIG=${OPENSSLCONFIG- /etc/ssl/dovecot-openssl.cnf}:' doc/mkcert.sh
+}
+
+build() {
+  cd $pkgname-$pkgver
+  # configure with openssl, mysql, and postgresql support
+  ./configure --prefix=/usr --sysconfdir=/etc \
+    --sbindir=/usr/bin \
+    --localstatedir=/var \
+  	--libexecdir=/usr/lib \
+  	--with-moduledir=/usr/lib/dovecot/modules \
+  	--with-systemdsystemunitdir=/usr/lib/systemd/system \
+	--disable-static \
+	--with-nss \
+	--with-pam \
+	--with-mysql \
+	--with-pgsql \
+	--with-sqlite \
+	--with-ssl=openssl \
+	--with-ssldir=/etc/ssl \
+	--with-gssapi \
+	--with-ldap=plugin \
+	--with-zlib \
+	--with-bzlib \
+	--with-lzma \
+	--with-lz4 \
+	--with-libcap \
+	--with-solr \
+	--with-lucene \
+	--with-docs #--help
+  make
+}
+
+check() {
+  cd $pkgname-$pkgver
+  make
+}
+
+package() {
+	
+  # system user/group dovenull - 74
+  # system user/group dovecot  - 76
+  
+  cd $pkgname-$pkgver
+  make DESTDIR=${pkgdir} install
+
+  # install example conf files and ssl.conf
+  install -d -m755 ${pkgdir}/etc/dovecot/conf.d
+  install -m 644 ${pkgdir}/usr/share/doc/dovecot/example-config/dovecot.conf ${pkgdir}/etc/dovecot/dovecot.conf.sample
+  install -d -m755 ${pkgdir}/etc/ssl
+  install -m 644  ${srcdir}/$pkgname-$pkgver/doc/dovecot-openssl.cnf ${pkgdir}/etc/ssl/dovecot-openssl.cnf.sample
+
+  # install mkcert helper script
+  install -m 755  ${srcdir}/$pkgname-$pkgver/doc/mkcert.sh ${pkgdir}/usr/lib/dovecot/mkcert.sh
+
+  rm ${pkgdir}/etc/dovecot/README
+  
+  # systemd tmpfile
+  install -d -m755 ${pkgdir}/usr/lib/tmpfiles.d
+  install -m 644  ${srcdir}/dovecot.tmpfilesd ${pkgdir}/usr/lib/tmpfiles.d/dovecot.conf
+}

Deleted: extra-i686/dovecot.install
===================================================================
--- extra-i686/dovecot.install	2015-04-28 19:13:10 UTC (rev 238228)
+++ extra-i686/dovecot.install	2015-04-28 19:14:18 UTC (rev 238229)
@@ -1,10 +0,0 @@
-post_install() {
-  getent group dovenull &> /dev/null || groupadd -g 74 dovenull &> /dev/null
-  getent group dovecot &> /dev/null  || groupadd -g 76 dovecot &> /dev/null
-  getent passwd dovenull &> /dev/null || useradd -s /sbin/nologin -c "Dovecot user for completely untrustworthy processes" -d /var/empty -u 74 -g dovenull -r dovenull &> /dev/null
-  getent passwd dovecot &> /dev/null  || useradd -s /sbin/nologin -c "Dovecot user" -d /var/empty -u 76 -g dovecot -r dovecot &> /dev/null
-}
-
-post_remove() {
-  rm -rf /var/run/dovecot/ &> /dev/null || /bin/true
-}

Copied: dovecot/repos/extra-i686/dovecot.install (from rev 238228, dovecot/trunk/dovecot.install)
===================================================================
--- extra-i686/dovecot.install	                        (rev 0)
+++ extra-i686/dovecot.install	2015-04-28 19:14:18 UTC (rev 238229)
@@ -0,0 +1,10 @@
+post_install() {
+  getent group dovenull &> /dev/null || groupadd -g 74 dovenull &> /dev/null
+  getent group dovecot &> /dev/null  || groupadd -g 76 dovecot &> /dev/null
+  getent passwd dovenull &> /dev/null || useradd -s /sbin/nologin -c "Dovecot user for completely untrustworthy processes" -d /var/empty -u 74 -g dovenull -r dovenull &> /dev/null
+  getent passwd dovecot &> /dev/null  || useradd -s /sbin/nologin -c "Dovecot user" -d /var/empty -u 76 -g dovecot -r dovecot &> /dev/null
+}
+
+post_remove() {
+  rm -rf /var/run/dovecot/ &> /dev/null || /bin/true
+}

Deleted: extra-i686/dovecot.tmpfilesd
===================================================================
--- extra-i686/dovecot.tmpfilesd	2015-04-28 19:13:10 UTC (rev 238228)
+++ extra-i686/dovecot.tmpfilesd	2015-04-28 19:14:18 UTC (rev 238229)
@@ -1 +0,0 @@
-d /var/run/dovecot 0755 root dovecot -

Copied: dovecot/repos/extra-i686/dovecot.tmpfilesd (from rev 238228, dovecot/trunk/dovecot.tmpfilesd)
===================================================================
--- extra-i686/dovecot.tmpfilesd	                        (rev 0)
+++ extra-i686/dovecot.tmpfilesd	2015-04-28 19:14:18 UTC (rev 238229)
@@ -0,0 +1 @@
+d /var/run/dovecot 0755 root dovecot -

Copied: dovecot/repos/extra-x86_64/CVE-2015-3420.patch (from rev 238228, dovecot/trunk/CVE-2015-3420.patch)
===================================================================
--- extra-x86_64/CVE-2015-3420.patch	                        (rev 0)
+++ extra-x86_64/CVE-2015-3420.patch	2015-04-28 19:14:18 UTC (rev 238229)
@@ -0,0 +1,58 @@
+
+diff -r a2d342257b25 -r 86f535375750 src/login-common/ssl-proxy-openssl.c
+--- a/src/login-common/ssl-proxy-openssl.c	Sat Apr 25 12:16:07 2015 +0300
++++ b/src/login-common/ssl-proxy-openssl.c	Tue Apr 28 11:27:04 2015 +0200
+@@ -80,6 +80,7 @@
+ 	unsigned int cert_broken:1;
+ 	unsigned int client_proxy:1;
+ 	unsigned int flushing:1;
++	unsigned int failed:1;
+ };
+ 
+ struct ssl_parameters {
+@@ -131,6 +132,12 @@
+ static int ssl_proxy_ctx_get_pkey_ec_curve_name(const struct master_service_ssl_settings *set);
+ #endif
+ 
++static void ssl_proxy_destroy_failed(struct ssl_proxy *proxy)
++{
++	proxy->failed = TRUE;
++	ssl_proxy_destroy(proxy);
++}
++
+ static unsigned int ssl_server_context_hash(const struct ssl_server_context *ctx)
+ {
+ 	unsigned int i, g, h = 0;
+@@ -462,7 +469,7 @@
+ 
+ 	if (errstr != NULL) {
+ 		proxy->last_error = i_strdup(errstr);
+-		ssl_proxy_destroy(proxy);
++		ssl_proxy_destroy_failed(proxy);
+ 	}
+ 	ssl_proxy_unref(proxy);
+ }
+@@ -492,7 +499,7 @@
+ 
+ 	if (proxy->handshake_callback != NULL) {
+ 		if (proxy->handshake_callback(proxy->handshake_context) < 0)
+-			ssl_proxy_destroy(proxy);
++			ssl_proxy_destroy_failed(proxy);
+ 	}
+ }
+ 
+@@ -822,7 +829,8 @@
+ 	if (proxy->destroyed || proxy->flushing)
+ 		return;
+ 	proxy->flushing = TRUE;
+-	ssl_proxy_flush(proxy);
++	if (!proxy->failed && proxy->handshaked)
++		ssl_proxy_flush(proxy);
+ 	proxy->destroyed = TRUE;
+ 
+ 	ssl_proxy_count--;
+
+
+
+
+

Deleted: extra-x86_64/PKGBUILD
===================================================================
--- extra-x86_64/PKGBUILD	2015-04-28 19:13:10 UTC (rev 238228)
+++ extra-x86_64/PKGBUILD	2015-04-28 19:14:18 UTC (rev 238229)
@@ -1,96 +0,0 @@
-# $Id$
-# Maintainer: Andreas Radke <andyrtr at archlinux.org>
-# Contributor: Paul Mattal <paul at mattal.com>
-# Contributor: Federico Quagliata (quaqo) <quaqo at despammed.com>
-# Contributor: GARETTE Emmanuel <gnunux at laposte dot net>
-
-
-# --->>> remember to rebuild/bump pigeonhole in one step <<<---
-
-pkgname=dovecot
-pkgver=2.2.16
-pkgrel=1
-pkgdesc="An IMAP and POP3 server written with security primarily in mind"
-arch=('i686' 'x86_64')
-url="http://dovecot.org/"
-license=("LGPL")
-depends=('krb5' 'openssl' 'sqlite' 'libmariadbclient'
-        'postgresql-libs' 'bzip2' 'lz4' 'expat' 'curl')
-makedepends=('pam' 'libcap' 'libldap' 'clucene')
-optdepends=('libldap: ldap plugin'
-            'xz: imap zlib  plugin'
-            'clucene: alternative FTS indexer')
-provides=('imap-server' 'pop3-server')
-install=$pkgname.install
-source=(http://dovecot.org/releases/2.2/${pkgname}-${pkgver}.tar.gz{,.sig}
-        dovecot.tmpfilesd)
-md5sums=('8dba21e817b4239e462d98a925233418'
-         'SKIP'
-         '342a28251d40f983c98c0d1f1bf3d07d')
-validpgpkeys=('E643F0BDFDCD04D9FFCB6279C948525140558AC9') # Timo Sirainen <tss at iki.fi>
-
-prepare() {
-  cd $pkgname-$pkgver
-
-  # fix path in helper script
-  sed -i 's:OPENSSLCONFIG=${OPENSSLCONFIG-dovecot-openssl.cnf}:OPENSSLCONFIG=${OPENSSLCONFIG- /etc/ssl/dovecot-openssl.cnf}:' doc/mkcert.sh
-}
-
-build() {
-  cd $pkgname-$pkgver
-  # configure with openssl, mysql, and postgresql support
-  ./configure --prefix=/usr --sysconfdir=/etc \
-    --sbindir=/usr/bin \
-    --localstatedir=/var \
-  	--libexecdir=/usr/lib \
-  	--with-moduledir=/usr/lib/dovecot/modules \
-  	--with-systemdsystemunitdir=/usr/lib/systemd/system \
-	--disable-static \
-	--with-nss \
-	--with-pam \
-	--with-mysql \
-	--with-pgsql \
-	--with-sqlite \
-	--with-ssl=openssl \
-	--with-ssldir=/etc/ssl \
-	--with-gssapi \
-	--with-ldap=plugin \
-	--with-zlib \
-	--with-bzlib \
-	--with-lzma \
-	--with-lz4 \
-	--with-libcap \
-	--with-solr \
-	--with-lucene \
-	--with-docs #--help
-  make
-}
-
-check() {
-  cd $pkgname-$pkgver
-  make
-}
-
-package() {
-	
-  # system user/group dovenull - 74
-  # system user/group dovecot  - 76
-  
-  cd $pkgname-$pkgver
-  make DESTDIR=${pkgdir} install
-
-  # install example conf files and ssl.conf
-  install -d -m755 ${pkgdir}/etc/dovecot/conf.d
-  install -m 644 ${pkgdir}/usr/share/doc/dovecot/example-config/dovecot.conf ${pkgdir}/etc/dovecot/dovecot.conf.sample
-  install -d -m755 ${pkgdir}/etc/ssl
-  install -m 644  ${srcdir}/$pkgname-$pkgver/doc/dovecot-openssl.cnf ${pkgdir}/etc/ssl/dovecot-openssl.cnf.sample
-
-  # install mkcert helper script
-  install -m 755  ${srcdir}/$pkgname-$pkgver/doc/mkcert.sh ${pkgdir}/usr/lib/dovecot/mkcert.sh
-
-  rm ${pkgdir}/etc/dovecot/README
-  
-  # systemd tmpfile
-  install -d -m755 ${pkgdir}/usr/lib/tmpfiles.d
-  install -m 644  ${srcdir}/dovecot.tmpfilesd ${pkgdir}/usr/lib/tmpfiles.d/dovecot.conf
-}

Copied: dovecot/repos/extra-x86_64/PKGBUILD (from rev 238228, dovecot/trunk/PKGBUILD)
===================================================================
--- extra-x86_64/PKGBUILD	                        (rev 0)
+++ extra-x86_64/PKGBUILD	2015-04-28 19:14:18 UTC (rev 238229)
@@ -0,0 +1,101 @@
+# $Id$
+# Maintainer: Andreas Radke <andyrtr at archlinux.org>
+# Contributor: Paul Mattal <paul at mattal.com>
+# Contributor: Federico Quagliata (quaqo) <quaqo at despammed.com>
+# Contributor: GARETTE Emmanuel <gnunux at laposte dot net>
+
+
+# --->>> remember to rebuild/bump pigeonhole in one step <<<---
+
+pkgname=dovecot
+pkgver=2.2.16
+pkgrel=2
+pkgdesc="An IMAP and POP3 server written with security primarily in mind"
+arch=('i686' 'x86_64')
+url="http://dovecot.org/"
+license=("LGPL")
+depends=('krb5' 'openssl' 'sqlite' 'libmariadbclient'
+        'postgresql-libs' 'bzip2' 'lz4' 'expat' 'curl')
+makedepends=('pam' 'libcap' 'libldap' 'clucene')
+optdepends=('libldap: ldap plugin'
+            'xz: imap zlib  plugin'
+            'clucene: alternative FTS indexer')
+provides=('imap-server' 'pop3-server')
+install=$pkgname.install
+source=(http://dovecot.org/releases/2.2/${pkgname}-${pkgver}.tar.gz{,.sig}
+        CVE-2015-3420.patch
+        dovecot.tmpfilesd)
+md5sums=('8dba21e817b4239e462d98a925233418'
+         'SKIP'
+         '730366bb5895a3092f1b6511e254709a'
+         '342a28251d40f983c98c0d1f1bf3d07d')
+validpgpkeys=('E643F0BDFDCD04D9FFCB6279C948525140558AC9') # Timo Sirainen <tss at iki.fi>
+
+prepare() {
+  cd $pkgname-$pkgver
+  
+  # https://bugs.archlinux.org/task/44757
+  patch -Np1 -i ${srcdir}/CVE-2015-3420.patch
+  
+  # fix path in helper script
+  sed -i 's:OPENSSLCONFIG=${OPENSSLCONFIG-dovecot-openssl.cnf}:OPENSSLCONFIG=${OPENSSLCONFIG- /etc/ssl/dovecot-openssl.cnf}:' doc/mkcert.sh
+}
+
+build() {
+  cd $pkgname-$pkgver
+  # configure with openssl, mysql, and postgresql support
+  ./configure --prefix=/usr --sysconfdir=/etc \
+    --sbindir=/usr/bin \
+    --localstatedir=/var \
+  	--libexecdir=/usr/lib \
+  	--with-moduledir=/usr/lib/dovecot/modules \
+  	--with-systemdsystemunitdir=/usr/lib/systemd/system \
+	--disable-static \
+	--with-nss \
+	--with-pam \
+	--with-mysql \
+	--with-pgsql \
+	--with-sqlite \
+	--with-ssl=openssl \
+	--with-ssldir=/etc/ssl \
+	--with-gssapi \
+	--with-ldap=plugin \
+	--with-zlib \
+	--with-bzlib \
+	--with-lzma \
+	--with-lz4 \
+	--with-libcap \
+	--with-solr \
+	--with-lucene \
+	--with-docs #--help
+  make
+}
+
+check() {
+  cd $pkgname-$pkgver
+  make
+}
+
+package() {
+	
+  # system user/group dovenull - 74
+  # system user/group dovecot  - 76
+  
+  cd $pkgname-$pkgver
+  make DESTDIR=${pkgdir} install
+
+  # install example conf files and ssl.conf
+  install -d -m755 ${pkgdir}/etc/dovecot/conf.d
+  install -m 644 ${pkgdir}/usr/share/doc/dovecot/example-config/dovecot.conf ${pkgdir}/etc/dovecot/dovecot.conf.sample
+  install -d -m755 ${pkgdir}/etc/ssl
+  install -m 644  ${srcdir}/$pkgname-$pkgver/doc/dovecot-openssl.cnf ${pkgdir}/etc/ssl/dovecot-openssl.cnf.sample
+
+  # install mkcert helper script
+  install -m 755  ${srcdir}/$pkgname-$pkgver/doc/mkcert.sh ${pkgdir}/usr/lib/dovecot/mkcert.sh
+
+  rm ${pkgdir}/etc/dovecot/README
+  
+  # systemd tmpfile
+  install -d -m755 ${pkgdir}/usr/lib/tmpfiles.d
+  install -m 644  ${srcdir}/dovecot.tmpfilesd ${pkgdir}/usr/lib/tmpfiles.d/dovecot.conf
+}

Deleted: extra-x86_64/dovecot.install
===================================================================
--- extra-x86_64/dovecot.install	2015-04-28 19:13:10 UTC (rev 238228)
+++ extra-x86_64/dovecot.install	2015-04-28 19:14:18 UTC (rev 238229)
@@ -1,10 +0,0 @@
-post_install() {
-  getent group dovenull &> /dev/null || groupadd -g 74 dovenull &> /dev/null
-  getent group dovecot &> /dev/null  || groupadd -g 76 dovecot &> /dev/null
-  getent passwd dovenull &> /dev/null || useradd -s /sbin/nologin -c "Dovecot user for completely untrustworthy processes" -d /var/empty -u 74 -g dovenull -r dovenull &> /dev/null
-  getent passwd dovecot &> /dev/null  || useradd -s /sbin/nologin -c "Dovecot user" -d /var/empty -u 76 -g dovecot -r dovecot &> /dev/null
-}
-
-post_remove() {
-  rm -rf /var/run/dovecot/ &> /dev/null || /bin/true
-}

Copied: dovecot/repos/extra-x86_64/dovecot.install (from rev 238228, dovecot/trunk/dovecot.install)
===================================================================
--- extra-x86_64/dovecot.install	                        (rev 0)
+++ extra-x86_64/dovecot.install	2015-04-28 19:14:18 UTC (rev 238229)
@@ -0,0 +1,10 @@
+post_install() {
+  getent group dovenull &> /dev/null || groupadd -g 74 dovenull &> /dev/null
+  getent group dovecot &> /dev/null  || groupadd -g 76 dovecot &> /dev/null
+  getent passwd dovenull &> /dev/null || useradd -s /sbin/nologin -c "Dovecot user for completely untrustworthy processes" -d /var/empty -u 74 -g dovenull -r dovenull &> /dev/null
+  getent passwd dovecot &> /dev/null  || useradd -s /sbin/nologin -c "Dovecot user" -d /var/empty -u 76 -g dovecot -r dovecot &> /dev/null
+}
+
+post_remove() {
+  rm -rf /var/run/dovecot/ &> /dev/null || /bin/true
+}

Deleted: extra-x86_64/dovecot.tmpfilesd
===================================================================
--- extra-x86_64/dovecot.tmpfilesd	2015-04-28 19:13:10 UTC (rev 238228)
+++ extra-x86_64/dovecot.tmpfilesd	2015-04-28 19:14:18 UTC (rev 238229)
@@ -1 +0,0 @@
-d /var/run/dovecot 0755 root dovecot -

Copied: dovecot/repos/extra-x86_64/dovecot.tmpfilesd (from rev 238228, dovecot/trunk/dovecot.tmpfilesd)
===================================================================
--- extra-x86_64/dovecot.tmpfilesd	                        (rev 0)
+++ extra-x86_64/dovecot.tmpfilesd	2015-04-28 19:14:18 UTC (rev 238229)
@@ -0,0 +1 @@
+d /var/run/dovecot 0755 root dovecot -



More information about the arch-commits mailing list