Hello,

I try to send an attachment with MTOM from a Client to a Server. I
traced the Message with tcpmon and see, that the message contains base64
Date directly in the body and not as a xop:include link to an
attachment. This happends with small attachments (34kb) and Big ons
(22mb) both.


On Client Site, I have enabled MTOM with


stub._getServiceClient().getOptions().setProperty(Constants.Configuration.ENABLE_MTOM,
Constants.VALUE_TRUE);

On server site, I set the enableMTOM Property to true.

The relevant Part of the WSDL:
<xs:element name="addAntragsdokument">
<xs:complexType>
<xs:sequence>
...
<xs:element minOccurs="0" name="pdfDokument"
nillable="true" type="xmime:base64Binary" />
</xs:sequence>
</xs:complexType>
</xs:element>



The Soap Message looks like, that MTOM is enabled because of
"Content-Type: application/xop+xml;" in HTTP Header. But as you can see,
there is no xop:include in the soap-body:

POST /avparchiveservice/services/AvpArchivService HTTP/1.1
Content-Type: multipart/related;
boundary=MIMEBoundaryurn_uuid_0655E8454C89FC8F621214463338880;
type="application/xop+xml";
start="<0.urn:uuid:[EMAIL PROTECTED]>";
start-info="text/xml"
SOAPAction: "urn:addMandantendokument"
User-Agent: Axis2
Host: localhost:8081
Transfer-Encoding: chunked

20e5
--MIMEBoundaryurn_uuid_0655E8454C89FC8F621214463338880
Content-Type: application/xop+xml; charset=UTF-8; type="text/xml"
Content-Transfer-Encoding: binary
Content-ID: <0.urn:uuid:[EMAIL PROTECTED]>
<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";>
<soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing";>
<wsse:Security

xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd";
soapenv:mustUnderstand="1">
<wsu:Timestamp

xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
wsu:Id="Timestamp-7226213">
<wsu:Created>2008-06-26T06:55:38.687Z</wsu:Created>
<wsu:Expires>2008-06-26T07:00:38.687Z</wsu:Expires>
</wsu:Timestamp>
<wsse:UsernameToken

xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
wsu:Id="UsernameToken-33402317">
<wsse:Username>test</wsse:Username>
<wsse:Password

Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordDigest";>OC1+di1N3aFqUH6baAvd3maNh5w=</wsse:Password>
<wsse:Nonce>90q/U9DPl02opPiANdp1Nw==</wsse:Nonce>
<wsu:Created>2008-06-26T06:55:38.687Z</wsu:Created>
</wsse:UsernameToken>
</wsse:Security>


<wsa:To>http://localhost:8081/avparchiveservice/services/AvpArchivService</wsa:To>
<wsa:MessageID>urn:uuid:0655E8454C89FC8F621214463338238</wsa:MessageID>
<wsa:Action>urn:addMandantendokument</wsa:Action>
</soapenv:Header>
<soapenv:Body>
<ns1:addMandantendokument xmlns:ns1="http://avp.archivservice.awd.de";>
<ns1:mandantenNr>1</ns1:mandantenNr>
<ns1:dokumentenName>Mandantendokument</ns1:dokumentenName>
<ns1:dateiName>testdokument.pdf</ns1:dateiName>
<ns1:dokumentenTyp>MANDANTEN_DOKUMENTE</ns1:dokumentenTyp>
<ns1:pdfDokument xmlns:ns2="http://www.w3.org/2005/05/xmlmime";
ns2:contentType="application/pdf">
JVBERi0xLjQKJeLjz9MKMSAwIG9iago8PAovTWV


/R+yYtdo7I4j1vsZ04CFZGHCkxsHGwcEaSrUAjJ5IcI/n1qa+K7C72OWc0uq6D7IPONKvZZLFYd1701+WvF8u9//7m749fLPfuf+qWTz77dLn464VbavSH2pbU0oFKXi57+cXji6+W51LDrS/37/yCt35J+ZAbtRZoKZmrutBarMvV9cW9Tx+45dMHXGd58OkX3NjTxR3C8uMSl/vLxb3P+e23L6WP64vk3YFC5udnFw8uvtRvr17i25dXz+Xb9Y/gBOe3WLXRokft0SzhQDculO7gUuBBTQ4H4jxauLrgY/fYqRTy7jOecW29AqqGIkVz6Q3DFPoJAFUWtlA4
/NKymIPzz4JESKnnpBBpxy2t7lAnwcJsUxQoI09
2000
...
</ns1:addMandantendokument>
</soapenv:Body>


</soapenv:Envelope>3a--MIMEBoundaryurn_uuid_0655E8454C89FC8F621214463338880--0

Has anyone an Idea?

I'm using axis2 1.4 with addressing 1.4 and rampart 1.4 (Only
UsernameToken and Timestamp),

Thanks a lot! 
Regards
Jochen


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to