Stuck with ssl and IIS10 reverse proxy

Need help? Post your questions here.

Moderator: moderators

Stuck with ssl and IIS10 reverse proxy

Postby davi2d » Fri Mar 02, 2018 10:00 am

Hello everyone.

I'm using my own material.
I'm also using subsonic.
I'd like to have a valid SSL certificate.
That's why I'm using let'sencrypt - certify application.

I read a lot of websites : tutorial on this forum (http://forum.subsonic.org/forum/viewtopic.php?f=6&t=17464, website with IIS redirect informations, .... but I only get error messages : too many redirect or cgi erreur or I get nothing.

Here are the details :
- OS : Windows Server 2016
- IIS : 10.0.14393.0 + ARR + rewrite module
- Subsonic : 6.0 (build 830afc) – 30 avril 2016
- jetty-6.1.x, java 1.8.0_161

What I did :

- in IIS, I set up my website : mywebsite.com with 80 and 443 port.
- I certified this website with letsencrypt.
- then in rewrite module i set up : ReverseProxyInboudRule1, match : (.*), rewrite to https://localhost:4443/{R:0}
=> I tried with R:0 or with R:1

Here is my web.config file :

Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <rewrite>
            <rules>
                <rule name="ReverseProxyInboundRule1" stopProcessing="true">
                    <match url="(.*)" />
                    <conditions>
                    </conditions>
                    <action type="Rewrite" url="https://localhost:4443/{R:1}" />
                </rule>
            </rules>
            <outboundRules>
                <rule name="ReverseProxyOutboundRule1" preCondition="ResponseIsHtml1">
                    <match filterByTags="A, Form, Img" pattern="^http(s)?://https://localhost:4443/(.*)" />
                    <action type="Rewrite" value="http{R:1}://mywebsite.com/{R:2}" />
                </rule>
                <preConditions>
                    <preCondition name="ResponseIsHtml1">
                        <add input="{RESPONSE_CONTENT_TYPE}" pattern="^text/html" />
                    </preCondition>
                </preConditions>
            </outboundRules>
        </rewrite>
    </system.webServer>
</configuration>


Does anyone could tell me where i'm doing wrong ? Thank you
davi2d
 
Posts: 1
Joined: Wed Feb 28, 2018 12:49 pm

Return to Help

Who is online

Users browsing this forum: No registered users and 11 guests