I don't know why but sending e-mails through the javax.mail-package fails.
It's strange that sending mails to local recipients works fine (according to
the error message below):
server: mail.foo.com
recipient: x...@foo.com works fine
recipient x...@xyz.com doesn't work...
Error Message
***********
2002-04-21 16:46:22,126 ERROR [HttpProcessor[8080][4]]
ee.core.utils.CoreLogger -
javax.mail.SendFailedException: Sending failed;
nested exception is:
javax.mail.SendFailedException: Invalid Addresses;
nested exception is:
javax.mail.SendFailedException: 550 not local host freesurf.ch, not a
gateway
at javax.mail.Transport.send0(Transport.java:218)
at javax.mail.Transport.send(Transport.java:80)
at
com.datenreich.j2ee.core.utils.MailComponent.send(MailComponent.java:296)
It can't be the problem of my mail server because I'm using the same server
to send mails through normal e-mail clients. Any suggestions?
Thank you very much
Philipp
That doesn't mean it's not a problem with talking to the mail server.
o Are you on the same machine as the normal e-mail clients? Many mail
servers will only relay from local machines, IIRC
o The mail server may only allow outgoing mail if you've recently logged
in for incoming mail. I've certainly seen that before now.
--
Jon Skeet - <sk...@pobox.com>
http://www.pobox.com/~skeet/
If replying to the group, please do not mail me too
"I bent my wookie" - Ralph Wiggum
Thanks for the immediate reply. As it's also not working if running on the
server, I'll contact my ISP first (I think it sould be allowed for the
server itself...).
Thanks for your advice :-)
Philipp
"Joe" <yoha...@nospam.space.com> schrieb im Newsbeitrag
news:MPG.173078c42...@news.bellglobal.com...
transport = session.getTransport();
transport.connect( mail.host, username, password );
Thanks for your advice. The problem was that the server didn't look where
the email came from but who the sender was (regarding the email-address). It
failed because I didn't explicitely set the senders address but generated
one (feedback...@www.foo.com). The problem was the "www." as the
server accepts just emails coming from any...@foo.com.
Thanks for your suggestions :-)
Philipp
"Joe" <yoha...@nospam.space.com> schrieb im Newsbeitrag
news:MPG.1730e1f6a...@news.bellglobal.com...