<PackageReference Include="System.Security.Permissions" Version="9.0.0-preview.4.24266.19" />

SmtpAccess

public enum SmtpAccess
Specifies the level of access allowed to a Simple Mail Transport Protocol (SMTP) server.
Connect = 1

Connection to an SMTP host on the default port (port 25).

Connection to an SMTP host on any port.

None = 0

No access to an SMTP host.