Bug 588165

Summary: sendmail should install sendmail-milter as a requirement
Product: Red Hat Enterprise Linux 6 Reporter: Uwe Beck <ubeck>
Component: sendmailAssignee: Jaroslav Škarvada <jskarvad>
Status: CLOSED WONTFIX QA Contact: qe-baseos-daemons
Severity: medium Docs Contact:
Priority: low    
Version: 6.0CC: jskarvad
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-05-26 07:46:32 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Uwe Beck 2010-05-02 22:53:55 UTC
Description of problem:

sendmail was build with MILTER API. sendmail-8.14.3-10.el6 rpm does not contain libmilter. You need sendmail-milter which is not on DVD. It is on optional repository.

On DVD there are:
- sendmail
- sendmail.cf
At optional repository are:
- sendmail-doc
- sendmail-devel
- sendmail-milter

# sendmail -d0 < /dev/null
Version 8.14.3
 Compiled with: DNSMAP HESIOD HES_GETMAILHOST LDAPMAP LOG MAP_REGEX
                MATCHGECOS MILTER MIME7TO8 MIME8TO7 NAMED_BIND NETINET NETINET6
                NETUNIX NEWDB NIS PIPELINING SASLv2 SCANF SOCKETMAP STARTTLS
                TCPWRAPPERS USERDB USE_LDAP_INIT
#

You can see that sendmail was build with MILTER API. If you want use MILTER you get "missing libmilter.so". libmilter is not part of sendmail rpm.

You must also install sendmail-milter to be able to use MILTER API.

This is a mismatch between output from sendmail and the sendmail binary.

Version-Release number of selected component (if applicable):

sendmail-8.14.3-10.el6.src.rpm

Resolution for this problem:

I do not know why libmilter is now at his own sendmail-milter rpm.

Fix at SPEC file:

Name: sendmail
...
Requires: sendmail-milter = %{version}-%{release}

Rebuild sendmail and move sendmail-milter rpm from optional repository to DVD.

Comment 2 RHEL Program Management 2010-05-02 23:53:57 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
inclusion.

Comment 3 Jaroslav Škarvada 2010-05-03 15:15:09 UTC
What do you use as a milter? The idea here is that a milter (filtering application) should install sendmail-milter as dependency. Also if you would like to use milter API on your own, the sendmail-devel installs the sendmail-milter for you. AFAIK there is no supported milter (filtering application) in the RHEL-6 repo, thus the sendmail-milter lands in optional repo. 

Also the idea of sub-packaging is that most of users don't need milter in basic installation. And the proposed explicit requires drops the advantage of sub-packaging. I am not aware of better way how to accomplish sendmail/milter sub-packaging.

Comment 4 Uwe Beck 2010-05-03 22:14:11 UTC
(In reply to comment #3)
> What do you use as a milter?

clamav-milter, dkim-milter, spamass-milter, smf-sav

> The idea here is that a milter (filtering application) should install
> sendmail-milter as dependency.

At this time no milter rpm I know use sendmail-milter as dependency because libmilter is part of sendmail rpm while sendmail knows the MILTER API.

clamav-milter
Requires: clamd
Requires: sendmail

dkim-milter
Requires: sendmail

spamass-milter
Requires: sendmail
Requires: spamassassin

smf-sav
Requires: sendmail

> Also if you would like to use milter API on your own, the sendmail-devel
> installs the sendmail-milter for you.

Please make a difference between a system on which you build a milter rpm and a system you will install the binary rpm to use the milter. Only the system for build the rpm needs the sendmail-devel rpm.

The user see that your sendmail rpm was compiled with MILTER API (output from "sendmail -d0 < /dev/null"). This means for him that a milter can use the API. If there should not be so then the output should not contain MILTER.
But if you compile sendmail without MILTER option libmilter will not build.

At this time an upgrade to RHEL6 will work. But after the upgrade no milter will work because libmilter is not longer part of sendmail and libmilter is part of sendmail rpm while sendmail knows the MILTER API. Really a bad situation, because the RHEL6 sendmail rpm will not install the sendmail-milter rpm as a dependency for you.

> AFAIK there is no supported milter (filtering application) in the RHEL-6
> repo, thus the sendmail-milter lands in optional repo.

ok

> Also the idea of sub-packaging is that most of users don't need milter in
> basic installation.

Does this mean that Red Hat do not want to support sendmail MILTER API at RHEL6? It doesn't make sense.

I do not see the sub-package requirement for one library which provides a basic sendmail API.

If you which for future that milters should have:

Requries: sendmail-milter

than use:
Provides: sendmail-milter

at sendmail.spec file for the sendmail rpm and drop sendmail-milter rpm.

Comment 5 Jaroslav Škarvada 2010-05-04 10:42:28 UTC
> clamav-milter, dkim-milter, spamass-milter, smf-sav

It looks you use software from unsupported repo.

> At this time no milter rpm I know use sendmail-milter as dependency because
> libmilter is part of sendmail rpm while sendmail knows the MILTER API.

All milter packages from rawhide (origin of RHEL-6 packages) and all packages from derivative repos honour it as dependency. The dependency is satisfied by RPM auto-dependency:

$ repoquery ---disablerepo='*' --enablerepo=rawhide -whatprovides 'libmilter.so*'

sendmail-milter-0:8.14.4-4.fc14.x86_64
sendmail-milter-0:8.14.4-4.fc14.i686

$ repoquery --disablerepo='*' --enablerepo=rawhide --whatrequires 'libmilter.so*'
sendmail-devel-0:8.14.4-4.fc14.x86_64
sendmail-devel-0:8.14.4-4.fc14.i686
dkim-milter-0:2.8.3-7.fc14.x86_64
spamass-milter-0:0.3.1-19.fc14.x86_64
clamav-milter-0:0.96-1402.fc14.x86_64
milter-regex-0:1.7-6.fc12.x86_64
milter-greylist-0:4.2.4-1400.fc14.x86_64
mimedefang-0:2.68-1.fc14.x86_64

> The user see that your sendmail rpm was compiled with MILTER API (output from
> "sendmail -d0 < /dev/null"). This means for him that a milter can use the API.
> If there should not be so then the output should not contain MILTER.
> But if you compile sendmail without MILTER option libmilter will not build.
Yes, it is not optimal, but I am not aware of better way, how to do the modularization. Also the sendmail-milter is there for a long time thus more complex changes would be painfull.

> At this time an upgrade to RHEL6 will work. But after the upgrade no milter
> will work because libmilter is not longer part of sendmail and libmilter is
> part of sendmail rpm while sendmail knows the MILTER API. Really a bad
> situation, because the RHEL6 sendmail rpm will not install the sendmail-milter
> rpm as a dependency for you.
Upgrade is not officially supported. The only official way is reinstall. Also no milter (filtering application) is shipped with RHEL-6, thus you are here on your own.

> Does this mean that Red Hat do not want to support sendmail MILTER API at
> RHEL6? It doesn't make sense.
I didn't write so. That's why there is the sendmail-milter in the optional repo. If you need a milter you can try compatible (unsupported) repo and the sendmail-milter will be installed as auto-dependency. And in all other cases you can always install sendmail-milter manually. 

> I do not see the sub-package requirement for one library which provides a
> basic sendmail API.
The sendmail-milter exists for a long time (according to changelog this change was done in 2001) - I am not aware of details. Also the explicit "requires" would render the sendmail-milter modularization useless, but it could be done. If this is critical for you, please contact http://redhat.com/support

Comment 6 Uwe Beck 2010-05-06 11:59:39 UTC
(In reply to comment #5)
> It looks you use software from unsupported repo.

All rpms outside RHEL RHN channels are unsupported by Red Hat.

> If you need a milter you can try compatible (unsupported) repo and the
> sendmail-milter will be installed as auto-dependency. And in all other cases
> you can always install sendmail-milter manually. 

I know about the change for sendmail MILTER API at RHEL6 now. I can modify it on my used milters.

It would be good to have an information at RHEL6 release notes for this change.

Comment 7 Uwe Beck 2010-05-06 12:11:13 UTC
(In reply to comment #5)
> 
> It looks you use software from unsupported repo.

All rpms outside RHN channels are unsupported by Red Hat.

> If you need a milter you can try compatible (unsupported) repo and the
> sendmail-milter will be installed as auto-dependency. And in all other cases
> you can always install sendmail-milter manually. 

I know now about sendmail MILTER API change at RHEL6 and can modify SPEC files.

It would be good to have an information about this change at RHEL6 release notes.