1

We are having an application server , we need to host .Net Web api with secure HTTPS link on port 443 using IIS , also a front application (using JAVA) in Tomcat with secured HTTPS link on same 443 port.

We deployed Java front end in tomcat with 443 port but now when tried to start a site in IIS on same port 443 it is not starting since port already in use.

So what steps can be taken so that we will have two different application hosted in IIS and Tomcat with using same 443 port.

Olaf Kock
  • 46,930
  • 8
  • 59
  • 90
Sagar Shirke
  • 648
  • 9
  • 32

3 Answers3

2

Deploy a reverse proxy server(Nginx, Apache or else) with port 443 , IIS and Tomcat use other port. Config the proxy server to proxy the traffic of IIS and Tomcat.

Ten Du
  • 21
  • 3
  • By using reverse proxy server, will user be able to open two different sites (with no commonality in URL) like "https://example.com/login" and "https://dummy.com/login" ? – Sagar Shirke Jul 11 '22 at 14:45
  • If you don't know yet, IIS itself can be that reverse proxy. – Lex Li Jul 11 '22 at 20:53
2

First, let IIS be the web server that takes all traffic.

Second, configure all your sites on IIS at port 443. SNI support in IIS 8+ allows you to host multiple HTTPS sites on the same machine,

https://learn.microsoft.com/en-us/iis/get-started/whats-new-in-iis-8/iis-80-server-name-indication-sni-ssl-scalability

Third, if one of the sites is Java/Tomcat based, use HttpPlatformHandler to forward its traffic to Tomcat (let IIS control which port Tomcat should use),

https://stackoverflow.com/tags/httpplatformhandler/info

Lex Li
  • 60,503
  • 9
  • 116
  • 147
1

You can configure a reverse proxy for IIS, use port 443 as the traffic forwarding port, and set the two different applications to other ports. Because IIS is used as a reverse proxy server, you can use port 443 to forward to by creating a rewrite rule. on two other different application ports.

you can look at this: Proxy IIS Server to Tomcat Application

JennyDai
  • 214
  • 1
  • 5