是否可以使用ASP.NET ScriptManager来使用Windows FIPS安全策略?
如果在 Windows中启用“使用FIPS兼容算法进行加密,散列和签名”安全策略选项,则尝试在.NET Framework中使用许多加密类将导致InvalidOperationException.默认情况下,ASP.NET使用AES加密ViewState blob,因此失败.您可以通过向web.config添加这样的键来解决此问题: <machineKey validationKey="AutoGenerate,IsolateApps" decryptionKey="AutoGenerate,IsolateApps" validation="3DES" decryption="3DES"/> 这涵盖了ASP.NET的基本用法.我的问题是:我有一个庞大,复杂的ASP.NET Web应用程序,它大量使用ScriptManagers(ASP.NET AJAX的基础),需要由必须启用此FIPS策略设置的政府客户部署.任何带有ScriptManager的ASP.NET页面都会抛出此异常: [InvalidOperationException: This implementation is not part of the Windows Platform FIPS validated cryptographic algorithms.] System.Security.Cryptography.SHA1Managed..ctor() +3607454 System.Security.Policy.Hash.get_SHA1() +45 System.Web.Handlers.ScriptResourceHandler.GetAssemblyInfoInternal(Assembly assembly) +85 System.Web.Handlers.ScriptResourceHandler.GetAssemblyInfo(Assembly assembly) +99 System.Web.Handlers.RuntimeScriptResourceHandler.GetScriptResourceUrlImpl(List`1 assemblyResourceLists,Boolean zip,Boolean notifyScriptLoaded) +525 System.Web.Handlers.RuntimeScriptResourceHandler.System.Web.Handlers.IScriptResourceHandler.GetScriptResourceUrl(List`1 assemblyResourceLists,Boolean notifyScriptLoaded) +910 System.Web.Handlers.RuntimeScriptResourceHandler.System.Web.Handlers.IScriptResourceHandler.GetScriptResourceUrl(Assembly assembly,String resourceName,CultureInfo culture,Boolean notifyScriptLoaded) +193 System.Web.UI.ScriptReference.GetUrlFromName(ScriptManager scriptManager,IControl scriptManagerControl,Boolean zip) +306 System.Web.UI.ScriptManager.RegisterUniqueScripts(List`1 uniqueScripts) +169 System.Web.UI.ScriptManager.RegisterScripts() +407 System.Web.UI.ScriptManager.OnPagePreRenderComplete(Object sender,EventArgs e) +200 System.Web.UI.Page.OnPreRenderComplete(EventArgs e) +11041982 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint,Boolean includeStagesAfterAsyncPoint) +3672 甚至添加< enforceFIPSPolicy enabled =“false”/> web.config的元素不能解决异常. 有没有办法配置ASP.NET,以便ScriptManager可以与Windows FIPS安全策略一起使用? 解决方法Microsoft的更新:此修补程序可在 http://code.msdn.microsoft.com/KB981119获得答案是您不能将ScriptManager与启用FIPS的服务器一起使用. (编辑:大庆站长网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
- asp.net-core – 具有取消令牌的自定义AspCore中间件
- asp.net-mvc – ASP.NET MVC jQueryUI datepicker在使用AJA
- Asp.net超链接控件相当于
- asp.net-mvc – 在EditorFor for child对象中使用时,MVC无法
- asp.net-mvc – 命名约定 – 控制器的一个规则,没有模型和视
- ASP.NET登录页面重定向问题
- ASP.NET Web API返回可查询的DTO?
- asp.net-mvc – 在ASP.NET MVC 4中未加载的捆绑包
- asp.net-mvc – 无法在Web服务器上启动调试.调试器无法连接
- 我如何让Fiddler捕获我的MVC应用程序向我的ASP.NET Web API
- asp.net – MVC4 – ContextDependentView – 这
- ASP.NET 清除模式窗口数据缓存的操作方式
- ASP.NET Page_Init被解雇了两次!
- asp.net-mvc-3 – 如何将复选框绑定到mvc3中的vi
- asp.net – Intranet / Internet的Windows身份验
- asp.net-mvc-3 – MVC 3不显眼的验证 – 有条件地
- Asp.Net的FileUpload类实现上传文件实例
- 发布一款层次下拉列表控件
- ASP.NET MVC与Webforms:替换WebForms控件
- asp.net-mvc-4 – .net 4.5 ASP.Net web API JSO