具有 SSL 的自定义子域未重定向到 Azure cloudapp

发布于 2024-12-29 12:56:18 字数 522 浏览 2 评论 0原文

我部署了一个 Azure 应用程序,并且希望对整个应用程序使用 SSL。

为了保护我的应用程序:

-I made a subdomain in my site to point to the Azure application.
-I got a SSL in the name of my subdomain
-Add the certificate to the applicaton
-Loaded the certificate to the Azure hosted account
-Opened up a https endpoint in the application.

现在这就是问题所在。当我输入我的网址(带有子域)时,找不到该页面。但是,如果我在 URL 中手动输入 https://,它将按原样转到该网站。

这是怎么回事?我只打开了一个 https 端点。我需要一个 http 端点吗?如果我这样做,我不能让用户在没有加密的情况下使用该应用程序,那么我该如何解决这个问题?

谢谢您的帮助!

I have an Azure app deployed and I want to use SSL for the entire application.

To do secure my app:

-I made a subdomain in my site to point to the Azure application.
-I got a SSL in the name of my subdomain
-Add the certificate to the applicaton
-Loaded the certificate to the Azure hosted account
-Opened up a https endpoint in the application.

Now this is where the problem comes up. When I enter in my url (with the subdomain) the page can not be found. However, if I manually enter in https:// in the url it will go to the site as it should.

What is going on here? I have only a https endpoint open. Do I need a http endpoint to? If I do, I can't let the user use the app without an encryption, so how would I solve that?

Thank you for the help!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

十秒萌定你 2025-01-05 12:56:18

我相信这不是特定的 Azure 问题。当输入不带 https:// 的 URL 时,浏览器会自动采用 http:// 协议并预先添加它。由于您没有打开 http 端点,因此连接时会出现错误。

建议:打开http端点。在连接到 http 端点时将 URL 重定向/重写为 https。如何执行此操作取决于您用于开发站点的技术。(ASP.NET、MVC 等)

I believe that this is not a specific Azure problem. When typing in URL w/o the https://, browsers automatically assume the http:// protocol and pre-pend it. Since you did not open the http endpoint, you're getting error when connecting.

Suggestion: open the http endpoint. Redirect/rewrite the URL to https upon the connection to the http endpoint. How to do this, depends on the technology you're using to develop your site in. (ASP.NET, MVC, etc)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文