Apps/BlockPageApp/README.md
A DNS App for Technitium DNS Server that serves a configurable block page from an embedded web server.
IDnsApplicationdnsApp.config can be either a single object or an array of objects. Each object supports:
| Property | Type | Default | Description |
|---|---|---|---|
name | string | default | Instance name. |
enableWebServer | boolean | true | Enables the web server instance. |
webServerLocalAddresses | string[] | [] | Local IPs to bind to. |
webServerUseSelfSignedTlsCertificate | boolean | true | Use a generated self-signed certificate. |
webServerTlsCertificateFilePath | string | null | Path to a .pfx/.p12 certificate. |
webServerTlsCertificatePassword | string | null | Certificate password. |
webServerEnableOnlineCertificateSigning | boolean | Enables the online TLS certificate generation feature for enabling HTTPS MiTM. | |
webServerRootPath | string | wwwroot | Static file root. |
serveBlockPageFromWebServerRoot | boolean | false | Serve static files instead of generated block page. |
blockPageTitle | string | Website Blocked | Page title. |
blockPageHeading | string | Website Blocked | Page heading. |
blockPageMessage | string | This website has been blocked by your network administrator. | Page message. |
includeBlockingInfo | boolean | true | Include blocking info/EDE details on page. |
[
{
"name": "default",
"enableWebServer": true,
"webServerLocalAddresses": ["0.0.0.0", "::"],
"webServerUseSelfSignedTlsCertificate": true,
"webServerTlsCertificateFilePath": null,
"webServerTlsCertificatePassword": null,
"webServerEnableOnlineCertificateSigning": true,
"webServerRootPath": "wwwroot",
"serveBlockPageFromWebServerRoot": false,
"blockPageTitle": "Website Blocked",
"blockPageHeading": "Website Blocked",
"blockPageMessage": "This website has been blocked by your network administrator.",
"includeBlockingInfo": true
}
]
serveBlockPageFromWebServerRoot is false, it generates a page from the title/heading/message values.serveBlockPageFromWebServerRoot is true, it serves static content from webServerRootPath.webServerLocalAddresses match the DNS blocking target addresses.