大网数据广告活动
网站运营与故障问答

IIS 10 giving internal error when attempting to redirect to HTTPS

· 52CE 我爱测

I've looked at innumerable resources on how to set up a HTTP to HTTPS Redirect, but still it doesn't seem to work. Using IIS10 and the URL Rewrite module, here are my steps: I've generated a Self-Signed SSL Cert (this part is sel…

问题原文

原帖链接 · Maclain Anderson · CC BY-SA 4.0

I've looked at innumerable resources on how to set up a HTTP to HTTPS Redirect, but still it doesn't seem to work. Using IIS10 and the URL Rewrite module, here are my steps:

  1. I've generated a Self-Signed SSL Cert (this part is self-explanatory and I feel like it doesn't need attention)
  2. I've added a new binding to port 443 for HTTPS and told it to use the cert generated in step 1.
  3. I've set my rules as in the picture below.

Browsing to that page gives the generic IIS 'internal error' message. IIS logs say it's a 404 error when trying to access the IP at the default port 80. Going directly to port 443 works fine, it just won't automatically redirect. I'm not really sure what I'm doing wrong here.

It may be worth considering that I'm using PHP, but I don't think that affects anything in this case.

已采纳解答

原帖链接 · Maclain Anderson · CC BY-SA 4.0

The problem appears to be fixed. My only issue was making it a rewrite instead of a redirect, which Stephen Ostermiller helpfully pointed out are two completely different things.

Though I could swear this wasn't the case not two hours ago, it appears to be working fine now. Closing this out when the site allows me to.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Webmasters Stack Exchange
适用范围
以原帖系统、软件版本与发布日期为准(2018-11-16)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。