# Action Mailer : FROM ADDRESS

**URL:** <https://www.ruby-forum.com/t/action-mailer-from-address/146780>\
**Category:** Rails\
**Created:** [August 25, 2008, 12:55pm UTC](https://www.ruby-forum.com/t/action-mailer-from-address/146780 "2008-08-25T12:55:14Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![sgudibanda](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/a9adbd/32.png) [@sgudibanda](https://www.ruby-forum.com/u/sgudibanda)\
**Post date:** [August 25, 2008, 12:55pm UTC](https://www.ruby-forum.com/t/action-mailer-from-address/146780/1 "2008-08-25T12:55:14Z")

</div>

Hi,

I have been using action mailer with little or no issues for quite a  
while. I have been sending all mails as admin. Now that i thought of  
using user’s email IDs itself when they communicate with each other  
instead of sending it via admin.

The action mailer messages /output do indicate that Mail from is :  
removed\_email\_address@domain.invalid

“235 2.7.0 Accepted\r\n”  
“MAIL FROM:[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)\r\n”  
“250 2.1.0 OK\r\n”  
“RCPT TO:[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)\r\n”  
“250 2.1.5 OK\r\n”  
“DATA\r\n”  
“354 Go ahead\r\n”

But the mail received by removed\_email\_address@domain.invalid still says, removed\_email\_address@domain.invalid.

1. How to solve this issue?

2. Is it legal to even use user’s email id in such communications. If at  
all if I or someone gets this working, essentially mail can be sent to  
anyone with anyone’s email id! Is this legal?

Regards,  
SG

---

<div class="post-metadata">

**Author:** ![sgudibanda](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/a9adbd/32.png) [@sgudibanda](https://www.ruby-forum.com/u/sgudibanda)\
**Post date:** [August 25, 2008, 1:53pm UTC](https://www.ruby-forum.com/t/action-mailer-from-address/146780/2 "2008-08-25T13:53:59Z")

</div>

On Aug 25, 11:55 am, Sandeep G. \<rails-mailing-l…@andreas-  
[s.net](http://s.net)\> wrote:

> But the mail received by removed\_email\_address@domain.invalid still says, removed\_email\_address@domain.invalid.
> 
> 1. How to solve this issue?
> 
> 2. Is it legal to even use user’s email id in such communications. If at  
> all if I or someone gets this working, essentially mail can be sent to  
> anyone with anyone’s email id! Is this legal?

Yup, from addresses can easily be spoofed. That’s why you often get  
spam with bogus from addresses. Some mails servers force the from  
address to be the one associated with the account, precisely to reduce  
this sort of problem.

Fred
