重定向到多个域之间的HTTPS
我有两个域名(例如domainone.com和domaintwo.com),它们指向一个网站。 我有一个用于domainone.com的ssl证书 我想为domainone.com自动重定向到https。 我不想为domaintwo.com自动重定向到https,因为我没有此domaintwo.com的ssl证书。我只想用http打开它 url重写(IIS)中的规则如下所示重定向到多个域之间的HTTPS,https,url-rewriting,iis-7.5,Https,Url Rewriting,Iis 7.5,我有两个域名(例如domainone.com和domaintwo.com),它们指向一个网站。 我有一个用于domainone.com的ssl证书 我想为domainone.com自动重定向到https。 我不想为domaintwo.com自动重定向到https,因为我没有此domaintwo.com的ssl证书。我只想用http打开它 url重写(IIS)中的规则如下所示 Match URL – Requested URL: Matches the Pattern Match URL – Us
Match URL – Requested URL: Matches the Pattern
Match URL – Using: Regular Expression
Pattern: (.*)
Condition Input: {HTTPS}
Check if input string: Matches the Pattern
Pattern: ^OFF$
Action type: Redirect
Redirect URL: https://{HTTP_HOST}/{R:1}
Redirect type: See Other (303)
现在两个域名都自动重定向到https。请帮助我如何只为domainone.com自动重定向到https
多谢各位 我添加了一个条件。现在它正按我所希望的那样工作
Match URL – Requested URL: Matches the Pattern
Match URL – Using: Regular Expression
Pattern: (.*)
Condition Input: {HTTPS}
Check if input string: Matches the Pattern
Pattern: ^OFF$
Condition Input: {HTTP_HOST}
Check if input string: Matches the Pattern
Pattern: domainone.com
Action type: Redirect
Redirect URL: https://{HTTP_HOST}/{R:1}
Redirect type: See Other (303)
我增加了一个条件。现在它正按我所希望的那样工作
Match URL – Requested URL: Matches the Pattern
Match URL – Using: Regular Expression
Pattern: (.*)
Condition Input: {HTTPS}
Check if input string: Matches the Pattern
Pattern: ^OFF$
Condition Input: {HTTP_HOST}
Check if input string: Matches the Pattern
Pattern: domainone.com
Action type: Redirect
Redirect URL: https://{HTTP_HOST}/{R:1}
Redirect type: See Other (303)