gpt4 book ai didi

java - OpenSAML 3 解码器为空

转载 作者:行者123 更新时间:2023-11-29 04:37:49 30 4
gpt4 key购买 nike

您好,我目前正在将应用程序移植到 opensaml3 并遇到以下问题:

InitializationService.initialize();
...
Unmarshaller unmarshaller = Configuration.getUnmarshallerFactory().getUnmarshaller(qName);

我已经用初始化函数替换了 opensaml2 和之前的 DefaultBootstrap。工厂仍然将我作为编码器返回 null。知道这里出了什么问题吗?

这是初始化进度的输出:

[main] INFO org.opensaml.core.config.InitializationService - Initializing OpenSAML using the Java Services API
[main] INFO org.opensaml.xmlsec.algorithm.AlgorithmRegistry - Algorithm failed runtime support check, will not be usable: http://www.w3.org/2001/04/xmlenc#ripemd160
[main] INFO org.opensaml.xmlsec.algorithm.AlgorithmRegistry - Algorithm failed runtime support check, will not be usable: http://www.w3.org/2001/04/xmldsig-more#hmac-ripemd160
[main] INFO org.opensaml.xmlsec.algorithm.AlgorithmRegistry - Algorithm failed runtime support check, will not be usable: http://www.w3.org/2001/04/xmldsig-more#rsa-ripemd160

最佳答案

我想您使用的是 opensaml v3所以你应该像这样用 XMLObjectProviderRegistrySupport 类创建 UnmarshallerFactory 对象,它工作得很好

UnmarshallerFactory umFactory=XMLObjectProviderRegistrySupport.getUnmarshallerFactory();
Unmarshaller unmarshaller=umFactory.getUnmarshaller(element);

关于java - OpenSAML 3 解码器为空,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40508448/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com