Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mozilla/ssl-config-generator.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGene Wood <gene_wood@cementhorizon.com>2022-07-29 00:14:18 +0300
committerGene Wood <gene_wood@cementhorizon.com>2022-07-29 00:14:18 +0300
commit1936deb5336cb9dfceced1deb4cc5a19f6bff54e (patch)
treed05947e821a899b5d3f8883e927b6d26678ece95
parent307568851c64512b1efe98dd78f200e35f606a25 (diff)
Add documentation written by gstrauss on template variables
Content from https://github.com/mozilla/ssl-config-generator/issues/23#issuecomment-813822976 Fixes #23
-rw-r--r--README.md30
1 files changed, 30 insertions, 0 deletions
diff --git a/README.md b/README.md
index 0138fd0..61b0077 100644
--- a/README.md
+++ b/README.md
@@ -47,6 +47,36 @@ All of the templates are written in [Handlebars.js](https://handlebarsjs.com/),
- `split(string, splitter)` - split a string into an array based on `splitter`
- `{{#each (split somearray ":")}}`
+### Template variables
+
+Highlighted items from src/js/state.js for use in templates. See src/js/state.js for more.
+
+- `form.serverName` - Server Name
+- `form.serverVersion` - Server Version
+- `form.opensslVersion` - OpenSSL Version
+- `form.config` - configuration name ([ "modern" | "intermediate" | "old" ])
+- `form.hsts` - HTTP Strict Transport Security form checkbox (boolean true/false)
+- `form.ocsp` - OCSP Stapling form checkbox (boolean true/false)
+
+- `output.header` - description of rendered config (`# {{output.header}}`)
+- `output.link` - URL to rendered config (`# {{{output.link}}}`)
+- `output.protocols` - protocol list (e.g. zero or more of: "TLSv1" "TLSv1.1" "TLSv1.2" "TLSv1.3")
+- `output.ciphers` - cipher list (`{{join output.ciphers ":"}}`)
+- `output.cipherSuites` - cipher suites list
+- `output.serverPreferredOrder` - enforce ServerPreference for ordering cipher list (boolean true/false)
+- `output.hstsMaxAge` - max-age (seconds) for Strict-Transport-Security: max-age=... HTTP response header
+- `output.permanentRedirect` - HTTP status code ([ 301 | 308 ]) to use for permanent redirect from http://site to https://site
+
+- `output.latestVersion` - server latest version
+- `output.usesOpenssl` - server uses openssl (boolean true/false)
+- `output.usesDhe` - server might use Diffie-Hellmann key exchange (boolean true/false)
+- `output.dhCommand` - command to generate Diffie-Hellman (DH) parameters
+- `output.hasVersions` - server config has versions (boolean true/false)
+- `output.supportsConfigs` - supports modern, intermediate, old configs (boolean true/false)
+- `output.supportsHsts` - supports HTTP Strict Transport Security (HSTS) (boolean true/false)
+- `output.supportsOcspStapling` - supports OCSP Stapling (boolean true/false)
+- `output.tls13` - minimum server version supporting TLSv1.3
+
## Building
To publish to GitHub Pages, simply run: