SmtpServerProxy Property
Provides access to the settings which allow MailBee to connect to a mail server via a proxy server.

Namespace: MailBee.SmtpMail
Assembly: MailBee.NET (in MailBee.NET.dll) Version: 12.2.0 build 630 for .NET 4.5
public ProxyServer Proxy { get; }

Property Value

Type: ProxyServer
A reference to the proxy server settings.
By default, proxy server is not used. The developer can change this to make MailBee use SOCKS4, SOCKS5, or HTTP proxy server. This is useful when a firewall prohibits direct connections with a mail server but permits connections via a proxy.
This console sample establishes connection with the mail server via an HTTP proxy server which requires clients to authenticate themselves.
using System;
using MailBee;
using MailBee.SmtpMail;
using MailBee.Proxy;

class Sample
    static void Main(string[] args)
        Smtp mailer = new Smtp();
        SmtpServer server = new SmtpServer("");
        server.Proxy.Name = "";
        server.Proxy.Protocol = ProxyProtocol.Http;
        server.Proxy.Port = 808;
        server.Proxy.AccountName = "jdoe";
        server.Proxy.Password = "secret";
        Console.WriteLine("Connected via a proxy server");
See Also