DNN Forums

Ask questions about your website to get help learning DNN and help resolve issues.

Redirected you too many times, if enable SSL on a page.

 7 Replies
 3 Subscribed to this topic
 40 Subscribed to this forum
Sort:
Author
Messages
Growing Member
Posts: 45
Growing Member

Dear All, 

I have a strange problem with the site. I have configured SSL on the live site once I Access the site by typing https://www.mydomain.com it's working fine but when I enabled the SSL through page settings or enforced SSL from the site settings it throws an error of www.mydomain.com redirected you too many times.

In the site settings, I have set  CANONICAL URL

Here is the site running file if I place https:// manually in the URL 

Is there any thing that I am doing wrong? 

Regards 

3ART TechnologiesRegards,
3ART Technologies Expert

3ART Technologies
Experts in Analysis, Design & Development for DNN and SharePoint Solution
https://www.3art.tech/
Senior Member
Posts: 1322
Senior Member
3 Helpful Replier
Helpful Replier
Thanks for being such a helpful replier!
Lifesaver
Lifesaver
You're Life Saver!
New Poster
New Poster
Congrats on posting!
3 Engaged Reader
Engaged Reader
You are an engaged reader!

Did you try this in a private browser?
Sometimes the browser caches the redirect and you end up in an endless loop.
Also using a redirect ruile in web.config is much more efficient than using the options in DNN.

https://aboutssl.org/iis-...ction-http-to-https/

Senior Member
Posts: 1607
Senior Member
MVP
MVP
You're an MVP!
New Poster
New Poster
Congrats on posting!

If you're behind a WAF (such as CloudFlare), you may need to adjust the SSL setting on your WAF, or install an SSL certificate in your hosting environment.  If the SSL isn't working completely, end-to-end, this will also cause this issue.  

Das
New Around Here
Posts: 2
New Around Here

Hi,

We have SSL certificate on our site and all the requests are https. But we see that the customlink, userlinks that DNN generates (when we use tabid in navigateURL) are http.
Is there a way to make these links https?

We are looking at enabling https on our DNN 9.11.0 site. As soon as we make all pages Issecure=1 and chagne the portalsetting SSLEnabled to true , the site doesnt come up.

Please let us know the steps for changing all links to https in the website.

Thank you for all your help.

Veteran Member
Posts: 1182
Veteran Member
MVP
MVP
You're an MVP!
Posted By Das on 5/23/2023 2:16 PM

Hi,

[...] userlinks that DNN generates (when we use tabid in navigateURL) are http.
Is there a way to make these links https?

You can do that in the IIS configuration, i.e. in web.config.

First install the Url Rewriter module in IIS, and then add this rule to your web.config file:

<code> &#91;rewrite&#93;<br />    &#91;rules&#93;<br />       &#91;rule name="HTTP to HTTPS redirect" stopProcessing="true"&#93;<br />          &#91;match url="(.*)" /&#93;<br />          &#91;conditions&#93;<br />             &#91;add input="{HTTPS}" pattern="off" ignoreCase="true" /&#93;<br />          &#91;/conditions&#93;<br />          &#91;action type="Redirect" url="https://{HTTP_HOST}/{R:1}" redirectType="Permanent" /&#93;<br />       &#91;/rule&#93;<br />    &#91;/rules&#93;<br /> &#91;/rewrite&#93;<br /> </code>

(Replace [ and ] by < and >)

Happy DNNing!
Michael

 

Michael Tobisch
DNN★MVP

DNN Connect
Das
New Around Here
Posts: 2
New Around Here
Thank you for the response.

We already have the redirect at the LB level. We do render all the links as https.
We need the links to be https on the page source as well.

How to make these links (link that is created when we use tabid) use absolute URL?

Thanks
Veteran Member
Posts: 1182
Veteran Member
MVP
MVP
You're an MVP!

I don't know of a possibility to change this behaviour (maybe there is one, but I am not aware of it).

You could use a CSP (upgrade-insecure-requests) to upgrade the http-request. Also implementing HSTS could be a good idea.

Happy DNNing!
Michael

Michael Tobisch
DNN★MVP

DNN Connect
Senior Member
Posts: 1607
Senior Member
MVP
MVP
You're an MVP!
New Poster
New Poster
Congrats on posting!
Posted By Das on 5/23/2023 5:16 AM

Hi,

We have SSL certificate on our site and all the requests are https. But we see that the customlink, userlinks that DNN generates (when we use tabid in navigateURL) are http.
Is there a way to make these links https?

We are looking at enabling https on our DNN 9.11.0 site. As soon as we make all pages Issecure=1 and chagne the portalsetting SSLEnabled to true , the site doesnt come up.

Please let us know the steps for changing all links to https in the website.

Thank you for all your help.

If DNN is generating non-secure URLs for you, it's likely that either DNN isn't set to enforce SSL in the security settings, and/or there is a custom API integration that is manually generating the URLs in question.  (That is, unless there's a new bug that got introduced recently.)  

 

These Forums are for the discussion of the open source CMS DNN platform and ecosystem.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. If you have (suspected) security issues, please DO NOT post them in the forums but instead follow the official DNN security policy
  2. No Advertising. This includes the promotion of commercial and non-commercial products or services which are not directly related to DNN.
  3. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  4. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  5. No Flaming or Trolling.
  6. No Profanity, Racism, or Prejudice.
  7. Site Moderators have the final word on approving / removing a thread or post or comment.
  8. English language posting only, please.

Would you like to help us?

Awesome! Simply post in the forums using the link below and we'll get you started.

Get Involved