473,795 Members | 2,892 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

changing From in email envelope

Mtr
Using the mail() function, I can easily change the From address that
appears in an email. But how do I change the From that gets sent in the
SMTP conversation, which results in the address that appears in the
envelope's Return-path: header? That value currently is the
account_name@ma chine_name, but I don't want to give away my Linux account
name with every single email.
Oct 1 '07 #1
7 3964
Hi,

Try adding the -f option to sendmail on unix:

mail('to@dest', 'Subject', 'Message',
"From: My Site <info@site>", '-finfo@site');

On Oct 1, 8:44 am, Mtr <M...@no.spamwr ote:
Using the mail() function, I can easily change the From address that
appears in an email. But how do I change the From that gets sent in the
SMTP conversation, which results in the address that appears in the
envelope's Return-path: header? That value currently is the
account_name@ma chine_name, but I don't want to give away my Linux account
name with every single email.

Oct 1 '07 #2
Mtr
On Mon, 01 Oct 2007 14:16:18 -0000, petersprc <pe*******@gmai l.comwrote:
>Hi,

Try adding the -f option to sendmail on unix:

mail('to@dest' , 'Subject', 'Message',
"From: My Site <info@site>", '-finfo@site');
That works just fine, even for Exim. Thank you, Peter.

But still, the first Received: line shows the account name as the
originating host. I've tried the -oMs option, but that fails. (I'll have to
contact the server admin to see about being a "trusted caller".)

However, is there a PHP way to override the HELO/EHLO hostname that calls
Exim (just as there was an Exim way to override what goes into the
envelope's From).?

>
On Oct 1, 8:44 am, Mtr <M...@no.spamwr ote:
>Using the mail() function, I can easily change the From address that
appears in an email. But how do I change the From that gets sent in the
SMTP conversation, which results in the address that appears in the
envelope's Return-path: header? That value currently is the
account_name@m achine_name, but I don't want to give away my Linux account
name with every single email.
Oct 1 '07 #3
Mtr wrote:
On Mon, 01 Oct 2007 14:16:18 -0000, petersprc <pe*******@gmai l.comwrote:
>Hi,

Try adding the -f option to sendmail on unix:

mail('to@dest' , 'Subject', 'Message',
"From: My Site <info@site>", '-finfo@site');

That works just fine, even for Exim. Thank you, Peter.

But still, the first Received: line shows the account name as the
originating host. I've tried the -oMs option, but that fails. (I'll have to
contact the server admin to see about being a "trusted caller".)

However, is there a PHP way to override the HELO/EHLO hostname that calls
Exim (just as there was an Exim way to override what goes into the
envelope's From).?
No. And you don't want to. Many MTA's will validate a server is who it
says it is via reverse domain lookup. And they will bounce (or just
delete) any mail from mismatched names.
--
=============== ===
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attgl obal.net
=============== ===
Oct 2 '07 #4
Mtr
On Mon, 01 Oct 2007 22:57:34 -0400, Jerry Stuckle <js*******@attg lobal.net>
wrote:
>However, is there a PHP way to override the HELO/EHLO hostname that calls
Exim (just as there was an Exim way to override what goes into the
envelope's From).?

No. And you don't want to. Many MTA's will validate a server is who it
says it is via reverse domain lookup.
Hardly true, the name given on HELO is not used much anymore. And it is
called rDNS, not reverse domain lookup.

You might be thinking of how a server will do a lookup on the domain that
is given in the FROM. That is different.

Some MUAs will give the name of any common Windows box in the HELO. We
won't expect a mail agent to lookup those :)
>And they will bounce (or just
delete) any mail from mismatched names.
Yes, I do. Because I don't want to give away my account name with every
email. Besides, I am calling Exim - I am not connecting via TCP socket, as
is obvious from my post. But thanks anyway.
Oct 2 '07 #5
Mtr wrote:
On Mon, 01 Oct 2007 22:57:34 -0400, Jerry Stuckle <js*******@attg lobal.net>
wrote:
>>However, is there a PHP way to override the HELO/EHLO hostname that calls
Exim (just as there was an Exim way to override what goes into the
envelope's From).?
No. And you don't want to. Many MTA's will validate a server is who it
says it is via reverse domain lookup.

Hardly true, the name given on HELO is not used much anymore. And it is
called rDNS, not reverse domain lookup.
Actually, quite incorrect. Many sites validate the HELO name - first
for syntax, then do a rdns lookup on it. MTA's on all of the Linux
sites I manage do it, as do many other people I know. You should check
the MTA newsgroups.

Also, it is called both rdns and reverse domain name lookup - and has
been for over 30 years.
You might be thinking of how a server will do a lookup on the domain that
is given in the FROM. That is different.
No, I'm not thinking of that at all.
Some MUAs will give the name of any common Windows box in the HELO. We
won't expect a mail agent to lookup those :)
I'm not talking about MUA's.
>And they will bounce (or just
delete) any mail from mismatched names.

Yes, I do. Because I don't want to give away my account name with every
email. Besides, I am calling Exim - I am not connecting via TCP socket, as
is obvious from my post. But thanks anyway.
You aren't giving away your account name. Exim is providing your
computer (host) name.

And it doesn't matter if you're calling Exim or not (yes, I use Exim on
all of the Linux systems I manage). This is a configuration parameter
in Exim, not a user-defined parameter. As it should be, according to
the RFC's.

I suggest you follow this up on the Exim mailing list. You'll be told
the same thing - for the same reasons.

--
=============== ===
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attgl obal.net
=============== ===
Oct 2 '07 #6
Mtr
On Tue, 02 Oct 2007 06:42:07 -0400, Jerry Stuckle <js*******@attg lobal.net>
wrote:
>Mtr wrote:
>On Mon, 01 Oct 2007 22:57:34 -0400, Jerry Stuckle <js*******@attg lobal.net>
wrote:
>>>However, is there a PHP way to override the HELO/EHLO hostname that calls
Exim (just as there was an Exim way to override what goes into the
envelope's From).?

No. And you don't want to. Many MTA's will validate a server is who it
says it is via reverse domain lookup.

Hardly true, the name given on HELO is not used much anymore. And it is
called rDNS, not reverse domain lookup.

Actually, quite incorrect. Many sites
that would be a small minority. Else you can post an SMTP conversation from
any well known host that shows email being rejected because of the HELO.
Try privacy-invading google, e.g.
><validate the HELO name - first
for syntax, then do a rdns lookup on it. MTA's on all of the Linux
sites I manage do it, as do many other people I know. You should check
the MTA newsgroups.

Also, it is called both rdns and reverse domain name lookup - and has
been for over 30 years.
I was just pulling your chain.
>
>You might be thinking of how a server will do a lookup on the domain that
is given in the FROM. That is different.

No, I'm not thinking of that at all.
>Some MUAs will give the name of any common Windows box in the HELO. We
won't expect a mail agent to lookup those :)

I'm not talking about MUA's.
no, the agent (MTA) doesn't evaluate what the MUA sends
>
>>And they will bounce (or just
delete) any mail from mismatched names.

Yes, I do. Because I don't want to give away my account name with every
email. Besides, I am calling Exim - I am not connecting via TCP socket, as
is obvious from my post. But thanks anyway.

You aren't giving away your account name.
Do you presume that I don't know what my account name is, and that I don't
see it in the Received: line? This is on shared hosting.
>Exim is providing your
computer (host) name.

And it doesn't matter if you're calling Exim or not
it does if I'm trying to clue you in that Exim is on the same machine as my
account. Try to pay attention.
>(yes, I use Exim on
all of the Linux systems I manage). This is a configuration parameter
in Exim, not a user-defined parameter. As it should be, according to
the RFC's.

I suggest you follow this up on the Exim mailing list. You'll be told
the same thing - for the same reasons.
Oct 2 '07 #7
Mtr wrote:
On Tue, 02 Oct 2007 06:42:07 -0400, Jerry Stuckle <js*******@attg lobal.net>
wrote:
>Mtr wrote:
>>On Mon, 01 Oct 2007 22:57:34 -0400, Jerry Stuckle <js*******@attg lobal.net>
wrote:

However, is there a PHP way to override the HELO/EHLO hostname that calls
Exim (just as there was an Exim way to override what goes into the
envelope' s From).?
>
No. And you don't want to. Many MTA's will validate a server is who it
says it is via reverse domain lookup.
Hardly true, the name given on HELO is not used much anymore. And it is
called rDNS, not reverse domain lookup.
Actually, quite incorrect. Many sites

that would be a small minority. Else you can post an SMTP conversation from
any well known host that shows email being rejected because of the HELO.
Try privacy-invading google, e.g.
Actually, it is a great number of sites. It's a first step in stopping
spam.
><validate the HELO name - first
for syntax, then do a rdns lookup on it. MTA's on all of the Linux
sites I manage do it, as do many other people I know. You should check
the MTA newsgroups.

Also, it is called both rdns and reverse domain name lookup - and has
been for over 30 years.

I was just pulling your chain.
>>You might be thinking of how a server will do a lookup on the domain that
is given in the FROM. That is different.
No, I'm not thinking of that at all.
>>Some MUAs will give the name of any common Windows box in the HELO. We
won't expect a mail agent to lookup those :)
I'm not talking about MUA's.

no, the agent (MTA) doesn't evaluate what the MUA sends
The MUA's (i.e. Outlook, Thunderbird) responsibility is to connect to
your MTA (i.e. sendmail, exim). It doesn't send HELO/EHLO messages;
rather it sends USER and PASS commands (if authentication is required).

The MTA's responsibility is to determine the destination email server
and connect to that server, using a HELO or EHLO command. And in that
command you must have a valid principal host domain name. See RFC 821
and RFC 1869.

MTA's are free to do whatever they wish when an invalid domain name is
sent. Many of them either reject the mail or drop it.

But that's fine. If you don't want your email to go through, it's not
my problem.
>>>And they will bounce (or just
delete) any mail from mismatched names.
Yes, I do. Because I don't want to give away my account name with every
email. Besides, I am calling Exim - I am not connecting via TCP socket, as
is obvious from my post. But thanks anyway.
You aren't giving away your account name.

Do you presume that I don't know what my account name is, and that I don't
see it in the Received: line? This is on shared hosting.
Is it your account name, or your domain name? If it's your account
name, then your shared hosting is set up wrong.

Why not get yourself a vps or dedicated server. Then you can set it up
the way you want.
>Exim is providing your
computer (host) name.

And it doesn't matter if you're calling Exim or not

it does if I'm trying to clue you in that Exim is on the same machine as my
account. Try to pay attention.
No, it makes no difference at all. Whether you're using the executable
interface to Exim or the socket interface is immaterial. Exim is
providing the computer (host) name, not you.

Try to understand plain English.
>(yes, I use Exim on
all of the Linux systems I manage). This is a configuration parameter
in Exim, not a user-defined parameter. As it should be, according to
the RFC's.

I suggest you follow this up on the Exim mailing list. You'll be told
the same thing - for the same reasons.

--
=============== ===
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attgl obal.net
=============== ===
Oct 2 '07 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
6915
by: Stephen Chell | last post by:
I'm using SAAJ 1.2 (from jwsdp-1.3) and JDK 1.4.2_03. I've written a client application that uses the SAAJ api to send a SOAP message to a servlet. The servlet successfully receives the message and returns a SOAP response containing a single element in the SOAP body. The client receives the response and writes its content to standard out via the SOAPMessage.writeTo() method. The response received looks correct: <SOAP-ENV:Envelope...
3
1841
by: mark.greenbank | last post by:
Hi, I'm writing a small script that generates email and I've noticed that: 1) one should add the 'To' and 'CC' headers to the email message 2) one needs to specify the recipients in the smtplib sendmail() method Can someone explain how these are related? Thanks,
0
1151
by: Markus Stehle | last post by:
Hi all! I need to create an soap envelope that will be sent to an external service using HTTP POST. I created the required classes which are serialized using XmlSerializer. The envelope should look like this: <Envelope xmlns="http://www.w3.org/2001/12/soap-envelope" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.w3.org/2001/12/soap-envelope soap-envelope.xsd">
3
1487
by: Munish | last post by:
hi there, I am a student and developing a new application using C#. I need advice on developing a control which flashs out emails to users as per settings during setup stage; I mean when they setup the task. I am not sure how I can achieve that. Please guide me to right path. Thanks in advance. Johan
2
5609
by: lprisr | last post by:
Hi, I have double byte characters in the content that I am returning using Web Services. However, the encoding in the xml file returned by Web Services is utf-8 and I am unable to read the content, not even by changing browser encoding setting to the appropriate one. I implemented SoapExtension (called EncodingExtension) to rewrite the xml to change the encoding="utf-8" to encoding="windows-1252" in BeforeDeserialize SoapMessage...
2
3089
by: groups2 | last post by:
This is a simplified example of an html email, including the header. It seems to render fine in most situations but for some people it is just code. (it seems to be happening with bellsouth addresses) Is there anything in this header that is not quite right that might be the cause ? X-Account-Key: account1 X-UIDL: e2f092b7266c262ad6b98fd41ac82173 X-Mozilla-Status: 0201 X-Mozilla-Status2: 00000000
2
1931
by: Slippy | last post by:
Hi, python newbie, struggling to learn here. I'm trying to write a simple program which posts messages to my google group (via email). I'm using smtplib, email and email.message to build and send a message, but all the header attributes are appearing in the message body, so my messages are arriving with loads of junk in the body, no subject line and only the skinniest of headers. I know I'm doing something wrong, but I don't know what... ...
0
3603
by: Patrick Brunmayr | last post by:
Hello I have a big Problem with validating a Soap Envelope. I have downloaded the xsd for a soap envelope from http://schemas.xmlsoap.org/soap/envelope/ The validation succeeds as lonng as i don't use elements in body with a xsi:type attribute! The Problem is that foo:person is an abstract type and foo:driver is dervived from it. So using a foo:person is not allowed until specifing
0
3062
by: broersen | last post by:
Hello, Does someone know how to create manually the header for an SOAP message, without having an WSDL? I also use an X509 certificate for connecting to the webservice. Can anyone help me to get on the right road. I have to talk to an old Java webservice, so that's why I don't have an WSDL. I'm sending it with HTTPWebRequest or HTTPSWebRequest with VB but I needed a header like this: Request:
0
9522
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10443
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10165
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10002
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9044
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5437
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4113
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3728
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2921
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.