问题描述
我正在尝试在 Java SpringMVC 框架中设置 SAML。
基本上,每当我尝试访问服务提供商 (http://baseaddress/context/saml/Metadata
) 或触发单点登录(应该重定向到身份提供商)时,我都会收到异常:java.lang.IllegalArgumentException: Manager with name 'MetadataKeyInfoGenerator' does not exist
。如果我使用 ResourceBackedMetadataProvider
,它会起作用。
<!-- IDP Metadata configuration - paths to Metadata of IDPs in circle of trust is here -->
<bean id="Metadata" class="org.springframework.security.saml.Metadata.CachingMetadataManager">
<constructor-arg>
<list>
<bean class="org.springframework.security.saml.Metadata.ExtendedMetadataDelegate">
<property name="MetadataTrustCheck" value="false" />
<property name="MetadataRequireSignature" value ="false" />
<constructor-arg>
<bean class="org.opensaml.saml2.Metadata.provider.HTTPMetadataProvider">
<constructor-arg>
<value type="java.lang.String">http://localhost:8088/Metadata</value>
</constructor-arg>
<constructor-arg>
<value type="int">15000</value>
</constructor-arg>
<property name="parserPool" ref="parserPool"/>
</bean>
</constructor-arg>
<constructor-arg>
<bean class="org.springframework.security.saml.Metadata.ExtendedMetadata"/>
</constructor-arg>
</bean>
</list>
</constructor-arg>
<!-- OPTIONAL used when one of the Metadata files contains information about this service provider -->
<!-- <property name="hostedSPName" value=""/> -->
<!-- OPTIONAL property: can tell the system which IDP should be used for authenticating user by default. -->
<!-- <property name="defaultIDP" value="http://localhost:8080/opensso"/> -->
</bean>
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)