Univention Bugzilla – Bug 46893
[4.2] Dovecot listener does not copy uid+gid, when moving files over filesystem boundaries
Last modified: 2018-05-08 14:57:12 CEST
+++ This bug was initially created as a clone of Bug #46892 +++ Turns out shutil.move() → copytree() → copy2() → copystat() does not copy the uid and gid of files/dirs. Add the required code to move_user_home() in mail/univention-mail-dovecot/modules/univention/mail/dovecot.py
[4.2-3] 115375dda0 Bug #46893: set UID and GID on move target [4.2-3] 185978f9c4 Bug #46893: changelog [4.2-3] 18dcb641f4 Bug #46893: advisory univention-mail-dovecot (3.0.1-7)
[4.2-3] 25413fbe9c Bug #46893: chown only if necessary [4.2-3] b7e7d7c5c6 Bug #46893: changelog [4.2-3] 49dbfdd906 Bug #46893: advisory update univention-mail-dovecot (3.0.1-8)
# dd if=/dev/zero of=/mailspool bs=1M count=500 # mkfs.ext4 /mailspool # mount /mailspool /var/spool/dovecot/private/domainb.local # ucr set mail/dovecot/mailbox/rename=yes # service univention-directory-listener restart # Delivered 10000 mails to abc@domaina.local and changed mailPrimaryAddress afterwards to abc@domainb.local → mails have been copied from /var/spool/dovecot/private/domaina.local/abc/Maildir to /var/spool/dovecot/private/domainb.local/abc/Maildir → with old package: files were owned by root:nogroup → with new package: files were owned by dovemail:dovemail Moving 10.000 mails took less than 3 seconds inclusive recursive chown. OK: code change OK: functional change OK: tests FIXED: advisory
--- mirror/ftp/4.2/unmaintained/component/4.2-3-errata/source/univention-mail-dovecot_3.0.1-6A~4.2.0.201712211551.dsc +++ apt/ucs_4.2-0-errata4.2-3/source/univention-mail-dovecot_3.0.1-8A~4.2.0.201804271108.dsc @@ -1,6 +1,14 @@ -3.0.1-6A~4.2.0.201712211551 [Thu, 21 Dec 2017 15:51:25 +0100] Univention builddaemon <buildd@univention.de>: +3.0.1-8A~4.2.0.201804271108 [Fri, 27 Apr 2018 11:08:10 +0200] Univention builddaemon <buildd@univention.de>: * UCS auto build. No patches were applied to the original source package + +3.0.1-8 [Fri, 27 Apr 2018 11:05:30 +0200] Daniel Troeder <troeder@univention.de>: + + * Bug #46893: chown only if necessary + +3.0.1-7 [Fri, 27 Apr 2018 10:12:11 +0200] Daniel Troeder <troeder@univention.de>: + + * Bug #46893: set UID and GID on move target 3.0.1-6 [Thu, 21 Dec 2017 15:47:59 +0100] Sönke Schwardt-Krummrich <schwardt@univention.de>:
<http://errata.software-univention.de/ucs/4.2/408.html>