One thing to note is that Port 465, like 587 is the SMTP Submission
port, which will (or at least should) have you authenticate to the
server that you are allowed to use it to distribute messages. 587 is the
more standard port, and 465 is legacy support for TLS.
Port 25 is for SMTP transport, and a server should only accept messages
on that port that it is authorized to deliver mail to, it is for
INCOMING email.
Some systems have improperly accepted submission on port 25, but this
causes all sorts of issue to avoid becoming an open relay and being
marked as a spam source.