This week's book giveaway is in the Cloud/Virtualization forum.
We're giving away four copies of Learning OpenStack Networking: Build a solid foundation in virtual networking technologies for OpenStack-based clouds and have James Denton on-line!
See this thread for details.
Win a copy of Learning OpenStack Networking: Build a solid foundation in virtual networking technologies for OpenStack-based clouds this week in the Cloud/Virtualization forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Knute Snortum
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Ganesh Patekar
  • Stephan van Hulst
  • Pete Letkeman
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Ron McLeod
  • Vijitha Kumara

Sending mails from same domain  RSS feed

 
Ranch Hand
Posts: 279
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using Java mail API to send emails. I have installed SMTP server on my system.
So in Java class, I am setting the property "mail.smtp.host" as "127.0..0.1".

The email id to which I am sending emails is "abc@tes.com". In the "from" field the email id being set is "user@gmail.com". The emails are send perfectly fine.
to="abc@tes.com"
from= "user@gmail.com"

Now I changed the from email address to "user@tes.com" (the domain for "to" and "from" is the same). Now the emails have stopped going. In other words, whenever I change the domain of "from" address to be different from the domain of "to" address the emails go fine. As soon as I give the same domain ("tes" in this case) for both "to" and "from" email address the emails stop going. Can someone please let me know why this problem? Is this a SMTP restriction or Java mail restriction?

Thank you
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!