mirror of
https://github.com/storytold/craft-libs.git
synced 2026-11-17 05:14:24 +00:00
* feat: add craft-proto (IMAP4rev1 + SMTP clients) Port from mailcraft: IMAP4rev1 and SMTP protocol clients over any Read + Write stream, no sockets or browser APIs. ## IMAP (RFC 3501, 4315, 4959, 6154, 6851) - Mailbox operations: SELECT, EXAMINE, LIST, LSUB - Message operations: FETCH, STORE, COPY, MOVE, EXPUNGE - IDLE (RFC 2177): server-initiated change notifications - AUTH: PLAIN, LOGIN, XOAUTH2 (RFC 4954) - STATUS (RFC 3501 §6.3.10): mailbox stats without opening - Modified UTF-7 encoding for mailbox names ## SMTP (RFC 5321, 3207, 4954) - EHLO/HELO, MAIL FROM, RCPT TO, DATA - STARTTLS (RFC 3207) - AUTH: PLAIN, LOGIN, XOAUTH2 ## Design - No I/O of its own: works over any Read + Write stream - Hostile-input bounded reading: lines, literals, counts capped - Passwords and tokens never reach logs or errors (Secrets wiped on drop) - Follows craft-libs safety pattern: no unwrap/expect/panic * fix(proto): restore standalone protocol wiring and safe authentication helpers * fix(proto): register dependencies and export message macro * fix(proto): retain upstream private trace filtering and regression coverage * fix(proto): redact uppercase private reply text and preserve error API * fix(proto): satisfy hosted workspace lint gates * fix(proto): bound IDLE polling and preserve mailbox updates safely * test(proto): exercise BODY sections in FETCH context * test(proto): distinguish fixed UID ranges from wildcard bounds
21 lines
480 B
TOML
21 lines
480 B
TOML
[package]
|
|
name = "craft-proto"
|
|
description = "Mail protocols without sockets: IMAP4rev1 and SMTP clients over any Read + Write stream"
|
|
version.workspace = true
|
|
edition.workspace = true
|
|
license.workspace = true
|
|
rust-version.workspace = true
|
|
repository.workspace = true
|
|
|
|
[lints]
|
|
workspace = true
|
|
|
|
[dependencies]
|
|
base64 = "0.23"
|
|
zeroize = "1"
|
|
# Internationalization: error messages and user-facing text.
|
|
log = { workspace = true }
|
|
|
|
[dev-dependencies]
|
|
proptest = { workspace = true }
|