cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nullpointer Forever (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CXF-6247) The signature or decryption was invalid
Date Tue, 10 Feb 2015 11:09:35 GMT

    [ https://issues.apache.org/jira/browse/CXF-6247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14314020#comment-14314020
] 

Nullpointer Forever commented on CXF-6247:
------------------------------------------

There is something wrong with digest?

{quote}
...
11:55:25 DEBUG XML Signature verification has failed
11:55:25 DEBUG Signature Validation check: false
11:55:25 DEBUG URIDereferencer class name: org.apache.jcp.xml.dsig.internal.dom.DOMURIDereferencer
11:55:25 DEBUG Data class name: org.apache.jcp.xml.dsig.internal.dom.ApacheNodeSetData
11:55:25 DEBUG Create URI "http://www.w3.org/2001/10/xml-exc-c14n#" class "class org.apache.xml.security.transforms.implementations.TransformC14NExclusive"
11:55:25 DEBUG The NodeList is [ds:Transform: null]
11:55:25 DEBUG setElement(ds:Transform, "null"
11:55:25 DEBUG Created transform for algorithm: http://www.w3.org/2001/10/xml-exc-c14n#
11:55:25 DEBUG ApacheData = true
11:55:25 DEBUG setElement("ec:InclusiveNamespaces", "null")
11:55:25 DEBUG Pre-digested input:
11:55:25 DEBUG <wsu:Timestamp xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
wsu:Id="TS-D7E2EF5879BAA43C9B14235657224041"><wsu:Created>2015-02-10T10:55:22.397Z</wsu:Created><wsu:Expires>2015-02-10T11:00:22.397Z</wsu:Expires></wsu:Timestamp>
11:55:25 DEBUG Expected digest: wt4kvlA+qObmRCp23yGxqNarjJA=
11:55:25 DEBUG Actual digest: wt4kvlA+qObmRCp23yGxqNarjJA=
11:55:25 DEBUG Reference #TS-D7E2EF5879BAA43C9B14235657224041 check: true
11:55:25 DEBUG URIDereferencer class name: org.apache.jcp.xml.dsig.internal.dom.DOMURIDereferencer
11:55:25 DEBUG Data class name: org.apache.jcp.xml.dsig.internal.dom.ApacheNodeSetData
11:55:25 DEBUG Create URI "http://www.w3.org/2001/10/xml-exc-c14n#" class "class org.apache.xml.security.transforms.implementations.TransformC14NExclusive"
11:55:25 DEBUG The NodeList is [ds:Transform: null]
11:55:25 DEBUG setElement(ds:Transform, "null"
11:55:25 DEBUG Created transform for algorithm: http://www.w3.org/2001/10/xml-exc-c14n#
11:55:25 DEBUG ApacheData = true
11:55:25 DEBUG setElement("ec:InclusiveNamespaces", "null")
11:55:25 DEBUG Pre-digested input:

...

11:55:25 DEBUG Expected digest: He+N5jlDMcbZ1C4ZNpGYMkCiNd0=
11:55:25 DEBUG Actual digest: KfDzbYM7lTFUw0EtB22qjoJ5vBU=
11:55:25 DEBUG Reference #id-D7E2EF5879BAA43C9B14235657224315 check: false
11:55:25 DEBUG Invoking handleFault on interceptor org.apache.cxf.ws.security.wss4j.WSS4JInInterceptor@1e5abac6
11:55:25 DEBUG Invoking handleFault on interceptor org.apache.cxf.binding.soap.interceptor.StartBodyInterceptor@7a4f8ca1
11:55:25 DEBUG Invoking handleFault on interceptor org.apache.cxf.binding.soap.interceptor.SoapActionInInterceptor@338df84c
11:55:25 DEBUG Invoking handleFault on interceptor org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor@3b72fd3c
11:55:25 DEBUG Invoking handleFault on interceptor org.apache.cxf.frontend.WSDLGetInterceptor@3f406ba3
11:55:25 DEBUG Invoking handleFault on interceptor org.apache.cxf.interceptor.StaxInInterceptor@adef49f
11:55:25 DEBUG Invoking handleFault on interceptor org.apache.cxf.transport.https.CertConstraintsInterceptor@68967f33
11:55:25 DEBUG Invoking handleFault on interceptor org.apache.cxf.interceptor.AttachmentInInterceptor@273cd569
11:55:25 DEBUG Invoking handleFault on interceptor org.apache.cxf.ws.policy.PolicyInInterceptor@32d670ed
11:55:25  WARN Interceptor for {http://localhost}WsService has thrown exception, unwinding
now
org.apache.cxf.binding.soap.SoapFault: The signature or decryption was invalid
...
{quote}

> The signature or decryption was invalid
> ---------------------------------------
>
>                 Key: CXF-6247
>                 URL: https://issues.apache.org/jira/browse/CXF-6247
>             Project: CXF
>          Issue Type: Bug
>          Components: JAX-WS Runtime, WS-* Components
>    Affects Versions: 3.0.3
>         Environment: JDK 1.7.0_55
> Windows 8.0
>            Reporter: Nullpointer Forever
>
> When I connect my client to service with CXF 3.0.3 I get in service:
> {quote}
> Exception in thread "main" javax.xml.ws.soap.SOAPFaultException: The signature or decryption
was invalid
> 	at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:158)
> 	...
> Caused by: org.apache.cxf.binding.soap.SoapFault: The signature or decryption was invalid
> 	at org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.unmarshalFault(Soap11FaultInInterceptor.java:84)
> 	at org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.handleMessage(Soap11FaultInInterceptor.java:51)
> 	at org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.handleMessage(Soap11FaultInInterceptor.java:40)
> 	at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:272)
> 	at org.apache.cxf.interceptor.AbstractFaultChainInitiatorObserver.onMessage(AbstractFaultChainInitiatorObserver.java:113)
> 	at org.apache.cxf.binding.soap.interceptor.CheckFaultInterceptor.handleMessage(CheckFaultInterceptor.java:69)
> 	at org.apache.cxf.binding.soap.interceptor.CheckFaultInterceptor.handleMessage(CheckFaultInterceptor.java:34)
> 	at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:272)
> 	at org.apache.cxf.endpoint.ClientImpl.onMessage(ClientImpl.java:849)
> 	at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:1626)
> 	at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1515)
> 	at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1318)
> 	at org.apache.cxf.io.CacheAndWriteOutputStream.postClose(CacheAndWriteOutputStream.java:56)
> 	at org.apache.cxf.io.CachedOutputStream.close(CachedOutputStream.java:223)
> 	at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:56)
> 	at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:632)
> 	at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62)
> 	at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:272)
> 	at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:572)
> 	at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:481)
> 	at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:382)
> 	at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:335)
> 	at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:96)
> 	at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:136)
> 	... 3 more
> {quote}
> Config:
> {code:xml}
> <?xml version="1.0" encoding="UTF-8"?>
> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:jaxws="http://cxf.apache.org/jaxws" xmlns:soap="http://cxf.apache.org/bindings/soap"
xmlns:cxf="http://cxf.apache.org/core" xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.0.xsd http://cxf.apache.org/jaxws
http://cxf.apache.org/schemas/jaxws.xsd http://cxf.apache.org/core http://cxf.apache.org/schemas/core.xsd
http://cxf.apache.org/bindings/soap http://cxf.apache.org/schemas/configuration/soap.xsd">
> 	
> 	<import resource="classpath:META-INF/cxf/cxf.xml" />
> 	
> 	<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
> 	
> 	<jaxws:endpoint implementor="#myWs" address="/services/WS" >
> 		<jaxws:inInterceptors>
> 			<ref bean="RequestInterceptor"/>
> 			<bean class="org.apache.cxf.ws.security.wss4j.DefaultCryptoCoverageChecker"/>
> 		</jaxws:inInterceptors>
> 	</jaxws:endpoint>
> 	
> 	<bean id="RequestInterceptor" class="org.apache.cxf.ws.security.wss4j.WSS4JInInterceptor">
> 		<constructor-arg>
> 			<map>
> 				<entry key="action" value="Timestamp Signature Encrypt"/>
> 				<entry key="signaturePropFile" value="myKeystore.properties"/>
> 				<entry key="decryptionPropFile" value="myKeystore.properties"/>
> 				<entry key="passwordCallbackClass" value="MyCallback"/>
> 				<entry key="encryptionKeyTransportAlgorithm" value="http://www.w3.org/2001/04/xmlenc#rsa-oaep-mgf1p"/>
> 				<entry key="signatureAlgorithm" value="http://www.w3.org/2000/09/xmldsig#rsa-sha1"/>
> 			</map>
> 		</constructor-arg>
> 	</bean>
> 	
> 	<bean id="logInbound" class="org.apache.cxf.interceptor.LoggingInInterceptor" />
> 	
> 	<bean id="logOutbound" class="org.apache.cxf.interceptor.LoggingOutInterceptor" />
> 	
> 	<cxf:bus>
> 		<cxf:outFaultInterceptors>
> 			<ref bean="logOutbound" />
> 		</cxf:outFaultInterceptors>
> 		<cxf:inFaultInterceptors>
> 			<ref bean="logInbound" />
> 		</cxf:inFaultInterceptors>
> 	</cxf:bus>
> 	
> </beans>
> {code}
> Maven dependencies:
> {code:xml}
> <dependencies>
> 	<dependency>
> 		<groupId>commons-codec</groupId>
> 		<artifactId>commons-codec</artifactId>
> 	</dependency>
> 	<dependency>
> 		<groupId>javax.servlet</groupId>
> 		<artifactId>servlet-api</artifactId>
> 		<scope>provided</scope>
> 	</dependency>
> 	<dependency>
> 		<groupId>bouncycastle</groupId>
> 		<artifactId>bcprov-jdk16</artifactId>
> 		<version>140</version>
> 	</dependency>
> 	<dependency>
> 			<groupId>com.sun.xml.bind</groupId>
> 			<artifactId>jaxb-impl</artifactId>
> 		</dependency>
> 	<dependency>
> 		<groupId>net.sf.json-lib</groupId>
> 		<artifactId>json-lib</artifactId>
> 		<classifier>jdk15</classifier>
> 	</dependency>
> 	<dependency>
> 		<groupId>org.apache.commons</groupId>
> 		<artifactId>commons-dbcp2</artifactId>
> 	</dependency>
> 	<dependency>
> 		<groupId>org.apache.cxf</groupId>
> 		<artifactId>cxf-rt-frontend-jaxws</artifactId>
> 	</dependency>
> 	<dependency>
> 		<groupId>org.apache.cxf</groupId>
> 		<artifactId>cxf-rt-transports-http</artifactId>
> 	</dependency>
> 	<dependency>
> 		<groupId>org.apache.cxf</groupId>
> 		<artifactId>cxf-rt-ws-security</artifactId>
> 	</dependency>
> 	<dependency>
> 		<groupId>org.springframework</groupId>
> 		<artifactId>spring-web</artifactId>
> 	</dependency>
> 	<dependency>
> 		<groupId>xom</groupId>
> 		<artifactId>xom</artifactId>
> 	</dependency>
> </dependencies>
> {code}
> Changing only CXF to ver. 2.7.14 resolve problem. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message