Podop is a piece of middleware designed to run between Postfix or Dovecot on one side, any Python implementation of a table lookup protocol on the other side.
It is thus able to forward Postfix maps and Dovecot dicts to the same (or multiple) backends in order to write a single, more flexible backend for a mail distribution.
Examples
- Connect Postfix to a DNS lookup so that every domain that has a proper MX record to your Postfix is actually accepted as a local domain
- Connect both Postfix and Dovecot to an HTTP microservice to run a high availability microservice-based mail service
- Use a single database server running any Python-compatible API for both your Postfix and Dovecot servers
Configure Podop tables
Podop tables are configured through CLI arguments when running the server.
You must provide a --name for the table, a --type for the table and
a --param that parametrizes the map.
URL table
The URL table will initiate an HTTP GET request for read access and an HTTP
POST request for write access to a table. The table is parametrized with
a template URL containing § (or {}) for inserting the table key.
--name test --type url --param http://microservice/api/v1/map/tests/§
GET requests should return 200 and a JSON-encoded object
that will be passed either to Postfix or Dovecot. They should return 4XX
for access issues that will result in lookup miss, and 5XX for backend
issues that will result in a temporary failure.
POST requests will contain a JSON-encoded object in the request body, that will be saved in the table.
Postfix usage
In order to access Podop tables from Postfix, you should setup socketmap
Postfix maps. For instance, in order to access the test table on a Podop
socket at /tmp/podop.socket, use the following setup:
virtual_alias_maps = socketmap:unix:/tmp/podop.socket:test
Multiple maps or identical maps can be configured for various usages.
virtual_alias_maps = socketmap:unix:/tmp/podop.socket:alias
virtual_mailbox_domains = socketmap:unix:/tmp/podop.socket:domain
virtual_mailbox_maps = socketmap:unix:/tmp/podop.socket:alias
In order to simplify the configuration, you can setup a shortcut.
podop = socketmap:unix:/tmp/podop.socket
virtual_alias_maps = ${podop}:alias
virtual_mailbox_domains = ${podop}:domain
virtual_mailbox_maps = ${podop}:alias
Dovecot usage
In order to access Podop tables from Dovecot, you should setup a proxy
Dovecot dictionary. For instance, in order to access the test table on
a Podop socket at /tmp/podop.socket, use the following setup:
mail_attribute_dict = proxy:/tmp/podop.socket:test
Multiple maps or identical maps can be configured for various usages.
mail_attribute_dict = proxy:/tmp/podop.socket:meta
passdb {
driver = dict
args = /etc/dovecot/auth.conf
}
userdb {
driver = dict
args = /etc/dovecot/auth.conf
}
# then in auth.conf
uri = proxy:/tmp/podop.socket:auth
iterate_disable = yes
default_pass_scheme = plain
password_key = passdb/%u
user_key = userdb/%u
Contributing
Podop is free software, open to suggestions and contributions. All components are free software and compatible with the MIT license. All the code is placed under the MIT license.
Metadata
Release files for podop 0.2.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| podop-0.2.6.tar.gz | 7.7 kB | Without provenance | Details for podop-0.2.6.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| podop-0.2.6-py3-none-any.whl | Python 3 | none | any | Details for podop-0.2.6-py3-none-any.whl |
Total release size: 16.9 kB
Release files / podop-0.2.6.tar.gz
| Download URL | podop-0.2.6.tar.gz |
|---|---|
| Size | 7.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d269a2b8eb13b1017f1df48349e7f6d40d5fdfc089e0d7752de7b2034870ae25
|
|
BLAKE2b-256 checksum How to use checksums |
963c91d620a56fa6cbd94e439e9fe42f0a6b19d891da187c0718321e820acf2e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.6.8
|
Release files / podop-0.2.6-py3-none-any.whl
| Download URL | podop-0.2.6-py3-none-any.whl |
|---|---|
| Size | 9.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2a0a1d3a8d5447f3a30c775e52e4c61f6a913ee823fd1850a6a310b0c4e89243
|
|
BLAKE2b-256 checksum How to use checksums |
e57b7b83d53208566fedfab7d253cbacc384d9fa739f0f62009a7b1b3cd2668a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.6.8
|
Security for podop 0.2.6
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.