Repository navigation
Releases
pst2eml v0.2.0
First release of pst2eml, a converter of PST files (Outlook and Enterprise Vault exports) to EML, and of the go-pst reader it is built on (a continuation of mooijtech/go-pst).
pst2eml -o out/ mailbox.pstwrites one .eml per message into a directory per folder and prints a report per folder (read, converted, skipped with the reason, errors). Options: -skip-deleted, -codepage, -version. Exit status 0 if every item was converted or skipped by design, 1 if items failed, 2 for usage errors.
Conversion
- Received mail keeps its original transport headers; sent mail and drafts get headers built from the properties: From/Sender with SMTP addresses, To/Cc/Bcc from the recipient table, Date, Message-ID, In-Reply-To, References
- Plain text, HTML (in its original charset) and RTF bodies (RTF encapsulating HTML back to HTML), attachments with MIME type and Content-ID, inline images, forwarded messages as
message/rfc822 - S/MIME messages are rebuilt from their original entity, so signatures stay verifiable
- Unicode and ANSI (pre-2003) PST files
- Appointments, contacts and other non-mail items, and Enterprise Vault shortcuts, are counted and skipped
Binaries: static builds for Linux, Windows and macOS on amd64 and arm64, checksums in SHA256SUMS. Or go install github.com/jsuto/go-pst/cmd/pst2eml@v0.2.0.
Tested on Outlook exports and on the EDRM Enron PSTs (up to 2 GiB, 70,000 messages); PSTs over 4 GiB are untested. See the README for details and limitations.