Сайт доступа IIS без порта

Существует mod_ntlm и mod_auth_sspi. Вы могли попробовать любое из этого.

PS: Ваш старый вопрос в stackoverflow не был удален. его перемещенный здесь.

2
задан 7 March 2016 в 02:32
3 ответа

Когда вы вводите URL без порта, подразумевается порт 80.

Ни один из известных мне браузеров не может изменить это поведение; если вы хотите использовать порт 3333, он вам понадобится в URL.

7
ответ дан 3 December 2019 в 08:48

You can use Reverse Proxy to silently redirect all HTTP requests to another port. Obviously, there still should be a site bound to TCP port 80 (that is the port which is used when no specific port is specified), which you will configure to make such redirect to another port.

It is possible with IIS 7 + URL Rewrite module + Application Request Routing (or IIS 7 + Helicon Ape if you prefer Apache-style configuration).

Question is -- if you can bind a site to port 80, why would you need to run it on port 3333 then?

1
ответ дан 3 December 2019 в 08:48

When you assign an IIS site to a TCP port, the IIS process actually binds to the TCP port. This means that any connection (less filtering at the stack level, example: software firewall) incoming on that TCP port is serviced by this IIS site instance.

What you could do is:

  1. Create a CNAME for the FQDN you wish destined for the server for which the site is hosted (if it's on the same server, okay).
  2. Create an IIS site to bind to port 80.
  3. In the site properties, on the Web Site tab, next to IP address, click Advanced. Change the host header value to the FQDN.
  4. Then, in the site properties, on the Home Directory tab, redirect to the url: http://CNAME:[bound port]

For instance, a user hits: http://redmine

  1. CNAME for redmine is 192.168.10.101 (WEBSERVER2).
  2. Their browser then connects to 192.168.10.101:80 (this is the default TCP HTTP port, all browsers will hit this port unless specified otherwise).
  3. The IIS site serving out 192.168.10.101:80 has the rule to inspect the Host Header for the source NAME hit... matches, okay... perform redirection rule.
  4. Redirection rule redirects the user's browser to http://redmine:8080

All the user did was hit http://redmine

This obviously allows you to host multiple sites on a single box. "Virtual host" if you will.

1
ответ дан 3 December 2019 в 08:48

Теги

Похожие вопросы