Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Replacing the contents the "To:" field

Status
Not open for further replies.

trabadam

Technical User
May 5, 2003
9
RU
The issue is as follows: Certain software sends E-mail which must then be forwarded to Email-to-SMS service. The software is buggy and refuses send the mail if the username part of the address begins with a number, so it sends the message to some_alias@our_gateway, with line "some_alias 123456789@our_mobile_provider" in /etc/mail/aliases (aliases.db reflects it :). But the contents of the "To:" field remains intact and the script at provider's side does not send the SMS.
I failed to figure out in all those tricks with message mangling (setting up userdatabase with j flag for the mailer does not replace the address in To: field), so answer, please:
is it possible to rewrite the To: field using Sendmail's own means?
(I don't like the idea of writing a script since I prefer keeping /usr/adm/sm.bin empty)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top