You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by pchakinala <pr...@planetsoft.com> on 2011/04/14 18:05:05 UTC
SAML Token :org.opensaml.MalformedException: NameIdentifier is
invalid, requires name
Hi,
We are working SAML Token approach to implement security and used cxfbc
provider component.i found below exception when request has posted rom
client.
http client --> http consumer ---> cxf bc provider --->call webservice
Exception:
java.lang.RuntimeException: org.opensaml.MalformedException: NameIdentifier
is invalid, requires name
at
org.apache.ws.security.message.WSSecSAMLToken.prependToHeader(WSSecSAMLToken.java:82)[113:org.apache.ws.security.wss4j:1.5.9]
at
org.apache.ws.security.message.WSSecSAMLToken.build(WSSecSAMLToken.java:117)[113:org.apache.ws.security.wss4j:1.5.9]
at
org.apache.ws.security.action.SAMLTokenUnsignedAction.execute(SAMLTokenUnsignedAction.java:42)[113:org.apache.ws.security.wss4j:1.5.9]
at
org.apache.ws.security.handler.WSHandler.doSenderAction(WSHandler.java:205)[113:org.apache.ws.security.wss4j:1.5.9]
at
org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor.access$200(WSS4JOutInterceptor.java:50)[116:org.apache.cxf.bundle:2.3.2]
at
org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor$WSS4JOutInterceptorInternal.handleMessage(WSS4JOutInterceptor.java:257)[116:org.apache.cxf.bundle:2.3.2]
at
org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor$WSS4JOutInterceptorInternal.handleMessage(WSS4JOutInterceptor.java:134)[116:org.apache.cxf.bundle:2.3.2]
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:255)[116:org.apache.cxf.bundle:2.3.2]
at
org.apache.servicemix.cxfbc.CxfBcProvider.process(CxfBcProvider.java:247)[156:servicemix-cxf-bc:2011.01.0]
at
org.apache.servicemix.common.AsyncBaseLifeCycle.doProcess(AsyncBaseLifeCycle.java:651)[121:servicemix-common:2011.01.0]
at
org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:606)[121:servicemix-common:2011.01.0]
at
org.apache.servicemix.common.AsyncBaseLifeCycle.processExchangeInTx(AsyncBaseLifeCycle.java:501)[121:servicemix-common:2011.01.0]
at
org.apache.servicemix.common.AsyncBaseLifeCycle$2.run(AsyncBaseLifeCycle.java:370)[121:servicemix-common:2011.01.0]
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)[:1.6.0_24]
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)[:1.6.0_24]
at java.lang.Thread.run(Thread.java:662)[:1.6.0_24]
Caused by: org.opensaml.MalformedException: NameIdentifier is invalid,
requires name
at org.opensaml.SAMLNameIdentifier.checkValidity(Unknown
Source)[114:org.apache.servicemix.bundles.opensaml:1.1.0.5]
at org.opensaml.SAMLObject.toDOM(Unknown
Source)[114:org.apache.servicemix.bundles.opensaml:1.1.0.5]
at org.opensaml.SAMLNameIdentifier.toDOM(Unknown
Source)[114:org.apache.servicemix.bundles.opensaml:1.1.0.5]
at org.opensaml.SAMLSubject.toDOM(Unknown
Source)[114:org.apache.servicemix.bundles.opensaml:1.1.0.5]
at org.opensaml.SAMLSubjectStatement.toDOM(Unknown
Source)[114:org.apache.servicemix.bundles.opensaml:1.1.0.5]
at org.opensaml.SAMLAuthenticationStatement.toDOM(Unknown
Source)[114:org.apache.servicemix.bundles.opensaml:1.1.0.5]
at org.opensaml.SAMLAssertion.toDOM(Unknown
Source)[114:org.apache.servicemix.bundles.opensaml:1.1.0.5]
at org.opensaml.SAMLObject.toDOM(Unknown
Source)[114:org.apache.servicemix.bundles.opensaml:1.1.0.5]
at
CXF BC Provider configuration :
-----------------------------
passwordCallbackRef
keytool batch file:
--------------------
keytool batch file for certificate generation:
keytool -genkey -alias myAlias -keypass myAliasPassword -keystore
privatestore.jks -storepass keyStorePassword -dname "cn=myAlias,OU=MYOU,
O=MYORG, L=MYCITY, ST=MYSTATE, C=MY" -keyalg RSA
keytool -selfcert -alias myAlias -keystore privatestore.jks -storepass
keyStorePassword -keypass myAliasPassword
keytool -export -alias myAlias -file key.rsa -keystore privatestore.jks
-storepass keyStorePassword
keytool -import -alias myAlias -file key.rsa -keystore publicstore.jks
-storepass keyStorePassword
Why it is throwing NameIdentifier is invalid exception? Have i need to
change any configuration to fix the issue. Here atatched saml config files
for your reference.
Regards,
Praveen Chakinala
http://servicemix.396122.n5.nabble.com/file/n4303405/config.zip config.zip
--
View this message in context: http://servicemix.396122.n5.nabble.com/SAML-Token-org-opensaml-MalformedException-NameIdentifier-is-invalid-requires-name-tp4303405p4303405.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.