Commit graph

190 commits

Author SHA1 Message Date
schmonz
24bb800d02 Update checksums to BLAKE2s, noted by wiz@. 2021-11-15 20:01:51 +00:00
nia
be020196fe mail: Remove SHA1 hashes for distfiles 2021-10-07 14:25:11 +00:00
schmonz
8d15e06bc7 Improve TLS setup instructions. Bump PKGREVISION. 2021-01-14 15:25:22 +00:00
schmonz
c6e2fac040 Remove DJB_RESTRICTED, no longer used. 2020-11-19 09:35:38 +00:00
schmonz
25968dd301 Reorder and clarify TLS setup instructions. 2020-11-02 10:43:55 +00:00
tnn
7bc7573abd qmail: mark as NOT_FOR_UNPRIVILEGED
Although the package itself builds when pkgsrc is bootstrapped in
unprivileged mode, the pkgsrc +INSTALL/+DEINSTALL scripts fail, causing
bulk build noise:

=> Creating binary package /wrk/mail/qmail/work/.packages/qmail-1.03nb49.tgz
fatal: unable to find user alias
===========================================================================

ERROR: instchown exited 111.

Permissions are likely wrong, and/or the queue may be uninitialized.

===========================================================================
pkg_add: install script returned error status
pkg_add: 1 package addition failed
2020-08-24 05:44:33 +00:00
schmonz
3948870bde Retire 'djbware-errno-hack' and associated options.mk cleverness.
Instead:

1. Package makefiles including their own options.mk
2. Packages say "SUBST_CLASSES+=djberrno" to get the hack, if needed
3. Packages adjust SUBST_FILES.djberrno, if needed

Should fix bulk build failures due to multiple inclusions of options.mk
and/or incorrect definitions of DJB_ERRNO_HACK.

Approved during the freeze by wiz@.
2020-06-25 05:42:36 +00:00
schmonz
de7f8545e7 Update to notqmail 1.08 (as qmail-1.03nb49). From the changelog:
## Fix bugs

- Vulnerabilities we've inherited from qmail 1.03, reported by Qualys.
    - CVE-2005-1515: fix signedness wraparound in `substdio_{put,bput}()`.
    - CVE-2005-1514: fix possible signed integer overflow in `commands()`.
    - CVE-2005-1513: fix integer overflow in `stralloc_readyplus()`.
    - Fix several other places where variables could overflow.
- `qmail-pop3d`: instead of running as root if root authenticates (and
  being a vector for a dictionary attack on the root password), exit 1
  to look just like a failed `checkpassword` login.
- `qmail-inject`: do not parse header recipients if `-a` is given.
- Correctly detect multiple IP addresses on the same interface.
- Remove workaround for ancient DNS servers that do not properly
  support CNAME.
- Fix possible integer overflow in `alloc()`.

## Reduce bug likelihood

- Remove `dnscname` and `dnsmxip` programs that were being built but not
  installed.
- Remove `systype` and related platform detection.
- Remove unused variable in `maildir.c`.
- Reduce variable scope in `tcpto.c`.
- Avoid local variables shadowing same-named globals.
- Avoid needing `exit.h` in named-pipe bug check.
- Add a `test` target and some unit tests, using Check.
- Add missing function declarations in `cdbmss.h`, `scan.h`.
- Add missing return types to `main()`.
- Add `hier.h` for inclusion in `instcheck.c`, `instchown.c`, `instpackage.c`.
- Use system headers and types instead of the `HASSHORTSETGROUPS` check.
- Use system headers instead of redeclaring `exit()`, `read()`,
  `write()`, `malloc()`, `free()`, `fork()`, `uint32_t`.
- Use C89 function signatures for code we've touched so far.
- Automated builds:
    - TravisCI: move setting `MAKEFLAGS` out of the script and into
      the matrix.
    - Add FreeBSD builds with CirrusCI.
    - Add a GitHub Actions build.

## Other changes

- Remove DJB's TODO.
- Replace many `pobox.com` URLs.
- Acknowledge Erik Sjölund's `qmail-local.c` bugfix that we've
  inherited from netqmail.
- Avoid generating catted manpages by building with `NROFF=true`.
- Optionally create a `systemd` service file.
- Run an alternate `qmail-remote` by setting `QMAILREMOTE` in
  `qmail-send`'s environment.

## Intent to remove

In the course of developing this release, we found programs that we
intend to remove in the next release. We believe none of these remains
necessary or useful enough to be worth the cost of maintaining. If you
disagree, please let us know!

- Remove `qsmhook`, long since replaced by `preline`.
- Remove inefficient `maildirwatch`.
- Remove obsolete mail client wrappers.
- Remove `qmail-pop3d`, since Maildir is well supported by actively
  maintained POP3 servers.
2020-05-23 20:50:02 +00:00
rillig
ba4d1eb643 mail/qmail: doesn't need the errno hack anymore
notqmail-1.07 correctly includes <errno.h> instead of declaring errno as
a process-global variable.
2020-05-02 10:47:38 +00:00
joerg
5e0e6d42ae Make sure ${TAR} is present 2020-03-18 17:56:09 +00:00
schmonz
48f34856e5 Update to tlsonlyremote 20200202 from upstream TLS patch 20200107. Adds
client cert authentication with TLS v1.3. Bump PKGREVISION.
2020-02-03 04:51:27 +00:00
jperkin
26c1bffc9f *: Recursive revision bump for openssl 1.1.1. 2020-01-18 21:48:19 +00:00
rillig
f31693dd3a mail: align variable assignments
pkglint -Wall -F --only aligned -r

No manual corrections.
2019-11-02 16:25:17 +00:00
schmonz
3539d21138 Document config-fast-pkgsrc in README.pkgsrc, too. 2019-08-29 22:04:21 +00:00
schmonz
20045859ba Update from netqmail 1.06 (2007) to notqmail 1.07 (just released). From
the changelog:

- code: remove incorrect usage of vfork()
- code: detect and prefer utmpx where available
- code: removed idedit, install-big. var-qmail packages are no more
- portability problem: explicitly initialize strerr_sys and
  define BIND_8_COMPAT to work around Mac OS X
- code: add instchown to set ownership and mode on installed files
- code: add instpackage to install without root access
- doc: rename INSTALL, SENDMAIL to INSTALL.md, SENDMAIL.md to
  support building on case-insensitive filesystems
- code: lookup uid/gid at runtime
- code: use DESTDIR environment variable as root directory in install

pkgsrc changes:

- If hostname isn't FQDN, config-fast-pkgsrc wouldn't produce a working
  config, so don't run it; tell user what to do instead
- Stage QMAIL_QUEUE_DIR into DESTDIR/tmp, to be more obvious that it's
  not being packaged up (and is not how a queue gets created at
  pkg_add time)
- Drop custom destdir, qbiffutmpx, and Darwin patches
- Rebase TLS-onlyremote, QMAILREMOTE, and SRS patches
- Require latest ucspi-ssl and ucspi-tcp6 for IPv4 fixes
- Move MESSAGE.tls to README.tls, and remove other MESSAGE*
- Set PKG_HOME even for non-default values of QMAIL_ALIAS_USER
- Check whether alias/.qmail-foo exist before trying to remove

Bump PKGREVISION.
2019-08-20 02:38:04 +00:00
schmonz
4df664b850 qmail's queue is expected to work just fine on a case-insensitive FS.
Remove the INSTALL check and warning.
2019-07-15 16:11:58 +00:00
schmonz
d5a9c6c270 BIGDNS_PATCH has been reliably reachable; remove from MASTER_SITE_LOCAL.
OUTGOINGIP_PATCH needs to come from a qmail.org mirror, as the original
domain has lapsed; get it from mine.
2019-07-01 14:57:31 +00:00
schmonz
b63849b9a4 qmail.org domain lapsed. netqmail.org has not, as yet. 2019-06-30 21:51:49 +00:00
schmonz
0b0fdd061c Use CPPFLAGS, not CFLAGS, for consistency with ucspi-tcp6 and djbdns. 2019-06-28 19:18:25 +00:00
schmonz
eb557a365d Keep it simple: libtai does not futz with PKG_SYSCONFSUBDIR. 2019-06-19 17:46:39 +00:00
schmonz
ffef6708ff Update to tlsonlyremote 20190408, cut from upstream TLS patch with the
same date. Fixes build with OpenSSL 1.1 and includes pkgsrc's #ifdef
guards for non-TLS builds. Bump PKGREVISION.
2019-04-10 22:24:57 +00:00
schmonz
dcd35d6d1c Apply the "tai-leapsecs" patch iff the 'tai-system-clock' option is set
(off by default). Bump PKGREVISION.
2019-01-17 22:49:12 +00:00
schmonz
f094649abc Add Toby Betts' "tai-leapsecs" patch to handle leap seconds correctly
when the system clock is set to TAI (and a libtai dependency to get
leapsecs.dat). While here, catch up to his latest maildiruniq patch.

Let an installed ucspi-tcp6 satisfy the ucspi-tcp dependency for
non-'inet6' builds.

Bump PKGREVISION.
2019-01-09 19:32:07 +00:00
schmonz
0c5192fa02 Bump destdir patch to build on OpenBSD. No functional change elsewhere. 2018-12-17 19:15:33 +00:00
schmonz
679c338b4c Avoid the -O (to stdout) tar option, as it's not sufficiently portable.
While here, append the specific patch file (not just the distribution)
to the qmail-spp QMAILPATCHES entry.
2018-12-16 23:46:44 +00:00
schmonz
7a5727c8f8 Just set CFLAGS.Darwin in Makefile. 2018-12-13 05:05:05 +00:00
schmonz
24a5351087 Explicitly buildlink-depend on openssl<1.1. Fixes build on
NetBSD-current (by adding dependency on security/openssl to get a
sufficiently old version). NFCI elsewhere.
2018-12-13 05:01:55 +00:00
schmonz
3557e4ae46 Take responsibility from qmail-run for creating and removing the basic
config files and aliases. Bump PKGREVISION.
2018-12-04 17:01:39 +00:00
schmonz
71e3a22671 Fix obvious bug in is_queue_fs_case_sensitive(). 2018-11-25 16:15:53 +00:00
schmonz
e1b2b69350 Entab previous. 2018-11-14 16:44:13 +00:00
schmonz
c07823e719 Build and install config-fast-pkgsrc, which is like config-fast but
installs the generated files elsewhere, so we can simulate
CONF_FILES-like behavior. qmail-run will switch to config-fast-pkgsrc.
We'll take advantage to deinstall these config files (as well as the
three basic .qmail files in ~alias) provided they haven't been changed.

Both of these commands stop leaving leftovers in ${PKG_SYSCONFDIR}:

# pkg_add qmail && pkg_delete qmail
# pkg_add qmail-run && pkg_delete -r qmail

While here, warn if the queue directory is on a case-insensitive
filesystem. Probably not gonna work perfectly.

Bump PKGREVISION.
2018-11-14 16:43:17 +00:00
schmonz
f1c346cdb7 Move patches long since non-optional out of options.mk. 2018-11-10 16:42:52 +00:00
schmonz
c73a470db2 Make PATCH_DIST_CAT.${SPP_PATCH} more portable. Fixes at least NetBSD. 2018-11-10 16:27:18 +00:00
schmonz
cc46117aaf Add a new non-optional patch: qmail-spp, a generic plugin interface for
qmail-smtpd (tweaked to tolerate the absence of a config file).

The RCPTCHECK patch is a logical subset of SPP with a slightly different
interface, and conflicts with SPP. Remove RCPTCHECK.

Bump PKGREVISION.
2018-11-10 15:29:01 +00:00
schmonz
990becf16c Provide a TLS patch without the qmail-smtpd portion, as acceptutils
20181108 implements STARTTLS in fixsmtpio(8). Rebase EAI patch onto
TLS-onlyremote. Switch back to upstream for RCPTCHECK, which applies
cleanly again. Bump PKGREVISION.
2018-11-08 20:58:08 +00:00
schmonz
6253176e63 Fix build with "eai -tls" option combination. 2018-10-25 14:02:37 +00:00
schmonz
34bcb0be30 We've been stuck on a TLS implementation from 2007 because the TLS
patch and the AUTH patch conflict, nobody else has published a newer
hand-merged combo patch, and as it happens, I'd apparently rather
write a pile of new DJB-style C than make myself responsible for
hand-merging other people's security-sensitive code every time there's
a new TLS patch.

Now that we have AUTH without patching (see mail/qmail-acceptutils), the
"sasl" option goes away, we're finally on the most recent TLS patch
available, and when it's updated it'll be easy for us to keep up.

Rebase RCPTCHECK and EAI patches onto netqmail-with-TLS-and-no-AUTH.

Bump PKGREVISION.
2018-10-24 13:32:26 +00:00
schmonz
dc734a5ce0 Actually generate the promised key sizes. Ride previous bump. 2018-09-14 16:44:09 +00:00
schmonz
f7f0927f99 The latest upstream TLS patch (netqmail-1.06-tls-20160918.patch, not yet
in pkgsrc) has bumped key sizes to 2048 bits. Do likewise. Bump PKGREVISION.
2018-09-14 09:01:53 +00:00
schmonz
59c4fc1a52 Depend on new enough sysutils/checkpassword{,-pam} such that qmail-run
can (by itself depending on pkgtools/pkg_alternatives) expect to find
"nbcheckpassword".

Remove 'qmail-rejectutils' option, which will become an unconditional
dependency in qmail-run.

Bump PKGREVISION.
2018-08-01 07:10:27 +00:00
schmonz
2566f67740 Add 'inet6' and 'pam' options to control dependencies on ucspi-tcp{6,}
and checkpassword{-pam,}. Add dependency on ucspi-ssl to 'tls' option.
Bump PKGREVISION.
2018-07-29 23:26:44 +00:00
schmonz
b81dab190f Add dependency on checkpassword-pam, since checkpassword is not yet licensed.
Ride previous PKGREVISION bump.
2018-07-25 16:42:36 +00:00
schmonz
d30d86a398 s/ucspi-tcp/ucspi-tcp6/g in dependencies. Bump PKGREVISIONs. 2018-07-25 16:32:34 +00:00
jperkin
5393242c73 *: Move SUBST_STAGE from post-patch to pre-configure
Performing substitutions during post-patch breaks tools such as mkpatches,
making it very difficult to regenerate correct patches after making changes,
and often leading to substituted string replacements being committed.
2018-07-04 13:40:07 +00:00
schmonz
0163fa74c5 Remove vestiges of rejectutils patch, missed in previous. 2018-05-28 23:39:16 +00:00
schmonz
354089cb68 Extract qmail-rejectutils to standalone package. Bump PKGREVISION. 2018-05-28 12:57:36 +00:00
rillig
b381c6e2f3 Sort PLIST files.
Unsorted entries in PLIST files have generated a pkglint warning for at
least 12 years. Somewhat more recently, pkglint has learned to sort
PLIST files automatically. Since pkglint 5.4.23, the sorting is only
done in obvious, simple cases. These have been applied by running:

  pkglint -Cnone,PLIST -Wnone,plist-sort -r -F
2018-01-01 22:29:15 +00:00
schmonz
0b29d5023c Remove compatibility mappings for options retired in 2017Q2. 2017-10-29 00:46:14 +00:00
schmonz
15ac330ba5 Update to netqmail-1.06-qbiffutmpx-20170820.patch. Should fix EL7 bulk
build. No functional change elsewhere.
2017-08-19 22:11:43 +00:00
schmonz
0401ca3d9d Update to 1.03nb32. pkgsrc changes:
- Apply the qbiff-utmpx patch to (probably) fix build on FreeBSD
- Enable "qmail-srs" by default
- Add "qmail-customerror", enabled by default
- Move TLS config steps from INSTALL to MESSAGE.tls
2017-08-13 23:42:55 +00:00