Is there a workaround at this time for Jira "CXF-1538"
(https://issues.apache.org/jira/browse/CXF-1538
<https://issues.apache.org/jira/browse/CXF-1538> )?
We are hitting against this bug while trying to send signed SOAP
messages over HTTPS.
We understand that this is an open Jira, but we would like to understand
more about what is going on, so that we can find a workaround.
Why is this interceptor in the chain? What function does it provide?
Can we remove it from the chain? Can we replace it in the chain by our
own implementation?
If we were to implement a replacement, what should that replacement do?
Use an XMLStreamWriter?
Our interceptor chain is the following:
Chain [EMAIL PROTECTED] Current flow:
pre-logical [HolderOutInterceptor, SwAOutInterceptor,
WrapperClassOutInterceptor, SoapHeaderOutFilterInterceptor]
post-logical [SoapActionOutInterceptor]
prepare-send [MessageSenderInterceptor]
pre-stream [MSXMLStreamOutInterceptor, LoggingOutInterceptor,
SoapPreProtocolOutInterceptor, AttachmentOutInterceptor]
pre-protocol [SAAJOutInterceptor, SOAPHandlerInterceptor]
write [SoapOutInterceptor]
pre-marshal [LogicalHandlerOutInterceptor]
marshal [BareOutInterceptor]
post-protocol [WSS4JOutInterceptor]
write-ending [SoapOutEndingInterceptor]
pre-protocol-ending [SAAJOutEndingInterceptor]
prepare-send-ending [MessageFlushInterceptor,
MessageSenderEndingInterceptor]
The code which presents the problem (Jira CXF-1538):
SAAJOutInterceptor.java
public void handleMessage(SoapMessage message) throws Fault {
SOAPMessage soapMessage =
message.getContent(SOAPMessage.class);
if (soapMessage != null) { // IN OUR CASE, message!=null,
soapMessage!=null
OutputStream os =
message.getContent(OutputStream.class); // <==== IN OUR CASE, os == null
try {
setMessageContent(message, soapMessage);
soapMessage.writeTo(os); // <==== IN OUR CASE,
throws NullPointerException
The exception is:
[...]
Caused by: java.lang.NullPointerException
at
com.sun.xml.messaging.saaj.soap.MessageImpl.writeTo(MessageImpl.java:122
1)
at
org.apache.cxf.binding.soap.saaj.SAAJOutInterceptor$SAAJOutEndingInterce
ptor.handleMessage(SAAJOutInterceptor.java:116)
at
org.apache.cxf.binding.soap.saaj.SAAJOutInterceptor$SAAJOutEndingInterce
ptor.handleMessage(SAAJOutInterceptor.java:103)
Thanks,
Radu Manolescu
Morgan Stanley | Technology
2000 Westchester Ave, 1st Floor | Purchase, NY 10577
Phone: +1 914 225-5871
Mobile: +1 203 648-6964
[EMAIL PROTECTED]
--------------------------------------------------------
NOTICE: If received in error, please destroy and notify sender. Sender does not
intend to waive confidentiality or privilege. Use of this email is prohibited
when received in error.