Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jnphilipp/gpgmail
Encrypt/Decrypt GPG/MIME emails.
https://github.com/jnphilipp/gpgmail
Last synced: 3 months ago
JSON representation
Encrypt/Decrypt GPG/MIME emails.
- Host: GitHub
- URL: https://github.com/jnphilipp/gpgmail
- Owner: jnphilipp
- License: gpl-3.0
- Created: 2019-06-27T12:00:46.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-03-29T12:27:53.000Z (over 1 year ago)
- Last Synced: 2024-07-14T12:37:24.455Z (4 months ago)
- Language: Python
- Size: 225 KB
- Stars: 14
- Watchers: 3
- Forks: 5
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-starred - jnphilipp/gpgmail - Encrypt/Decrypt GPG/MIME emails. (others)
README
# gpgmail
[![Tests](https://github.com/jnphilipp/gpgmail/actions/workflows/test.yml/badge.svg)](https://github.com/jnphilipp/gpgmail/actions/workflows/test.yml)
[![DEB Package](https://github.com/jnphilipp/gpgmail/actions/workflows/deb.yml/badge.svg)](https://github.com/jnphilipp/gpgmail/actions/workflows/deb.yml)This tool can encrypt and decrypt emails using PGP/MIME. When encrypting,
the tool preserves all headers in the original email in the encrypted part, and
copies relevant headers to the output. When decrypting, any headers are
ignored, and only the encrypted headers are restored.Encrypted email are not reencrypted. This is check based on the content type.
## Requirements
* Python 3.7 or newer
* python-gnupg
* gnupg## Install
* from Source: ```make install```
* deb-Package: ```make deb```## Usage
### Postfix
Update ```smtp```, ```smtps``` and ```submission``` in ```/etc/postfix/master.cf```, add ```-o content_filter=gpgmail-pipe``` to the end, for example:
```
smtp inet n - - - - smtpd -o content_filter=gpgmail-pipe
```And add to the end of ```/etc/postfix/master.cf```:
```
gpgmail-pipe unix - n n - - pipe
flags=Rq user=gpgmail argv=/usr/bin/gpgmail-postfix --sign-encrypt --gnupghome /home/gpgmail/.gnupg --encrypt-headers --key KEYID --passphrase PASSPHRASE --recipient ${recipient} -oi -f ${sender}
```