[H-GEN] Email "from"

Bruce Campbell bc at thehub.com.au
Tue May 11 02:01:33 EDT 1999


(Note reply-to: being general at humbug.org.au vs Bruce Campbell <bc at thehub.com.au>)

On Tue, 11 May 1999, Martin Pool wrote:

> Date: Tue, 11 May 1999 13:17:15 +1000
> From: Martin Pool <martinp at mincom.com>
> Reply-To: general at lists.humbug.org.au
> To: general at lists.humbug.org.au
> Cc: general at humbug.org.au

Harumph.  Must fix that.

> Luke Grant wrote:
> > i currently have the email being sent in the following format.
> > >open(STDIN, "thesamemailfile");
> > >system("mail","-s","subject","recipient at host");
> > 
> > of course the reader recieves the email and the "from" line contains
> > apache at myhost.com
> 
> It's probably better to call sendmail(8) directly.  IIRC many varieties
> recognize a -f option to set the  From line (or just emit your own
> header), and if you make apache a trusted user you can use -bs IIRC to
> set the 'Sender' line.

Note that if you make apache a 'trusted' user, take care in your script to
ensure that it is not possible for someone elsewhere on the 'net to enter
an arbitary address when http://calling/your/script, otherwise its your
machine sending spam, with no easy way of proving whodunnit.  

If your client can edit the script, do make them sign a provisio that they
will not allow this behaviour, good programming practice, its their fault
if anything goes wrong, should allow for system oddities etc etc.

--==--
Bruce.

"My cgi script doesn't work, its your fault!"
"Who wrote it?
"I did."
"Then its your fault.  Debugging will be at standard rates."


--
This is list (humbug) general handled by majordomo at lists.humbug.org.au .
Postings only from subscribed addresses of lists general or general-post.



More information about the General mailing list