alpha
Login
or
Join now
jcollie.dev
/
zig-smtp
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
An SMTP client and server library for Zig implementing RFC 5321.
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Overview
Issues
Pulls
Pipelines
zig-smtp
/
nix
2 files
at
8d96c14c969b1a6480d96b6b6ba889050decc446
Jeffrey C. Ollie
Add Exim interop tests; switch client TLS to tls.zig
14d ago
8d96c14c
interop-test.nix
Add Exim interop tests; switch client TLS to tls.zig The VM test now also runs the zsmtp client against Exim (ports 2625/2626) over plaintext, STARTTLS, and implicit TLS, with taint-safe appendfile delivery checked in /var/spool/exim-mail. Exim exposed a standard-library TLS bug: std.crypto.tls.Client only advances its record-decryption state upon receiving the TLS 1.3 middlebox-compatibility ChangeCipherSpec record, which is optional and disabled by Exim's OpenSSL setup, so the handshake died with TlsUnexpectedMessage. The client-side Tls wrapper now uses ianic/tls.zig (already used server-side) instead: init is in-place (the connection holds interior pointers), and the flush-through workaround is gone since tls.zig flushes each record to the stream. A sendmail interop test was built and passing but removed again since nixpkgs does not package the sendmail MTA. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012HBHFhoTYa8TU9GLwobfbx
2 weeks ago
package.nix
Add Nix package and NixOS VM interop tests nix/package.nix builds zsmtp with zig_0_16 and runs the unit tests; the tls.zig dependency is provided offline by materializing it into the project-local zig-pkg/<hash>/ directory with only the files from the dependency's paths list, so Zig's content hash matches. nix/interop-test.nix exercises zsmtp against third-party implementations in one VM: - zsmtp client -> Postfix: plaintext (25), STARTTLS (25), implicit TLS (465, submissions wrapper mode), verified via alice's maildir spool - swaks -> zsmtp server: plaintext and STARTTLS (snakeoil EC cert), verified via the server's journal Exposed as packages.zsmtp/default and checks.{zsmtp,interop}. Postfix on NixOS delivers maildir-style (mail_spool_directory has a trailing slash), so assertions grep the directory recursively, with 60s timeouts to fail fast. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012HBHFhoTYa8TU9GLwobfbx
2 weeks ago