Two Laptop Bag*
The moose likes EJB and other Java EE Technologies and the fly likes Restricting mails to a particular domain  Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Restricting mails to a particular domain  " Watch "Restricting mails to a particular domain  " New topic
Author

Restricting mails to a particular domain

Pradeep Kumar T
Greenhorn

Joined: Apr 14, 2007
Posts: 12
Hello,

I am using JavaMail API and have a small requirement. I have to restrict my outgoing mails to only to a particular domain. I mean the mails that i send should go successfully only if the domain is "abc@mycompany.com..Even if the users of my application types someother domain like yahoo.com or anything else, the mails shouldn't go. I want to restrict the users to send mails to only our company domain. Is that possible, any method available to set it so?

Please help.

Thanks in advance.

Pradeep
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41146
    
  45
It sounds like a simple test of whether the email address ends with "@mycompany.com" should suffice, no?


Ping & DNS - my free Android networking tools app
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Restricting mails to a particular domain
 
Similar Threads
Is the "From" Email Address Necessary?
Java Mail, diff. domain
James server issue...
Get Email Address
Connecting to SMTP server with user name and password