Bug 220452 - cyrus mailer in sendmail-cf uses /usr/lib/cyrus-imapd/deliver instead of /usr/lib64/cyrus-imapd/deliver on x86_64
cyrus mailer in sendmail-cf uses /usr/lib/cyrus-imapd/deliver instead of /usr...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: sendmail (Show other bugs)
4.4
x86_64 Linux
medium Severity medium
: ---
: ---
Assigned To: Thomas Woerner
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-12-21 08:19 EST by Jan Lieskovsky
Modified: 2008-07-24 16:02 EDT (History)
0 users

See Also:
Fixed In Version: RHBA-2008-0762
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-07-24 16:02:38 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
Example perl mail sending script: Run via: perl send.pl (After adding valid name of file to attach) (354 bytes, application/x-perl)
2006-12-21 08:24 EST, Jan Lieskovsky
no flags Details
Patch fixing the lmtp socket path for cyrusv2 mailer (537 bytes, patch)
2006-12-27 09:41 EST, Tomas Janousek
no flags Details | Diff

  None (edit)
Description Jan Lieskovsky 2006-12-21 08:19:28 EST
Description of problem:
Attempt to send email via cyrus-imapd on x86_64 arch fails with this warning:

Dec 21 07:57:45 x86_64-4as sendmail[10639]: kBLCvjjN010636: Warning: program
/usr/lib/cyrus-imapd/deliver unsafe: No such file or directory
Dec 21 07:57:45 x86_64-4as sendmail[10639]: kBLCvjjN010636: SYSERR(root): Cannot
exec /usr/lib/cyrus-imapd/deliver: No such file or directory
Dec 21 07:57:45 x86_64-4as sendmail[10638]: kBLCvjjN010636: to=<testuser>,
delay=00:00:00, xdelay=00:00:00, mailer=cyrus, pri=172720, dsn=4.0.0,
stat=Operating system error



Version-Release number of selected component (if applicable):
cyrus-imapd-2.2.12-7.RHEL4.x86_64 and higher

How reproducible:
Always

Steps to Reproduce:
1. Set up cyrus-imapd: (/etc/cyrus.conf: 
#  lmtp         cmd="lmtpd" listen="lmtp" prefork=0
  lmtpunix      cmd="lmtpd" listen="/var/lib/imap/socket/lmtp" prefork=1
2. adduser testuser
3. passwd cyrus
4. service saslauthd restart
5. su cyrus
6. cyradm localhost   (after successfull login)
       localhost.localdomain> cm user.testuser
       localhost.localdomain> setquota user.testuser 10000000
       quota: 10000000
       localhost.localdomain> quit
7. service cyrus-imapd restart
8. edit the /etc/mail/sendmail.mc file: 
   + define(`confLOCAL_MAILER',`cyrus')
   + MAILER(cyrus)
   + MAILER(local)
9. service sendmail restart
10. install perl Mail::Sender module: 
    perl -MCPAN -e"install Mail::Sender" and run the default questions
11. try to send mail via:
    perl send.pl => 
    Mail sent OK.  but in the maillog (/var/log/maillog you can see 
    message like the following): (See Actual results:)

  
Actual results: (from /var/log/maillog)

Dec 21 08:13:07 x86_64-4as sendmail[10944]: kBLDD7rw010941: Warning: program
/usr/lib/cyrus-imapd/deliver unsafe: No such file or directory
Dec 21 08:13:07 x86_64-4as sendmail[10944]: kBLDD7rw010941: SYSERR(root): Cannot
exec /usr/lib/cyrus-imapd/deliver: No such file or directory
Dec 21 08:13:07 x86_64-4as sendmail[10943]: kBLDD7rw010941: to=<testuser>,
delay=00:00:00, xdelay=00:00:00, mailer=cyrus, pri=172720, dsn=4.0.0,
stat=Operating system error


Expected results:
Mail is successfully sent.

Additional info:

file /usr/lib/cyrus-imapd/deliver =>
/usr/lib/cyrus-imapd/deliver: cannot open (/usr/lib/cyrus-imapd/deliver)

file /usr/lib64/cyrus-imapd/deliver => (it would be enough to change the path
to */deliver binary):

/usr/lib64/cyrus-imapd/deliver: setuid ELF 64-bit LSB executable, AMD x86-64,
version 1 (SYSV), for GNU/Linux 2.4.0, dynamically linked (uses shared libs),
stripped

uname -i =>
x86_64
Comment 1 Jan Lieskovsky 2006-12-21 08:24:22 EST
Created attachment 144177 [details]
Example perl mail sending script: Run via: perl send.pl (After adding valid name of file to attach)
Comment 2 Tomas Janousek 2006-12-21 09:18:18 EST
The problem is that there is a static path to the deliver binary in
/usr/share/sendmail-cf/mailer/cyrus.m4. As I don't know how to do a conditional
in m4, reassigning to sendmail-cf.

(although I think cyrusv2 is the preferred mailer, as it speaks to cyrus through
an lmtp socket, whose location is platform independent)
Comment 3 Tomas Janousek 2006-12-27 09:41:08 EST
Created attachment 144401 [details]
Patch fixing the lmtp socket path for cyrusv2 mailer
Comment 4 Tomas Janousek 2006-12-27 09:42:49 EST
Oh yeah, and the path to the lmtp socket in cyrusv2.m4 is wrong too :).
Attached patch, hopefully someone will look at it.
(note this does _not_ fix the bug in question)
Comment 5 Tomas Janousek 2007-06-07 09:11:59 EDT
The sendmail.mc in newer Fedoras contains the following comment, making the
modification of sendmail-cf unnecessary:

dnl # For using Cyrus-IMAPd as POP3/IMAP server through LMTP delivery uncomment
dnl # the following 2 definitions and activate below in the MAILER section the
dnl # cyrusv2 mailer.
dnl #
dnl define(`confLOCAL_MAILER', `cyrusv2')dnl
dnl define(`CYRUSV2_MAILER_ARGS', `FILE /var/lib/imap/socket/lmtp')dnl

We can probably solve this bug by adding similar comment about the cyrus mailer.

(But I will probably move the deliver binary to /usr/libexec someday)
Comment 7 RHEL Product and Program Management 2007-11-28 23:22:41 EST
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.
Comment 12 errata-xmlrpc 2008-07-24 16:02:38 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2008-0762.html

Note You need to log in before you can comment on or make changes to this bug.