Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Rewriting a From Address in Sendmail V8

Posted on 2000-03-14
3
Medium Priority
?
444 Views
Last Modified: 2010-04-21
How can I get sendmail to rewrite the from address.  As an example I have a  mail message going out with a from address of:
louis@life.com

I would like sendmail to rewrite the from address to bill@life.com.

No a replay to will not work.  The address is really an aliases to a list of people.   Maybe if there is a way to change the to address in to a bcc address and then create a replay to address that is the one I want???

Thanks,
Louis
0
Comment
Question by:brownjohn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 40

Expert Comment

by:jlevie
ID: 2616935
You could do it with a custom sendmail rule if the person part was always the same, but that's kind of a lot of work.

How about changing the alias to point to, say a perl script that reads the message, and remails it to the real alias list with what you want as the From: address? That's pretty simple and straight-forward (and I think I've got a perl script around somewhere that that does something awfully close to that)
0
 
LVL 1

Expert Comment

by:sereda
ID: 2620037
Hmm...

Will not
  sendmail -f from@address
do the trick?

Or do i miss something?

0
 
LVL 2

Accepted Solution

by:
mapc earned 600 total points
ID: 2620586
This could be accomplished by the USERDB
feature.
First, sendmail must be compiled with USERDB, this can be checked with sendmail -adda or some other bogus debug flag which will show the  compiled in modules.
If it's not, then you must recompile it.
Then, you use feature(`USERDB')dnl in the .m4 config file, and create a database which consists of:
user <space> mailname: anotheruser
Simple as that.
The sendmail 9.10.0 states that LDAP could be used for *any* database which is used in it, so I haven't verified it, but it should be possible with sendmail 9.10.0 to use LDAP database instead of USERDB which is in DB2 format.
Another use for USERDB is creating entries like:
user<space> maildrop: anotheruser@anotherhost
which accomplishes something similar to aliases/forwarding..
Other way to accomplish what you want is to write manual rule for sender address.
It should have F and 'i' and '@' if I'm not mistaken, but this sort of information should be checked in the book.
Hope that it helps.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In tuning file systems on the Solaris Operating System, changing some parameters of a file system usually destroys the data on it. For instance, changing the cache segment block size in the volume of a T3 requires that you delete the existing volu…
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.
Suggested Courses

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question