Connect. Communicate. Collaborate. Securely.

Home » Kerio User Forums » Kerio Connect » Kerio Sendmail Does Not Set Sender Address When Used on the Command Line (Kerio Sendmail Does Not Set Sender Address When Used on the Command Line)
  •  
ferthalangur

Messages: 3
Karma: 0
Send a private message to this user
Mac OS X Server 10.6.8 running Kerio 7.4.3 Build 7813

We have cron jobs and other legacy programs on the mail server that need to talk to something called /usr/sbin/sendmail.

After failing to successfully configure Mac's Postfix to accept those messages and then relay them to the Kerio server listening on localhost port 26, I decided to try using Kerio's sendmail instead of the Postfix sendmail.

Permissions on /usr/local/kerio and /usr/local/kerio/mailserver are set to 711, and /usr/sbin/sendmail is symlinked to /usr/local/kerio/mailserver/sendmail.

This works ... mostly. The only problem is that Kerio is not setting a From or a From: header in the message. The only header identifying who the message came from is Return-Path: <postmaster<_at_>mail.chs.harvard.edu> .

The program calling Kerio's sendmail is /usr/bin/mail which is hardcoded to call /usr/sbin/sendmail and it expects sendmail to set the From: header and the envelope sender.

Have others experienced this? Is there a workaround, other than writing a /usr/sbin/sendmail wrapper that does a getuid() and then calls /usr/local/kerio/mailserver/sendmail with either -r or -f and a sender address?

Thanks,

_rob_

  •  
Kedar

Messages: 1320
Karma: 48
Send a private message to this user
/usr/local/kerio/mailserver/sendmail -help


Personally I solved few days ago similar problem. Output of application is saved to temporary file and then is called sendmail with -r and -F, input is another file with defined custom headers, empty line and followed by content of temporary file. It looks complicated, there is probably better way, but it works perfectly. Smile

[Updated on: Thu, 22 November 2012 13:53]

  •  
ferthalangur

Messages: 3
Karma: 0
Send a private message to this user
Hi Radek,

Thanks for your reply. I guess I can write a sendmail wrapper script that will prep the mail message and call $kerio/sendmail ... and then direct stdout and stderr from cron to that script.

It occurs to me that writing a wrapper that does a getuid() would cause problems if the mail bounced or was replied to anyway -- we don't have Kerio users or Kerio aliases configured for each possible userid on the mail server, so we'd have to kludge the return address anyway.

Ah well ... If I come up with anything useful scriptwise, I'll post it.

_rob_
Previous Topic: carddav.db more than 2gb
Next Topic: webmail post IN message
Goto Forum:
  


Disclaimer:
Kerio discussion forums are intended for open communication between forum members and may contain information and material posted by members which may be useful in learning about Kerio products. The discussion forums are not intended to provide technical support for any specific product. Any information implied or expressed in the discussion forums is that of the posting member. Kerio is in no way responsible for the information posted in the forums, or its accuracy. Kerio employees may participate in the discussions, but their postings do not represent an offical position of the company on any issues raised or discussed. Kerio reserves the right to monitor and maintain the forums to promote free and accurate exchange of information.

Current Time: Tue Oct 17 13:44:01 CEST 2017

Total time taken to generate the page: 0.00429 seconds
.:: Contact :: Home ::.
Powered by: FUDforum 3.0.4.