I send an email from my smtp server, for example, setting From
to [email protected]. The recipient will think that email comes from anydomain
. How to confirm the email source?
There are several approaches to dealing with email forgery:
Received
headers (although this isn't reliable)The main thing to realise is that the From: address isn't any form of guarantee about the originator of a message.
Edit: okay I now understand that you're just trying to tag the mail message somehow so that you can recognise which server generated it (in a non-secure way). Here's how using .NET's MailMessage:
System.Net.Mail.MailMessage msg = new System.Net.Mail.MailMessage();
msg.Headers.Add("X-Is-Development", "true");
Email Headers has more details.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With