Build features and configuration
This page lists every Cargo feature, environment variable, command-line switch, and configuration field of both forms, and says for each one whether it has any effect today.
L4Re form: Cargo features
| Feature | Default | Effect |
|---|---|---|
openssl-vendored | on | builds OpenSSL from the sources in the openssl-src package, currently OpenSSL 3.5.4; requires Perl and a C compiler |
openssl-system | off | links an existing OpenSSL found through OPENSSL_DIR or the system search |
openssl-local | off | same as openssl-system; intended for prebuilt libraries when cross-compiling |
chacha20 | off | enables request types 0x03 and 0x04; not approved under FIPS 140-3 |
pqc | on | no effect; the post-quantum algorithms are always built in |
fips | off | no effect; no FIPS mode is implemented |
l4re, demo, bindgen | off | no effect |
One of the three openssl-* features must be enabled; if openssl-vendored is among them, it wins. To
link your own OpenSSL 3.6, build with --no-default-features --features pqc,openssl-system; see
Use your own OpenSSL build.
L4Re form: environment variables
| Variable | Effect |
|---|---|
OPENSSL_DIR | directory of the OpenSSL to link, with include/ and lib/ or lib64/; takes precedence over everything else |
L4RE_OPENSSL_DIR | root of prebuilt libraries per architecture; expects <root>/x86_64 or <root>/aarch64 |
OPENSSL_STATIC | 1 links OpenSSL statically; l4re/.cargo/config.toml sets this for aarch64 |
RUST_LOG | service log level, such as debug; default info |
For the Linux targets, l4re/.cargo/config.toml adds library paths from the machine on which the
delivered packages were built. If they don't exist, no harm is done; a set OPENSSL_DIR takes
precedence.
The file also defines three aliases:
| Command | Meaning |
|---|---|
cargo build-all | build for x86_64-unknown-linux-gnu and aarch64-unknown-linux-gnu |
cargo test-native | library tests only |
cargo lint | Clippy with every warning treated as an error |
Windows form: build
| Setting | Effect |
|---|---|
OPENSSL_DIR | directory of a prebuilt OpenSSL with include\, lib\libcrypto.lib, and lib\libssl.lib; if unset, the path from win/.cargo/config.toml applies |
OPENSSL_STATIC | 1 links OpenSSL statically; required if lib\ contains only static libraries |
Feature chacha20 | no effect; the Windows form has no ChaCha20 operation |
Windows form: command line
wvds_crypto_service [--config <path>] [--no-tui] [--single] [--help]
| Switch | Effect |
|---|---|
--config, -c | loads the configuration from the given file; if the file can't be read, the defaults apply |
--no-tui, -n, --headless | no terminal UI, log to the console |
--single, -s | one pipe only, \\.\pipe\wvds_crypto |
--help, -h | help |
Without --config, the service looks in the current directory for wvds_crypto.json,
config/wvds_crypto.json, and config.json, in that order. If none exists, it opens the pipes
wvds_crypto_gw1, wvds_crypto_gw2, wvds_crypto_gw3, and wvds_crypto.
Windows form: configuration file
{
"name": "WvdS Post-Quantum Crypto Service",
"max_keys": 1024,
"tui_enabled": true,
"log_level": "info",
"gateways": [
{ "id": "default", "name": "Default Gateway", "pipe_name": "\\\\.\\pipe\\wvds_crypto", "enabled": true }
]
}
| Field | Default | Effect |
|---|---|---|
name | WvdS Post-Quantum Crypto Service | display only |
version | – | no effect |
max_keys | 1024 | maximum number of keys held at once |
tui_enabled | true | terminal UI; --no-tui takes precedence |
log_level | info | trace, debug, info, warn, error; applies only without the terminal UI |
gateways | required | list of pipes |
gateways[].id | required | ID in the log and statistics |
gateways[].name | required | display only |
gateways[].pipe_name | required | full pipe name, with doubled backslashes in JSON |
gateways[].enabled | true | false keeps the pipe closed |
gateways[].priority, scenario_groups, description | – | no effect |
gateways[].rate_limit | – | no effect; the fixed limit of 60,000 requests per 60 seconds applies to the whole service |
The sample files win/wvds_crypto.json and win/config/wvds_crypto_demo.json open several pipes for a
demonstration.