···11# Changelog
2233# 2026-04-10
44+- **Proton Mail Bridge compatibility** — documented that Proton Mail works with neomd only via Proton Mail Bridge (paid Proton feature), added optional `tls_cert_file` support for trusting Bridge’s exported self-signed certificate, and added a narrow localhost-only TLS retry fallback for Bridge connections on `127.0.0.1`/`localhost`; normal remote IMAP/SMTP providers keep their existing strict certificate verification behavior
45- **Issue #6 verification pass** — reviewed the user report against the current code and specifically verified that startup auto-screening does not route Inbox mail to Trash in the current implementation, while manual `ToScreen` screening remains message-by-message by design
56- **Fix: Drafts/Spam reload off-tab folder mismatch** — reloading while viewing an off-tab folder now reloads that actual mailbox instead of the currently selected tab's folder; fixes the confusing case where Drafts could show Inbox content after pressing `R`
67- **Fix: committed `/` filter now clears with `esc`** — pressing `esc` now reliably clears the in-memory inbox filter even after the filter was already applied
···1313password = "app-password"
1414from = "Me <me@example.com>"
1515starttls = false # optional: force STARTTLS (see TLS/STARTTLS section below)
1616+tls_cert_file = "" # optional PEM cert/CA for self-signed local bridges
16171718# OAuth2 authenticated accounts are supported, it just need the relevant fields. Note that the password field is not required.
1819[[accounts]]
···122123imap = "imap.gmail.com:993"
123124smtp = "smtp.gmail.com:587"
124125starttls = false # optional, default behavior works
126126+tls_cert_file = ""
125127```
126128127129Proton Mail Bridge (local bridge on non-standard ports):
···130132imap = "127.0.0.1:1143" # Uses TLS automatically
131133smtp = "127.0.0.1:1025" # Uses TLS; set starttls=true if bridge uses STARTTLS
132134starttls = false
135135+tls_cert_file = "~/ProtonBridge/cert.pem" # optional: exported Bridge cert
133136```
134137135138Custom server with STARTTLS on non-standard port:
···141144```
142145143146See `docs/proton-bridge.md` for complete Proton Mail Bridge setup instructions.
147147+148148+For localhost/self-signed bridges such as Proton Mail Bridge, neomd first tries
149149+normal certificate verification. If that fails with an unknown-authority error
150150+on a loopback host (`127.0.0.1`, `::1`, `localhost`), neomd retries once with a
151151+localhost-only fallback so existing Bridge setups keep working. If you want
152152+strict verification, export the Bridge certificate and set `tls_cert_file`.
144153145154## Sending and Discarding
146155
+17
docs/proton-bridge.md
···2121 password = "bridge-password-here" # Get this from Proton Bridge settings
2222 from = "Your Name <your-proton-email@proton.me>"
2323 starttls = false # Proton Bridge uses TLS on non-standard ports
2424+ tls_cert_file = "~/ProtonBridge/cert.pem" # optional: exported Bridge certificate
2425```
25262627## Key Configuration Details
···3334 - Standard ports (993→TLS, 143→STARTTLS for IMAP; 465→TLS, 587→STARTTLS for SMTP)
3435 - Non-standard ports default to TLS unless `starttls = true` is set
3536 - Explicit `starttls = true` always forces STARTTLS
3737+- **Certificate**: Proton Bridge uses a self-signed certificate because the IMAP/SMTP server only runs on your own computer. neomd now handles this in two ways:
3838+ - Best: export the Bridge certificate and set `tls_cert_file`
3939+ - Fallback: for `127.0.0.1` / `localhost`, neomd retries once if verification fails with an unknown-authority error
36403741## Troubleshooting
3842···44481. Ensure you're running the latest version: `neomd --version`
45492. Check your config has the correct IMAP/SMTP addresses
46503. Verify Proton Bridge is running: `ps aux | grep bridge`
5151+5252+### "tls: failed to verify certificate"
5353+5454+This usually means Proton Bridge presented its local self-signed certificate and
5555+your client did not trust it yet.
5656+5757+Recommended fix:
5858+1. In Proton Mail Bridge, export the TLS certificates
5959+2. Point `tls_cert_file` at the exported `cert.pem`
6060+3. Keep `starttls = false` for IMAP on `1143` unless your Bridge shows otherwise
6161+6262+Without `tls_cert_file`, neomd now retries once for loopback hosts only, which
6363+keeps common Proton Bridge setups working without affecting normal remote IMAP servers.
47644865### Connection Refused
4966