That didn't work -- connect failed.
So then I tried patching the source to use the port and server I wanted. That, too, failed.
My next attempts were to change first the port and then the server. I found that changing either of them caused the connect to fail. The failure seems to be a timeout, since it hangs a while before the failure.
I've tried connecting from a different computer on the same network, and that works, so it doesn't appear to be a firewall problem (I'm using a Firewalla Gold as my firewall).
The system I'm working on is a nano 33 IOT.
Has anyone else seen this problem or been able to use EMailSender to a different smtp server/port?
Are you sure that the selected server accepts requests on port 25? No public mail server uses unencrypted ports these days. Try the same server but port 465
I was pretty sure that I had, but just tried it again. It fails.
Some more information:
I just looked at my firewall and it shows that 107 B were downloaded and 246 B were uploaded.t
So, it appears that data is being transferred, but the connection is never shown as established. (That's smtp.sendgrid.net port 25)
Running tcpdump on my firewall, I see that there is an apparent attempt to do what looks like what might be an SSL handshake at the beginning of the connection. I've tried doing:
emailSend.setIsSecure(false);
That doesn't seem to solve the problem.
I've tried connecting to a port that expects an encrypted connection, but that didn't work either.
Is anyone else using EMailSender on a nano 33 IOT?