Skip to content

abkarada/Go-SMTP-Server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ“¬ Go SMTP Server

A lightweight and fully functional SMTP server built using the emersion/go-smtp library in Golang.
This server accepts incoming emails, logs sender, recipients, and message body, and is suitable for testing, local development, or building custom email processing logic.


πŸš€ Features

  • πŸ“₯ Accepts and logs MAIL FROM, RCPT TO, and DATA
  • πŸ”§ Clean implementation using Go interfaces
  • πŸ“‘ Listens on custom port (:1025)
  • πŸ” Supports optional plaintext authentication (for testing)
  • πŸ§ͺ Ideal for development/testing environments

🧱 Tech Stack


πŸ“ Project Structure

Go_Mail/ β”œβ”€β”€ main.go # Main application with SMTP server implementation β”œβ”€β”€ go.mod # Module declaration β”œβ”€β”€ go.sum # Dependency hash tracking


πŸ›  How to Run

  1. Make sure you have Go installed:
    https://go.dev/doc/install

  2. Clone the repository:

git clone https://github.com/yourusername/Go_Mail.git cd Go_Mail

3.Initialize Modul

go mod init go_mail go get github.com/emersion/go-smtp

4.Run the Server

go run main.go

By default, the server listens on: localhost:1025

About

Mail Server with GoLang

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages