IMAP and POP3 Server Written Primarily with Security in Mind

Edit Package dovecot23

Dovecot is an IMAP and POP3 server for Linux and UNIX-like systems,
written primarily with security in mind. Although it is written in C,
it uses several coding techniques to avoid most of the common pitfalls.

Dovecot can work with standard mbox and maildir formats and is fully
compatible with UW-IMAP and Courier IMAP servers as well as mail
clients accessing the mailboxes directly.

Refresh
Refresh
Source Files (show unmerged sources)
Filename Size Changed
dovecot-2.0.configfiles 0000001000 1000 Bytes
dovecot-2.1-pigeonhole.configfiles 0000000074 74 Bytes
dovecot-2.1.configfiles 0000001117 1.09 KB
dovecot-2.2-pigeonhole.configfiles 0000000149 149 Bytes
dovecot-2.2.configfiles 0000001127 1.1 KB
dovecot-2.3-pigeonhole-0.5.21.tar.gz 0001955945 1.87 MB
dovecot-2.3-pigeonhole-0.5.21.tar.gz.sig 0000000866 866 Bytes
dovecot-2.3-pigeonhole.configfiles 0000000149 149 Bytes
dovecot-2.3.0-better_ssl_defaults.patch 0000002629 2.57 KB
dovecot-2.3.0-dont_use_etc_ssl_certs.patch 0000005303 5.18 KB
dovecot-2.3.21.tar.gz 0007837242 7.47 MB
dovecot-2.3.21.tar.gz.sig 0000000866 866 Bytes
dovecot-2.3.configfiles 0000001123 1.1 KB
dovecot-rpmlintrc 0000000122 122 Bytes
dovecot23.changes 0000124372 121 KB
dovecot23.keyring 0000004018 3.92 KB
dovecot23.spec 0000028026 27.4 KB
fix-build-with-openssl-3.patch 0000001140 1.11 KB
fix-strict-aliasing.patch 0000003028 2.96 KB
Latest Revision
buildservice-autocommit accepted request 1123902 from Dirk Mueller's avatar Dirk Mueller (dirkmueller) (revision 120)
baserev update by copy to link target
Comments 7

Johannes Nohl's avatar

Could you build dovecot23 with options --with-stemmer and --with-textcat (requires snowball libstemmer0d libexttextcat and to compile snowball-devel libexttextcat-devel) as these are necessary for dovecot23-fts-flatcurve.

https://github.com/slusarz/dovecot-fts-flatcurve/

Flatcurve just recently reached version 1.0.0 and will be, according to official dovecot documentation, included in dovecot 2.4. However, as a final version it is available since dovecot 2.3.17.


Christian Wittmer's avatar

I am preparing an update ... here:
https://build.opensuse.org/package/show/home:computersalat:devel:mail/dovecot23
did build the plugin here:
https://build.opensuse.org/package/show/server:mail/dovecot23-fts-flatcurve
kindly test if that works for you ...


Marcus Rueckert's avatar

why not just submit the packages from my home? I mean your fts-flatcurve package looks like a copy of mine anyway?


Johannes Nohl's avatar

Unfortunately your builds do NOT work, for the reasons stated initially.

indexer-worker(testbox)<11615><4KumDl0To2VfLQAA0J78UA>: Error: fts: Failed to initialize backend 'flatcurve': fts-flatcurve: Invalid settings
indexer-worker(testbox)<11615><4KumDl0To2VfLQAA0J78UA>: Error: fts-flatcurve: fts_filter_snowball: Snowball support not built in

I guess if you add Snowball support textcat support would fail, too ;-)

After I rebuild your dovecot32 packages with stemmer- and textcat-support, everything works as expected. Strangely my packages are 45 MiB bigger than yours?!

Your/darix's dovecot23-fts-flatcurve package works well, however. So in conclusion, it can only exist where also snowball and textcat-libraries are available (at least leap 15.5).


Johannes Nohl's avatar

Please also consider AppArmor. Here I can recommend:

Add in /etc/apparmor.d/usr.sbin.dovecot (indexer is only for dispatching, does not need its own profile imho):

 /usr/lib/dovecot/indexer mrix,
  /usr/lib/dovecot/indexer-worker mrPx,

And accordingly a new file in /etc/apparmor.d/usr.lib.dovecot.indexer-worker like this:

# ------------------------------------------------------------------
#
#    Copyright (C) 2023 Johannes Nohl
#
# ------------------------------------------------------------------
# vim: ft=apparmor

abi <abi/3.0>,

include <tunables/global>
include <tunables/dovecot>

profile dovecot-indexer-worker /usr/lib/dovecot/indexer-worker {
  include <abstractions/base>
  include <abstractions/nameservice>
  include <abstractions/dovecot-common>

  capability setuid,
  capability sys_chroot,
  capability sys_resource,
  capability dac_read_search,
  capability dac_override,

  @{DOVECOT_MAILSTORE}/** r,
  @{DOVECOT_MAILSTORE}/*/Maildir/** rl,
  @{DOVECOT_MAILSTORE}/*/Maildir/**dovecot-uidlist* rwk,
  @{DOVECOT_MAILSTORE}/*/Indizes/** rwlk,

  /etc/dovecot/dovecot.conf r,
  /etc/dovecot/{auth,conf}.d/*.conf r,

  @{PROC}/@{pid}/{stat,io} r,

  /usr/lib/dovecot/indexer-worker rmix,
  /usr/share/libexttextcat/** r,
  /usr/share/icu/** r,
  /usr/share/dovecot/stopwords/** r,

  # Site-specific additions and overrides. See local/README for details.
  include if exists <local/usr.lib.dovecot.indexer-worker>
}

^^ The path Indizes/ above is specific for me as tunables/dovecot does not consider a separate folder for that.


Marcus Rueckert's avatar

we can not globally turn on the stemmer/textcat option because the libraries are not available on older distros.


Johannes Nohl's avatar

Sorry if I get it wrong totally if that's not possible with packaging. But why not ship a different /usr/lib64/dovecot-fts.so with package dovecot23-fts-flatcurve that overwrites the one from package dovecot23?

Thus, nobody would be bothered if not using flatcurve. Also the package might be 45 MiB smaller for users of dovecot23-fts-* packages (or I am simply not good in compiling). Please see:

nm /usr/lib64/dovecot/libdovecot-fts.so* | grep snowball
nm /usr/lib64/dovecot/libdovecot-fts.so* | grep textcat
openSUSE Build Service is sponsored by