相关疑难解决方法(0)

X-Frame-Options允许来自多个域

我有一个asp.net 4.0 IIS7.5站点,我需要使用x-frame headers选项进行保护

我还需要启用我的网站页面来自我的同一个域以及我的Facebook应用程序.

目前,我的网站配置了以下网站:

Response.Headers.Add("X-Frame-Options", "ALLOW-FROM SAMEDOMAIN, www.facebook.com/MyFBSite")
Run Code Online (Sandbox Code Playgroud)

当我用Chrome或FireFox查看我的Facebook页面时,我的网站页面(与我的Facebook页面一起被设置)显示正常,但在IE9下,我收到错误

"此页面无法显示......"(因为X-Frame_Options限制).

如何设置X-Frame-Options: ALLOW-FROM支持多个域?

X-FRAME-OPTION 如果只能定义一个域,那么作为一个新功能似乎存在根本缺陷.

asp.net security iis-7 header internet-explorer-9

89
推荐指数
4
解决办法
14万
查看次数

如何在asp.net中检测新的Microsoft浏览器"Edge"

在asp.net中,使用这个结构,我如何检测新的Microsoft"Edge"浏览器?

    Dim wrkBrowser As String = ""
    Dim wrkBrowserType As String = HttpContext.Current.Request.Browser.Type
    If InStr(wrkBrowserType, "Chrome") <> 0 Then
        wrkBrowser = "Chrome"
    End If
    If InStr(wrkBrowserType, "MSIE") <> 0 Then
        wrkBrowser = "IE"
    End If
    If InStr(wrkBrowserType, "FireFox") <> 0 Then
        wrkBrowser = "FF"
    End If
Run Code Online (Sandbox Code Playgroud)

browser asp.net

2
推荐指数
2
解决办法
9177
查看次数

标签 统计

asp.net ×2

browser ×1

header ×1

iis-7 ×1

internet-explorer-9 ×1

security ×1