Message Boards Message Boards

0
|
3381 Views
|
1 Reply
|
0 Total Likes
View groups...
Share
Share this post:

SendMail - Without Authentication

Posted 9 years ago

I'm attempting to set up my Mathematica code so that it can email me the results of its calculation once it is finished. I decided to test a simple example of SendMail to make sure it was working.

In this case I'm using an internal mail relay on port 25 which does not require authentication.

My code is as follows.

SendMail[
 "To" -> "l.j@domain.com",
 "Subject" -> "Example Message",
 "Body" -> "My text",
 "From" -> "l.j@domain.com",
 "Server" -> "mailrelay.sub.domain.com",
 "UserName" -> "",
 "Password" -> None,
 "PortNumber" -> 25,
 "EncryptionProtocol" -> "SSL"]

and I get the error

SendMail::msgerr: An unexpected response was received during message transport. >>

I'm guessing that the unexpected response from the server is because it is attempting to send a username and password when it doesn't want one. Is there a way to tell mathematica not to send a username/password? Alternatively is there a way to dig into the error to pick up on the exact to and fro between mathematica and the mail server so that I can see exactly what it isn't expecting to receive?

Thanks, L

P.S. Not sure if this is just something in the code I'm missing or if I need to stick in the call to the service team but it would be good to get some community views on solutions.

POSTED BY: L J
Posted 9 years ago

I swapped to using the example outlined in my initial post on this question http://community.wolfram.com/groups/-/m/t/494598?p_p_auth=hlekduQ2

I found that changing my code to the below also provided the required effect.

SendMail[
 "To" -> "l.j@domain.com",
 "Subject" -> "Example Message",
 "Body" -> "My text",
 "From" -> "l.j@domain.com",
 "Server" -> "mailrelay.sub.domain.com",
 "UserName" -> "",
 "Password" -> "",
 "PortNumber" -> 25]
POSTED BY: L J
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract