Back to product page

Security Property


Determines if SSL is used.

Type

A SmtpSecurityEnum enumeration.

Syntax

  • Basic
object.Security [= value]
The Security(object,value) syntax has these parts:
objectAn expression evaluating to an object of type wodSmtp
valueA SmtpSecurityEnum enumeration.

Remarks

This property defines if wodSmtp will require SSL encryption to be used when it tries to deliver the message. You should set it to one of constants defined in SmtpSecurityEnum. It defaults to SecurityNone since most mail servers don't require SSL encryption.

When set to SecurityAllowed, then wodSmtp will try to negotiate SSL using STARTTLS command, but will not require SSL for posting a message.

If SecurityRequired is chosen, wodSmtp not deliver the message unless STARTTLS command succeeds.

If SecurityImplicit is chosen, wodSmtp will negotiate SSL connection even before any (SMTP specific) data is sent through the socket. Usually, server should be running on port 465 when this type is selected.

If your server requires client-side authentication with a certificate, make sure Certificate property is set.

Note: changing this property will also affect Port property. If you set Security = SecurityImplicit, wodSmtp will set Port = 465. Otherwise, it will set Port = 25.

Platforms

Windows