microsoft-information-protection - Microsoft 信息保护 SDK 1.7.133 - 加载库失败问题错误
问题描述
我之前使用的是 MIP SDK 1.6,我通过提供 Path 来初始化 MIP。它工作正常。我升级到 1.7 版本,现在它因 Load library failed 错误而失败。
{"Message":"发生错误。","ExceptionMessage":"LoadLibrary failed for: [C:\inetpub\wwwroot\teststs\bin\x64\mip_dotnet.dll]", "ExceptionType":"System.ComponentModel .Win32Exception","StackTrace":" 在 Microsoft.InformationProtection.Utils.SafeNativeMethods.LoadLibrary(String dllToLoad)\r\n 在 Microsoft.InformationProtection.Utils.Loader.LoadDlls(String dllFolder, String dllName, String[] dllDependencies)\ r\n 在 Microsoft.InformationProtection.MIP.Initialize(MipComponent mipComponent, 字符串路径)\r\n
有人可以帮忙吗?
解决方案
你能分享一下你是如何构建路径并在 MipContext 中设置它的吗?像这样的东西应该仍然有效。我已经在 MIP SDK 1.7.133 上的 .NET 项目中对此进行了测试。
// Set path to bins folder.
var path = Path.Combine(
Directory.GetParent(Path.GetDirectoryName(new Uri(System.Reflection.Assembly.GetExecutingAssembly().CodeBase).LocalPath)).FullName,
Environment.Is64BitProcess ? "bin\\x64" : "bin\\x86");
// Initialize MIP for File API.
MIP.Initialize(MipComponent.File, path);
推荐阅读
- java - 为什么 Object 和 var 变量的行为不同?
- javascript - Electron - 有没有办法在生产计算机上生成一个没有节点的节点子进程?
- list - 如何在haskell中创建一个函数,该函数接受一个单词并从列表列表中搜索它
- kubernetes - 是否可以防止 ReplicaSet 放大/缩小?
- javascript - 从 Render 中的循环中获取变量到 ReactJS 中的 componentDidMount() 并将此变量放入查询参数中
- python - 使用预建模板创建 python 注册
- mysql - Laravel MySql Connection 连接太多的问题
- javascript - 编辑图例标签 [vue-chart.js]
- objective-c - 类“IGListSectionController”的重复接口定义
- html - 制作一面旗帜和百分比