Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 922477 - >=sys-process/cronie-1.7.0 breaks sending mails with many setups
Summary: >=sys-process/cronie-1.7.0 breaks sending mails with many setups
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL: https://forums.gentoo.org/viewtopic-p...
Whiteboard:
Keywords:
Depends on: 922480
Blocks:
  Show dependency tree
 
Reported: 2024-01-19 09:29 UTC by Hanno Böck
Modified: 2024-01-19 10:29 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hanno Böck gentoo-dev 2024-01-19 09:29:45 UTC
cronie 1.7.0 introduced an undocumented change that will break many mail setups.

By default, it will pass "-f '<>'" to sendmail in order to configure an empty envelope from. The motivation was to avoid autoresponders in response to cron mails.

This is a bug on multiple levels. Using "-f '<>'" for an empty envelope from header appears to work in postfix setups (though apparently not all of them), but according to my tests it does not work in courier and exim. (It likely also won't work on some other MTAs.) The effect is that cron mails won't be sent after an update to 1.7.0 or 1.7.1.

Also, empty envelope from headers (so-called "null reverse-path") are reserved for special mails, e.g. mail delivery notifications, and setting a null reverse-path for anything else is against RFC recommendations ( https://datatracker.ietf.org/doc/html/rfc5321#section-4.5.5 ).

Apparently, the upstream author got some feedback that this breaks, and reverted the change after the 1.7.0 release. But shortly after that, he changed it back again in a slightly different way with the same effect. So 1.7.1 is still broken.

Unfortunately, I reported this upstream, and upstream does not appear to be interested in fixing this: https://github.com/cronie-crond/cronie/issues/170

I am not sure how to best handle this from Gentoo's side. I am mainly reporting it here so other people facing the same problem can find this bug and an explanation.

I am personally now using an 1.7.1 ebuild with a patch to revert the bad commit: https://github.com/cronie-crond/cronie/commit/c640f4f39e5c20995e960e4b954cd0574a96c028
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-01-19 09:32:46 UTC
It's fine with me if you add a new revision with that revert. It's going to lead to a lot of confused people without it, I think.
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-01-19 10:26:10 UTC
Looks like upstream have decided to revert it themselves so I'll pull that in now.
Comment 3 Larry the Git Cow gentoo-dev 2024-01-19 10:28:45 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c8d03c5fd70d4e1f0696ed140203f2475869ea7b

commit c8d03c5fd70d4e1f0696ed140203f2475869ea7b
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2024-01-19 10:28:25 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-01-19 10:28:35 +0000

    sys-process/cronie: backport envelope revert
    
    Closes: https://bugs.gentoo.org/922477
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-process/cronie/cronie-1.7.1-r1.ebuild          | 111 +++++++++++++++++++++
 .../files/cronie-1.7.1-envelope-revert.patch       |  59 +++++++++++
 2 files changed, 170 insertions(+)