#parser #nom #mail #zero-copy

email-parser

The fastest and lightest mail parsing Rust library

4 releases

✓ Uses Rust 2018 edition

0.1.3 Jun 29, 2020
0.1.2 Jun 29, 2020
0.1.1 Jun 29, 2020
0.1.0 Jun 29, 2020

#47 in Email


Used in dkim

MIT license

8KB
135 lines

email-parser

The fastest and lightest mail parsing Rust library. This library is extremely lightweight and does not support common things like header unfolding. No-panic and zero-copy, written with nom.

Benchmarks

This chart shows the time took to parse a single mail. The other crates are slower, but they offer more features.

Benchmark

Run the benchmark by yourself with rustup run nightly cargo bench. Tests require a mail.txt file containing a raw mail next to the Cargo.toml.

License: MIT


lib.rs:

The fastest and lightest mail parsing Rust library.
This library is extremely lightweight and does not support common things like header unfolding.
No-panic and zero-copy, written with nom.

Benchmarks

This chart shows the time took to parse a single mail.
The other crates are slower, but they offer more features.

Benchmark

Run the benchmark by yourself with rustup run nightly cargo bench.
Tests require a mail.txt file containing a raw mail next to the Cargo.toml.

Dependencies

~670KB
~14K SLoC