.net - 您可以在 .NET 应用程序中对一页进行 SSL 吗?

标签 .net iis ssl

您能否在 .NET 应用程序中有一个页面是 https,而其余页面是 http?例如,只是登录页面?这是否需要在应用程序中进行额外设置,还是与 IIS 设置一样简单?

最佳答案

是的,你可以。我推荐这个免费的开源 DLL,它可以让您指定哪些页面和文件夹需要 SSL,哪些不需要:

http://www.codeproject.com/KB/web-security/WebPageSecurity_v2.aspx

因此您可以像这样在您的 web.config 中设置一个安全的页面:

<secureWebPages encryptedUri="www.example.com" unencryptedUri="www.example.com" mode="RemoteOnly" >
    <files>
      <add path="/MustBeSecure.aspx" secure="Secure" />
    </files>
</secureWebPages>

关于.net - 您可以在 .NET 应用程序中对一页进行 SSL 吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1924119/

相关文章:

asp.net - 随机请求网站

c# - IIS Express 与 dotnet 运行

c# - 负载平衡器环境中的替代SignalR Redis实现

c# - 如何在 .NET 中修复 'Authentication to host for user using method ' mysql_native_password' failed with message : Reading from the stream has failed.'

Apache 域未指向 DocumentRoot (DigitialOcean Moodle)

.net - 我可以在 Windows 中开发 .NET 应用程序并部署适用于 Linux 和 Mac 的版本吗?

c# - 在 catch block 中返回?

mysql - 两个表之间的查询

c# - 如何使用 Linq-To-Sql 在同一查询中进行 TOP、ORDER BY 和 DISTINCT?

ssl - NGINX SSL 超时