I have an odd behaviour. If I have mail.user set as a session property, I should be able to call setFrom() with no arguments and send mail.
However if I do that I have an odd behaviour: I can't send mail To: another user in the same domain as mail.user. At least that seems to be the distinguishing feature.
However if I call MimeMessage.setFrom(new InternetAddress(session.getProperties().get("mail.user"))), it works.
There are no SMTP errors or exceptions in either case, it's just that the To: doesn't get through. However cc:s to users in other domains do get through in either case.
This seems pretty odd, as I am only doing in longhand what I would have thought setFrom() (no args) does anyway.
This could be a peculiarity of the SMTP server, which is "smtpout.secureserver.net:3535", plaintext. I don't know anything about it technically.
I can provide some userids and authentications offline if that will help, and I can post some code here, but it is basically exactly the same as per the example
here modulo how the from-address gets set, and providing a proper Authenticator.