Valvula server features

Server component separation

Valvula server is composed by several components which are a base library (libValvula), a run time server (Valvulad) and extension modules that provides the final end user features required by system administrators.

libValvula allows to encapsulate all low level functions that interacts with the postfix server to parse and reply requests. This library allows to embed all functions into a different application and/or creating different context where different handlers can be configured to process incoming requests.

Valvulad server is built on top of libValvula providing all system administrator functions like port configuration, modules to load, system user to run the server. This server allows a system administrator to enable/disable Valvula features, control its limits and receive logging about what's done by the server.

The administrator can enable different modules/plugins ready available to provide support to different features like Sender Login Mismatch handling, mail sending quotas, global/domain/account whitelists and blacklists, ...

Threaded design

Valvula is highly threaded server that allows to handle thousand of requests per minute with a single process. It also includes an internal queue design to avoid overflooding the server when there are a high number of requests.

Even though there is a threading design in place, writing modules is really easy because ValvulaD server takes cares of many details so plugin writer only has to pay attention on the core features its module has.

Port separation with different policies

Valvula has the hability to provide different policies (groups of modules that are applied in a particular order) on different ports. This way you can have the same Valvula server process applying different policies at the different postfix sections you require.

Because you can have different combination of modules at different ports, you are able to connect Valvula through postfix's check_policy_service in a really flexible manner.

Automatic postfix configuration detection

Valvula comes with a built-in postfix configuration parser that allows automatic postfix database detection. This way Valvula will detect which domains and accounts are considered local by your Postfix server, allowing valvula to make better decisions.

This includes skipping some modules when the requests talks about a local delivery or to skip a wrong white list rule that otherwise will imply that your mail server becomes an open relay.

This feature is provided through an API (valvulad_run_is_local_domain, valvulad_run_is_local_address, valvulad_run_is_local_delivery) that modules can leverage to create powerful plugins.

Robust and well tested implementation

Valvula suite is an ANSI C implementation checked with valgrind ( and supervised by a strong regression test to ensure the library, core server and modules keep on working without any failure as the project moves forward.

Currently it is being used intensively at many hosting providers and in-house mail server solutions with high SMTP traffic.

Real time internal stats support

Valvula comes with support to provide system administrators with real time process status and stats. This way it is possible to get up to date information about requests being handled, pending tasks or how long is taking Valvula server to process each requests (and how much time each module takes to process requests).

To get stats, just run the following in a server where valvula server is running:

>> valvulad -s

Valvula is administrator friendly

We are system administrators too and we like it easy. Valvula has various automatic processes that frees you from the database burden, module activation and many other details.

For example, you only have to create a MySQL database along with a MySQL user, and after configuring it into valvula's conf, then valvula will create for you all database tables, attributes, etc. It even will handle database updates across releases automatically for you.

Easy module design

Adding new valvula modules is really easy. You only have to implement a set of handlers that let you process requestes received.

Along with this handlers you have a featureful API that includes many functions to help you write concise modules quickly and easily.

Take a look at the valvula mod-test implementation to get a first glance:

And don't forget, Valvula is open source!

Valvula is provided to the world with an open source license (GPL) that allows integrating it into any enviroment without any cost.