Event handler plugin for restricting parts of an Umbraco website to an Intranet.
This project includes a DLL that will register as an event handler with Umbraco. Depending on set page properties or config settings, required pages will be redirected to HTTPS.
- NET Framework 4.5
- Umbraco 7.3.7+ (should work with older versions but not tested)
This project is available on NuGet.
- Add UmbHttpsRedirect.dll as a reference in your project or place it in the \bin folder.
- Insert the following
<appSettings>keys in web.config:
HttpsRedirect:DocTypes- comma-separated list of document type aliases that should use HTTPSHttpsRedirect:PageIds- comma-separate list of page IDs that should use HTTPSHttpsRedirect:Templates- comma separated list of templates that should use HTTPSHttpsRedirect:ForceHttp- true/false (default false) to redirect pages that aren't required to be HTTPS to HTTPHttpsRedirect:HttpPort- optional port to use when redirecting to HTTPHttpsRedirect:HttpsPort- optional port to use when redirecting to HTTPSHttpsRedirect:UseTemporaryRedirects- true/false (default false) if to use 302 Temporary redirects rather than 301 Permanent redirects
- To restrict access to specific pages, add a true/false-type document property in Umbraco:
umbHttpsRedirect