c# - System.Xml.XmlException 此 XML 文档中禁止 DTD 异常
问题描述
我正在尝试通过 ADFS 进行 SSO,同时通过IDpSsoDescriptor
. 我面临的问题:
System.Xml.XmlException HResult=0x80131940 Message=出于安全原因,此 XML 文档中禁止使用 DTD。要启用 DTD 处理,请将 XmlReaderSettings 上的 DtdProcessing 属性设置为 Parse 并将设置传递给 XmlReader.Create 方法。来源=ITfoxtec.Identity.Saml2 StackTrace:
我努力了:
XmlReaderSettings settings = new XmlReaderSettings();
settings.DtdProcessing = DtdProcessing.Parse;
但无法在dll
.
解决方案
推荐阅读
- terraform - 通过 Terraform 为 Azure 应用服务(Web 应用)设置 VNet 集成
- spring - 回滚内部事务影响hibernate spring中的外部事务
- html - 移动和桌面的不同“grid-template-columns”值
- kubernetes - 从 kubernetes 获取“无法列出资源“pods/var””
- reactjs - 如何在 nextjs 应用程序中强制使用 HTTPS 而无需创建自定义服务器
- azure-devops - 在 Azure Dev Ops 中从 Git 迁移到 TFVC
- node.js - 更改 node-sass 的版本以允许 grunt 构建正常完成
- excel - 根据单元格值合并范围内的单元格,但最后一个单元格没有被合并
- python - 离散值的指数衰减
- reactjs - 如何循环遍历对象数组并一一展示单独的 HTML 元素