Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # protonmail bridge setup over a systemd daemon with msmtp and isync
- * msmtp
- ~/.msmtprc
- #+BEGIN_SRC
- defaults
- auth on
- tls on
- logfile ~/.msmtp.log
- # ProtonMail Bridge
- account protonmail
- host 127.0.0.1
- port 1025
- from USERNAME
- user USERNAME
- password PASS
- tls_starttls on
- tls_fingerprint XX:XX:XX:XX:...
- #Set a default account
- account default : protonmail
- #+END_SRC
- Get tls fingerprint from this:
- #+BEGIN_SRC
- openssl s_client -starttls smtp -connect 127.0.0.1:1025 < /dev/null 2>/dev/null | openssl x509 -fingerprint -noout -in /dev/stdin | cut -d'=' -f2
- #+END_SRC
- * isync (mbsync)
- ~/.mbsyncrc
- #+BEGIN_SRC
- IMAPAccount protonmail
- Host 127.0.0.1
- Port 1143
- User USERNAME
- pass PASS
- SSLType STARTTLS
- CertificateFile LOCATION_OF_CERTFILE
- IMAPStore protonmail-remote
- Account protonmail
- MaildirStore protonmail-local
- Path ~/.mail/protonmail/
- Inbox ~/.mail/protonmail/Inbox/
- Channel protonmail-inbox
- Master :protonmail-remote:
- Slave :protonmail-local:
- Patterns "INBOX"
- Create Both
- Expunge Both
- SyncState *
- Channel protonmail-sent
- Master :protonmail-remote:"Sent"
- Slave :protonmail-local:"sent"
- Create Both
- Expunge Both
- SyncState *
- Channel protonmail-trash
- Master :protonmail-remote:"Trash"
- Slave :protonmail-local:"trash"
- Create Both
- Expunge Both
- SyncState *
- Channel protonmail-allmail
- Master :protonmail-remote:"All Mail"
- Slave :protonmail-local:"allmail"
- Create Both
- Expunge Both
- SyncState *
- Group protonmail
- Channel protonmail-inbox
- Channel protonmail-sent
- Channel protonmail-trash
- Channel protonmail-allmail
- #+END_SRC
- Make certfile. Put the everything from "-----BEGIN CERTIFICATE-----" and "-----END CERTIFICATE-----" in a file.
- #+BEGIN_SRC
- openssl s_client -starttls imap -connect 127.0.0.1:1143 -showcerts
- #+END_SRC
- * daemonize Desktop-Bridge
- start within a detache screen session. Create a systemd service file.
- ~/.config/systemd/user/bridge.service
- #+BEGIN_SRC
- [Unit]
- Description=Desktop-Bridge: Protonmail Bridge - ProtonMail IMAP and SMTP Bridge
- [Service]
- Type=simple
- ExecStart=/usr/bin/screen -Dm bash -c "sleep 5; Desktop-Bridge -c"
- Restart=always
- [Install]
- WantedBy=default.target
- #+END_SRC
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement