{"id":15936915,"url":"https://github.com/cl0v1s/gpg-filter","last_synced_at":"2025-03-15T11:09:46.981Z","repository":{"id":147906803,"uuid":"479988125","full_name":"Cl0v1s/gpg-filter","owner":"Cl0v1s","description":"Content Filter for Postfix, encrypt all incoming emails with public keys","archived":false,"fork":false,"pushed_at":"2022-12-04T14:40:36.000Z","size":12,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-22T01:36:23.899Z","etag":null,"topics":["email","encryption","mail","privacy"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Cl0v1s.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-04-10T10:48:40.000Z","updated_at":"2022-04-10T22:29:31.000Z","dependencies_parsed_at":"2023-08-31T10:49:24.785Z","dependency_job_id":null,"html_url":"https://github.com/Cl0v1s/gpg-filter","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cl0v1s%2Fgpg-filter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cl0v1s%2Fgpg-filter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cl0v1s%2Fgpg-filter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cl0v1s%2Fgpg-filter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Cl0v1s","download_url":"https://codeload.github.com/Cl0v1s/gpg-filter/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243719399,"owners_count":20336607,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["email","encryption","mail","privacy"],"created_at":"2024-10-07T04:41:18.945Z","updated_at":"2025-03-15T11:09:46.951Z","avatar_url":"https://github.com/Cl0v1s.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GPG Filter\n\nThis script is a simple content filter for Postfix.  \nIt encrypts incoming emails using public keys saved in the configured gnupg home.  \nif no matching public key is available, the incoming e-mail will not be encrypted.\n\nIt was created as a [RFC 3156](https://datatracker.ietf.org/doc/rfc3156/) compliant alternative to [GPG-mailgate](https://github.com/fkrone/gpg-mailgate), since emails encrypted with the latter are not readable for most of the email clients with OpenPGP support.\n\n## Requirements \n\n* gnupg\n* Python 3.6\n* python-gnupg\n\n## How to use \n\nPlease read the [official postfix documentation](https://www.postfix.org/FILTER_README.html#simple_filter).\n\n1. Create a gpg-filter user with a home directory\n2. Download the script and keep its path in mind, make the gpg-filter user owner of the script's directory\n3. Edit /etc/postfix/master.cf and add the following at the end of the file\n\n```\ngpg-filter    unix  -       n       n       -       10      pipe\n    flags=Rq user=gpg-filter null_sender=\n    argv=/usr/bin/python3 path/to/gpg-filter/main.py ${recipient}\n```\n\n4. Edit /etc/postfix/master.cf and edit the smtp service so it will use gpg-filter as a content-filter\n\n```\n# =============================================================\n# service type  private unpriv  chroot  wakeup  maxproc command\n#               (yes)   (yes)   (yes)   (never) (100)\n# =============================================================\nsmtp      inet  ...other stuff here, do not change...   smtpd\n    -o content_filter=gpg-filter:dummy\n```\n\n5. Edit the gpg-filter config.json file and set `gnupghome` to the .gnupg folder in the gpg-filter user's home directory \n6. You can now add public keys to the gpg-filter user keyring with\n```\nsudo -u gpg-filter /usr/bin/gpg --import /some/public.key\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcl0v1s%2Fgpg-filter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcl0v1s%2Fgpg-filter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcl0v1s%2Fgpg-filter/lists"}