基于Yggdrasil网络的真点对点电子邮件
True P2P Email on Top of Yggdrasil Network

原始链接: https://github.com/JB-SelfCompany/Tyr

## Tyr:安卓端真正的P2P电子邮件 Tyr是一款安卓应用程序,为您的设备带来真正的点对点(P2P)电子邮件,绕过传统的中心化服务器。它利用Yggdrasil网络,该网络提供免费的IPv6地址和强大的加密,消除了传统电子邮件系统中固有的监控和审查风险。 与典型的电子邮件客户端不同,Tyr不需要邮件服务器、加密层或端口转发。它在本地运行一个完整的电子邮件服务器(Yggmail),提供标准的SMTP/IMAP访问。您的电子邮件地址经过密码学保护,由唯一的Ed25519密钥派生,防止欺骗。 Tyr可以与DeltaChat和ArcaneChat等去中心化消息应用无缝集成,为现代聊天体验提供支持。设置过程简化,具有自动配置选项。 主要功能包括自动密钥生成、自动启动功能、加密备份以及强大的安全措施,例如Android Keystore集成和通过Yggdrasil进行网络加密。Tyr赋予用户电子邮件的自由和控制权,允许连接到各种Yggdrasil节点,甚至构建私有网络。它采用开源模式,优先考虑隐私和安全。

Hacker News 新闻 | 过去 | 评论 | 提问 | 展示 | 招聘 | 提交 登录 真点对点电子邮件,基于Yggdrasil网络 (github.com/jb-selfcompany) 13 分,作者 basemi 26分钟前 | 隐藏 | 过去 | 收藏 | 1 条评论 fattybob 2分钟前 [–] 我的第一个Linux安装就是Yggdrasil,就是为了这个,这让我很感兴趣…回复 指南 | 常见问题 | 列表 | API | 安全 | 法律 | 申请YC | 联系 搜索:
相关文章

原文

English | Русский

True P2P Email on top of Yggdrasil Network

We're taught that email must go through servers. Why? Because the Internet was built around centralized infrastructure. Every email you send travels through multiple servers - your provider's server, maybe a few relay servers, and finally your recipient's provider's server. Each hop is a potential point of surveillance, censorship, or failure.

Even "encrypted" email solutions still rely on these centralized servers. They encrypt the message content but the metadata - who you're talking to, when, how often - is visible to anyone watching the servers.

But there is a network, called Yggdrasil, that gives everyone a free IPv6 and doesn't need a blessing from your ISP. We finally have this possibility to use true P2P email. And moreover, this network has strong encryption to protect all data that flows from one IP to another.

So, Tyr brings true peer-to-peer email to your Android device using these unusual conditions. Unlike traditional email clients, Tyr doesn't need:

  1. Centralized mail servers (the connections are straight P2P)
  2. Message encryption layers (the network takes care of that)
  3. Port forwarding or STUN/TURN servers (Yggdrasil handles NAT traversal)

What does Tyr already have?

  1. Full integration with DeltaChat and ArcaneChat - the best decentralized messengers
  2. Local SMTP/IMAP server running on your device
  3. Automatic Ed25519 key generation for your mail identity
  4. Connection to the Yggdrasil Network with configurable peers
  5. Auto-start on boot for always-on availability
  6. Encrypted backup & restore with password protection
  7. Automatic recovery from Android Keystore issues (Samsung devices)

One of Tyr's strong points is censorship circumvention: you can connect to any of hundreds of available Yggdrasil nodes, host your own, or even build a private network. Email freedom is literally in your hands.

Tyr runs a complete email server right on your Android device, using the Yggdrasil network for transport. The Yggmail mail server (built in Go) is embedded as a library inside the app and runs as a foreground service.

On top of Yggdrasil, it provides standard SMTP and IMAP protocols on localhost (127.0.0.1:1025 and 127.0.0.1:1143). Any email client can connect to these ports - but we recommend DeltaChat or ArcaneChat for the best P2P messaging experience.

Every Tyr installation generates unique Ed25519 cryptographic keys. Your mail address is derived from your public key, making it: <64-hex-characters>@yggmail. This means your identity is cryptographically verifiable and cannot be spoofed.

DeltaChat/ArcaneChat Integration

DeltaChat and ArcaneChat are perfect companions for Tyr. These are messengers that use email protocols but provide modern chat interfaces. When you configure DeltaChat/ArcaneChat to use Tyr's local server:

  1. DeltaChat/ArcaneChat sends messages via SMTP to Tyr
  2. Tyr wraps them in Yggmail protocol and sends through Yggdrasil
  3. The recipient's Tyr receives the message via Yggdrasil
  4. Their DeltaChat/ArcaneChat fetches it via IMAP from their local Tyr
  5. All this happens peer-to-peer, with no central servers

Setting up DeltaChat/ArcaneChat with Tyr

Option 1: Automatic Setup (Recommended)

  1. Install Tyr and complete the onboarding (set password, configure peers)
  2. Start the Yggmail service in Tyr
  3. Install DeltaChat or ArcaneChat from F-Droid or Google Play
  4. In Tyr's main screen, tap "Setup DeltaChat/ArcaneChat"
  5. Tyr will automatically open DeltaChat/ArcaneChat with pre-configured settings
  6. Complete the setup and start chatting!

If automatic setup doesn't work:

  1. Install Tyr and complete the onboarding (set password, configure peers)
  2. Start the Yggmail service in Tyr
  3. Copy your mail address from the main screen (looks like abc123...@yggmail)
  4. Install DeltaChat or ArcaneChat from F-Droid or Google Play
  5. In DeltaChat/ArcaneChat, tap "Create a new profile"
  6. Enter a name and optionally select an avatar
  7. Tap "Use a different server" (below the login fields)
  8. Enter your Yggmail address and the password you set in Tyr
  9. Tap "✓" in the top right corner to complete setup

Important: Tyr must be running for DeltaChat/ArcaneChat to send and receive messages. Enable auto-start in Tyr settings for seamless experience.

  • Android Studio (latest version recommended)
  • JDK 17
  • Android SDK (API 23-36)
  • Go 1.21+ and gomobile (only if rebuilding yggmail.aar)
  1. Clone the repository:
git clone <repository-url>
cd Tyr
  1. Build debug APK:
  1. Install to connected device:

APKs will be in app/build/outputs/apk/debug/ or app/build/outputs/apk/release/

Rebuilding yggmail.aar (optional)

If you need to rebuild the Yggmail library:

cd ../yggmail/mobile
# On Windows:
..\build-android.bat
# On Unix:
gomobile bind -target=android -androidapi 23 -javapkg=com.jbselfcompany.tyr -ldflags="-checklinkname=0" -o yggmail.aar .

Then copy yggmail.aar to Tyr/app/libs/

  • Language: Kotlin 2.2.20
  • Min SDK: 23 (Android 6.0)
  • Target SDK: 33 (Android 13)
  • Architecture: Layered (UI → Service → Data)
  • Mail server: Yggmail (Go library, embedded via gomobile)
  • Network: Yggdrasil overlay network
  • Localization: English, Russian

🔒 Security implementation:

  • Passwords are encrypted using Android Keystore System (AES256-GCM encryption)
  • Automatic Keystore recovery: Handles Android Keystore issues on Samsung and other devices automatically
  • Network encryption provided by Yggdrasil Network for all peer-to-peer communications
  • Local-only access: SMTP/IMAP ports (1025/1143) are bound to localhost only, not accessible from network
  • Cryptographic identity: Ed25519 keys ensure your mail address cannot be spoofed
  • Encrypted backups: Configuration and keys can be backed up with password protection
  • Yggmail: The mail transfer agent that powers Tyr
  • Mimir: P2P messenger on Yggdrasil (sister project)
  • Yggdrasil Network: The mesh network infrastructure
  • DeltaChat: Recommended email-based messenger client
  • ArcaneChat: Alternative email-based messenger client

Tyr is open source software. The Yggmail library uses Mozilla Public License v. 2.0.

See LICENSE file for full details

联系我们 contact @ memedata.com