public MailServerService(IServiceProvider serviceProvider, MailServerConfiguration mailServerConfiguration, ILogger <MailServerService> logger)
        {
            this.serviceProvider         = serviceProvider;
            this.mailServerConfiguration = mailServerConfiguration;
            this.logger  = logger;
            this.options = new SmtpServerOptionsBuilder()
                           .ServerName(this.mailServerConfiguration.Domain)
                           .Port(25, false)
                           .CommandWaitTimeout(TimeSpan.FromSeconds(30))
                           .Build();

            this.messageStore = this.serviceProvider.Resolve <TempMessageStore>();
        }
 public MailboxService(
     MailServerConfiguration mailServerConfiguration,
     AsymmetricCryptoService asymmetricCryptoService,
     EmailCryptoService emailCryptoService,
     MailRepository mailRepository,
     IMessenger messenger,
     ILogger <MailboxService> logger)
 {
     this.mailServerConfiguration = mailServerConfiguration;
     this.asymmetricCryptoService = asymmetricCryptoService;
     this.emailCryptoService      = emailCryptoService;
     this.mailRepository          = mailRepository;
     this.messenger = messenger;
     this.logger    = logger;
 }
Beispiel #3
0
 public MailboxFilter(MailServerConfiguration mailServerConfiguration, ILogger <MailboxFilter> logger)
 {
     this.mailServerConfiguration = mailServerConfiguration;
     this.logger = logger;
 }