Security TXT Policy Server serves `.well-known/security.txt` files.
Project description
Security TXT Policy Server
Security TXT Policy Server serves .well-known/security.txt
files.
Install
Generic
Run the following command to create a source distribution:
python3 setup.py sdist
PyPI
Run the following command to install the package from PyPI:
pip3 install security-txt-policy-server
Configure
App
Find an example config in .env.example
.
Add settings to the .env
file. This file is relative to your working directory.
Only DATABASE_PATH
is required to be set. We recommend setting it to /var/lib/security-txt-policy-server.json
.
These settings can be overridden by specifying them as environment variables.
JSON Database
Find an example JSON database in security-txt-policy-server.json
.
Properties:
domains
. List of domains that this security.txt policy is served for.expires_timestamp
. UNIX timestamp of security.txt 'Expires' field.email_contacts
. (Do not add prefixmailto:
which is required by security.txt - the server does this.)url_contacts
encryption_key_urls
acknowledgment_urls
preferred_languages
canonical_urls
policy_urls
opening_urls
Find information about these properties on https://securitytxt.org/.
Usage
Start
Start Security TXT Policy Server manually with:
bin/security-txt-policy-server
Find the systemd configuration in security-txt-policy-server.service
.
SSL
Use a proxy that terminates SSL. E.g. HAProxy.
Tests
Run tests with pytest:
DATABASE_PATH=security-txt-policy-server.json pytest tests/
The tests must be run from the project root.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Hashes for security_txt_policy_server-1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4223ca2dc37cd3204a4b8cd2a8a0839c92ab37c566c784667b81897529bf9846 |
|
MD5 | 5511176a4579350bf53c40fef5aeae11 |
|
BLAKE2b-256 | a3a182eb2a283142a516f21259f5eac9075087beeb4a2ae191f5da41e8513893 |