简体   繁体   中英

best way to redirect securely one domain to another in IIS without having a website

I would like to know what is the best way to redirect everything from marketing-address.com to real-address.com.

best means

  • as less effort as possible,
  • as cheap as possible,
  • as secure as possible.

In detail:

  • Less effort : If possible without the need of creating a website oder some code like javascript
  • Secure : https://marketing-address.com should be accpeted by the browsers - no warning.
  • Cheap : if possible without buying a certificate (I don't think that this is possible) and without having a second webserver running

So in theory, the communication would be like this:

  • Making the address targeting the same IP address
  • Making the existing IIS listen to that address to
  • Let IIS tell the caller "yes, you're totally right here, but I neither I have a website nor do I have a certificate, but you don't need anything of that since you get redirected anyway..."

Is there a chance to accomplish that? If no, I would need to buy a certificate. What would be the solution then?

There are 2 restrictions :

  1. We are using an Azure App Service for hosting an asp.net core site, which seems to be very restricted in configuration possibilities
  2. The browser should definetly show the real-address.com in the URL, not the marketing-address.com.

Have you tried to use an Application Gateway before the IIS/Webapp at the backend?

I believe the AppGW will solve these issues, the AppGW can redirect the hostname to another web address, as many you want to.

https://docs.microsoft.com/en-us/azure/application-gateway/ssl-overview#tls-termination

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM