Configuring Let's Encrypt with DNN

Let's Encrypt(LE) is becoming an increasingly popular option for SSL Certificates. This is because it is very easy to use, quick, and most of all free! Plesk has an available extension for LE, so customers have easy access to this feature. Unfortunately, DNN Advanced URLs conflict with LE's domain verification process. We have developed a way to get around this. A setting needs to be added into the database to make Advanced URLs ignore the path used for domain verification.
If you are using a rule in your web.config file to force your site to redirect to the secure (HTTPS) URL you will need to adjust the rule using the code below to allow non-secure (HTTP) access to the Lets Encrypt verification file:
        <rule name="HTTP to HTTPS redirect" stopProcessing="true">
        <match url="(.*)" />
        	<add input="{HTTPS}" pattern="off" ignoreCase="true" />
			<add input="{REQUEST_URI}" negate="true" pattern="^/.well-known/*$" ignoreCase="true" />
        <action type="Redirect" redirectType="Permanent" url="https://{HTTP_HOST}/{R:1}" />
Automatic(Dedicated Server Only)
  1. Remote into your dedicated server
  2. Launch Control Suite
  3. Expand Domains, find your desired domain, expand the domain.
  4. Select the DNN Install
  5. Click Allow Let's Encrypt
  6. Once the task finishes, recycle the site's application pool. 
Please Note: The steps below will may no longer work in newer versions of DNN, these rules below only apply to versions of DNN where you are not able to manage the Advanced URL rewriter in DNN host management typically in DNN versions 7.2.x to 7.3, thus due to the nature of this module being installed we will not be able to provide additional support as the module is no longer being maintained by the developer, and the information below is being maintained for reference only.
In order to manually fix this issue, you will need to install a module that allows for greater control of Advanced URLs. So, you will need Host/SuperUser access to the DNN website. 
Installing Module
  1. Download the DNNUrlManagement Module. (You can get this from here)
  2. Login to DNN as Host/SuperUser
  3. Browse to Host>Extensions
  4. Click Install Extension Wizard
  5. Click Choose File and select the .zip file you just downloaded. Click through the popup windows to finish the install
Accessing Module
  1. Browse to Admin>Page Management
  2. Right click on the Admin, and click Add Page(s). Name the new page DNN URL Management
  3. Right click the newly added page and click View Page
  4. On the new page, expand the Modules button at the top and search for 'X3'. Drag and drop the module wherever you want on the page.
Applying the Fix
  1. With the new module added, switch to the Regular Expressions tab.
  2. In the Dialog box for Ignore URL Regular Expressions add the following text to the end of the line.
  3. The full line should look like:
  4. Recycle the App Pool of the site.
  5. Try to process the Let's Encrypt SSL again.
If you are still having issues, you can also try the following:
  1. Copy the web.config file in C>inetpub>vhosts>domain>httpdocs>.well-known>acme-challenge
  2. Rename the original file to web.configold or something similar
  3. Name the copied file web.config
  4. Edit your new web.config and paste the following over the contents
<?xml version="1.0" encoding="UTF-8"?> 
<mimeMap fileExtension="*" mimeType="text/plain" /> 
<clear /> 
<add name="StaticFile" path="*" verb="GET" modules="StaticFileModule" resourceType="Either" /> 
Recycle the app pool and try agian.
If you are having trouble with these steps or these steps did not resolve your issue. Contact the Support team.

Add Feedback