What an SMTP port is
A mail server listens on several ports, and each one is meant for a type of connection. Some let servers pass email between themselves; others let an application, a plugin or an email client hand its messages to its sending server.
If your application sends through an SMTP service, the norm is port 587 with STARTTLS or 465 with implicit TLS. Port 25 is for server-to-server traffic and 2525 is a non-standard alternative that only some providers offer.
Short answer
Use 587 with STARTTLS or 465 with SSL/TLS, always with authentication. Don't use 25 to send from an application: it's for server-to-server traffic and many providers block it. 2525 only helps if your provider offers it.
