Connecting Tech Pros Worldwide Help | Site Map

Sending a zip file as SOAP attachment

  #1  
Old March 24th, 2008, 10:32 AM
Newbie
 
Join Date: Mar 2008
Posts: 3
I have to send a zip file whose name is MeFAttachment.zip as an attachment in SOAP 1.1 packet.


But I get an error while submitting.

Here is the error description

Server Error 415
IDP Rule 'Invalid HTTP Message' aborted processing. Invalid mime format
System Name: ccgows012
Server Policy: ATS XML Policy
Matched task list:
Failure occurred in task:



Below is the content that I have written.


Expand|Select|Wrap|Line Numbers
  1. MIME-Version: 1.0
  2. Content-Type: Multipart/Related; boundary=MIMEBoundary; type=text/xml; 
  3. Content-Description: Transmission file for IRS MeF.
  4.  
  5. --MIMEBoundary
  6. Content-Type: text/xml; charset=UTF-8
  7. Content-Transfer-Encoding: 8bit
  8. Content-Location: SoapEnvelope
  9. <?xml version="1.0" encoding="UTF-8"?>
  10. <SOAP:Envelope xmlns="http://www.irs.gov/efile" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" xmlns:efile="http://www.irs.gov/efile" xsi:schemaLocation="http://schemas.xmlsoap.org/soap/envelope/ ../message/SOAP.xsd <http://www.irs.gov/efile> ../message/efileMessage.xsd">
  11.     <SOAP:Header>
  12. --- here is soap header part        
  13.     </SOAP:Header>
  14.     <SOAP:Body>
  15.  
  16. -----here is soap body part
  17.             </SOAP:Body>
  18. </SOAP:Envelope>
  19. --MIMEBoundary
  20. Content-Type: application/zip
  21. Content-Transfer-Encoding: Binary
  22. Content-Location: MeFAttachment.zip
  23. --MIMEBoundary

Last edited by Dormilich; June 8th, 2009 at 09:17 PM. Reason: added [code] tags
  #2  
Old June 8th, 2009, 06:56 PM
Newbie
 
Join Date: Jun 2009
Posts: 1

re: Sending a zip file as SOAP attachment


Hi Jyotish, i am trying to repeat what you have done already. I am trying to create an attachment to send to IRS through Mef, can you help me by giving some information on how i should go about solving this.
If you can share the code its much appreciated.
Thanks.


Quote:
Originally Posted by talk2jyotish View Post
I have to send a zip file whose name is MeFAttachment.zip as an attachment in SOAP 1.1 packet.


But I get an error while submitting.

Here is the error description

Server Error 415
IDP Rule &apos;Invalid HTTP Message&apos; aborted processing. Invalid mime format
System Name: ccgows012
Server Policy: ATS XML Policy
Matched task list:
Failure occurred in task:



Below is the content that I have written.


MIME-Version: 1.0
Content-Type: Multipart/Related; boundary=MIMEBoundary; type=text/xml;
Content-Description: Transmission file for IRS MeF.

--MIMEBoundary
Content-Type: text/xml; charset=UTF-8
Content-Transfer-Encoding: 8bit
Content-Location: SoapEnvelope
<?xml version="1.0" encoding="UTF-8"?>
<SOAP:Envelope xmlns="http://www.irs.gov/efile" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" xmlns:efile="http://www.irs.gov/efile" xsi:schemaLocation="http://schemas.xmlsoap.org/soap/envelope/ ../message/SOAP.xsd <http://www.irs.gov/efile> ../message/efileMessage.xsd">
<SOAP:Header>
--- here is soap header part
</SOAP:Header>
<SOAP:Body>

-----here is soap body part
</SOAP:Body>
</SOAP:Envelope>
--MIMEBoundary
Content-Type: application/zip
Content-Transfer-Encoding: Binary
Content-Location: MeFAttachment.zip
--MIMEBoundary
  #3  
Old June 10th, 2009, 04:01 PM
Moderator
 
Join Date: Mar 2006
Posts: 1,103

re: Sending a zip file as SOAP attachment


Are you putting your zip data directly into the xml, or are you converting it to a xml friendly form, eg base 64 encoding?
Reply


Similar Threads
Thread Thread Starter Forum Replies Last Post
Transport large binary file from Window client application to Web Server & back gauravkhanna@gmail.com answers 2 November 25th, 2005 02:15 PM
How to send file with WebService? ad answers 4 November 17th, 2005 12:22 PM