Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
dosper7 authored Jul 24, 2024
1 parent 0e641be commit a49d453
Showing 1 changed file with 130 additions and 103 deletions.
233 changes: 130 additions & 103 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,103 +1,130 @@
# What is SmtpServer?

[![NuGet](https://img.shields.io/nuget/v/SmtpServer.svg)](https://www.nuget.org/packages/SmtpServer/)

SmtpServer is a simple, but highly functional SMTP server implementation. Written entirely in C# it takes full advantage of the .NET TPL to achieve maximum performance.

SmtpServer is available via [NuGet](https://www.nuget.org/packages/SmtpServer/)

# What does it support?
SmtpServer currently supports the following ESMTP extensions:
* STARTTLS
* SIZE
* PIPELINING
* 8BITMIME
* AUTH PLAIN LOGIN

# How can it be used?

At its most basic, it only takes a few lines of code for the server to be listening to incoming requests.

```cs
var options = new SmtpServerOptionsBuilder()
.ServerName("localhost")
.Port(25, 587)
.Build();

var smtpServer = new SmtpServer.SmtpServer(options);
await smtpServer.StartAsync(CancellationToken.None);
```

# What hooks are provided?
There are three hooks that can be implemented; IMessageStore, IMailboxFilter, and IUserAuthenticator.
```cs
var options = new SmtpServerOptionsBuilder()
.ServerName("localhost")
.Port(25, 587)
.Port(465, isSecure: true)
.Certificate(CreateX509Certificate2())
.MessageStore(new SampleMessageStore())
.MailboxFilter(new SampleMailboxFilter())
.UserAuthenticator(new SampleUserAuthenticator())
.Build();

var smtpServer = new SmtpServer.SmtpServer(options);
await smtpServer.StartAsync(CancellationToken.None);
```

```cs
public class SampleMessageStore : MessageStore
{
public override Task<SmtpResponse> SaveAsync(ISessionContext context, IMessageTransaction transaction, CancellationToken cancellationToken)
{
var textMessage = (ITextMessage)transaction.Message;

var message = MimeKit.MimeMessage.Load(textMessage.Content);
Console.WriteLine(message.TextBody);

return Task.FromResult(SmtpResponse.Ok);
}
}
```

```cs
public class SampleMailboxFilter : IMailboxFilter, IMailboxFilterFactory
{
public Task<MailboxFilterResult> CanAcceptFromAsync(ISessionContext context, IMailbox @from, int size = 0, CancellationToken token)
{
if (String.Equals(@from.Host, "test.com"))
{
return Task.FromResult(MailboxFilterResult.Yes);
}

return Task.FromResult(MailboxFilterResult.NoPermanently);
}

public Task<MailboxFilterResult> CanDeliverToAsync(ISessionContext context, IMailbox to, IMailbox @from, CancellationToken token)
{
return Task.FromResult(MailboxFilterResult.Yes);
}

public IMailboxFilter CreateInstance(ISessionContext context)
{
return new SampleMailboxFilter();
}
}
```

```cs
public class SampleUserAuthenticator : IUserAuthenticator, IUserAuthenticatorFactory
{
public Task<bool> AuthenticateAsync(ISessionContext context, string user, string password, CancellationToken token)
{
Console.WriteLine("User={0} Password={1}", user, password);

return Task.FromResult(user.Length > 4);
}

public IUserAuthenticator CreateInstance(ISessionContext context)
{
return new SampleUserAuthenticator();
}
}
```
# David Pereira

### Tech Lead | .NET Champion | Distributed Systems | MCP

Lisbon Metropolitan Area
Email: djcostapereira@gmail.com
LinkedIn: [www.linkedin.com/in/djpereira](https://www.linkedin.com/in/djpereira)

## Summary

- Over 10 years of experience in software engineering.
- Passion for leading and nurturing teams in the .NET and distributed systems (microservices) landscape.
- Leverages technical skills and credentials to design and implement scalable and reliable solutions for complex business problems using cutting-edge technologies and architectures.
- Believes in creating a learning environment where knowledge sharing and continuous growth are part of the culture.
- Actively engages in code reviews, mentoring, and hiring to ensure the quality and performance of software products and services.
- Values simplicity and collaboration in finding the best solutions for clients and stakeholders.
- Enjoys playing soccer, exploring blockchain, or watching a movie in spare time.
- Privileged with a supportive family: amazing wife, wonderful daughter, and two incredible siblings (younger sister and older brother).

## Experience

### Teya
**Senior Software Engineer & .NET Champion**
**Location:** Lisbon, Portugal
**Duration:** September 2022 - Present

At Teya, I have been instrumental in building and maintaining microservices from scratch to provide acquiring host services to other teams. I led the design of several microservices for the host enablement team using vertical slice architecture. My responsibilities encompassed mentoring colleagues in C# and distributed systems, and advising other teams on the best approaches to consume and ingest our services. The software I developed was critical in handling communications with acquiring hosts, enabling integration of ISO messages with card schemes like VISA and Mastercard.

Key Responsibilities:
- Designing, optimizing, refactoring and maintaining services.
- Mentoring colleagues in C# and distributed systems.
- Advising other teams on best approaches to consume and ingest services.
- Designing and maintaining background validation workers.
- Refactoring old services to a vertical sliced design.
- Adding instrumentation and metrics to monitor business and services health.

Technologies: .NET C#, Kafka, Docker, Docker-compose, Kubernetes, PostgreSQL, AWS, Redis, OpenTelemetry, Grafana, Prometheus.

### Truphone
**Tech Lead**
**Location:** Lisbon, Portugal
**Duration:** November 2021 - September 2022

As the Tech Lead for the Ordering Team, I drove the technical strategy and implementation for our ordering systems, leveraging distributed and event-driven architectures. My responsibilities included defining technical solutions within the ordering scope, focusing on distributed and event-driven systems. I identified and resolved microservices performance bottlenecks, including memory and CPU tuning, optimizing database queries and schemas, and enhancing the asynchronous programming model.

Key Responsibilities:
- Defining technical solutions within the ordering scope.
- Identifying and resolving microservices performance bottlenecks.
- Optimizing database queries and schemas.
- Enhancing the asynchronous programming model.
- Leading code reviews to ensure code quality.
- Mentoring and guiding team members.

Technologies: .NET C#, RabbitMQ, Docker, Kubernetes, PostgreSQL, MongoDB, AWS, Golang, React.js, GitLab, OpenTelemetry, Grafana, Prometheus.

### Van Ameyde Group
**Technical Architect .NET**
**Location:** Lisbon, Portugal
**Duration:** January 2019 - October 2021

As a team Tech Lead, I served as the first point of contact for any technical questions presented to the team, shielding it from any undue noise and allowing them to execute and deliver on their projects. I was responsible for ensuring that the team adhered to the broader organization's technical direction, processes, and architecture. I represented the team in roadmap and strategy discussions with the rest of the organization.

Key Responsibilities:
- Defining and implementing technical solutions within the insurance domain.
- Designing new features, considering both technical and business perspectives.
- Ensuring adherence to technical direction, processes, and architecture.
- Leading code reviews to ensure high standards of code quality.
- Developing and maintaining systems using clean code principles and vertical slice architecture.
- Co-leading the design of microservices and managing the migration from monolithic systems.

Technologies: React.js, .NET Core C# / Web API / JSON / SignalR / JIRA / GIT / VS Code / Visual Studio / SQL Server / RabbitMQ / Docker / HangFire / gRPC / Clean Architecture / Blazor / Azure DevOps for CI/CD / AWS.

### Ageas Portugal
**Senior Software Developer**
**Location:** Oeiras, TagusPark
**Duration:** March 2016 - January 2019

At Ageas, I developed and maintained backend services (WCF, Web API, ASP.NET MVC) and frontend (Knockout.js and React.js libraries) using clean architecture design pattern. I was involved in migrating web services tech stack from ASMX to WCF (SOAP and REST) and provided production issues support and resolution.

Key Responsibilities:
- Developing and maintaining backend and frontend services.
- Migrating web services tech stack from ASMX to WCF (SOAP and REST).
- Providing production issues support and resolution.

Technologies: React.js, JQuery, Knockout.js, ASP.NET MVC, C# / Web API / JSON / WCF / T-SQL / JIRA / SignalR / Service-now.

### KPMG Portugal
**Full-stack .NET Developer**
**Location:** Lisbon Area, Portugal
**Duration:** July 2012 - March 2016

In the Ageas project (Insurance portals - Ocidental and Médis), I worked on the business application layer architecture, frontend components, and testing methodology using the ASP.NET tech stack. My role also included mentoring junior developers.

Key Responsibilities:
- Working on business application layer architecture and frontend components.
- Implementing testing methodology.
- Mentoring junior developers.

Technologies: SCRUM, ASP.NET 3.5/4.0/4.5 C# (WebForms, MVC, Web API), SQL Server, Javascript, JQuery, Knockout.js, TFS, WebServices, JSON, AJAX, Selenium.

### Indra
**Junior Fullstack .NET Software Engineer**
**Location:** Portugal
**Duration:** August 2010 - July 2012

At Indra, I worked on several projects, showcasing my versatility and capability in handling diverse technical challenges. In the SIT-e project for Portugal Telecom, I was responsible for corrective and evolutive maintenance of the SIT-e platform, utilizing technologies like MDA, SCRUM, and ASP.NET (WebForms and MVC) with C#. I also contributed to the Time Management project for Media Capital, where I designed and developed applications using ASP.NET 4.0, Entity Framework, and SQL Server, hosted on Windows Azure.

Key Responsibilities:
- Corrective and evolutive maintenance of the SIT-e platform.
- Designing and developing applications for the Time Management project.
- Focusing on data migration and developing user features for the NextWay project.
- Developing the NSOM by Indra Proxy/Gateway and migrating services for the new PT Order Management system.

Technologies: ASP.NET (WebForms and MVC), C#, SQL Server, Javascript, JQuery, Hudson (continuous Integration), Tortoise SVN, Entity Framework, Windows Azure, WebServices (AXIS2), XML, XSD, Ant scripts.

## Certifications and Courses

- .NET Memory Expert by Dotnetos
- Solution Architecture by Dometrain
- Distributed Systems Design Fundamentals by Particular Software
- MCSD: App Builder by Microsoft
- MCSA: Web Applications by Microsoft
- MCPS: Microsoft Certified Professional: ASP.NET MVC Web Applications by Microsoft
- Microsoft Certified Professional by Microsoft
- Design Patterns in C# and .NET by Udemy
- Fundamentals of Database Engineering by Udemy
- High Performance Coding with .NET Core and C# by Udemy
- Master the Coding Interview: Data Structures + Algorithms by Udemy
- Mastering the System Design Interview by Udemy
- Vue - The Complete Guide by Udemy

0 comments on commit a49d453

Please sign in to comment.