By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,143 Members | 1,267 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,143 IT Pros & Developers. It's quick & easy.

Using SoapExtensions to intercept and decrypt MIME formatted SOAP messages

P: n/a
Hi,

Please bear with me as I have only 1 weeks .NET experience.

I am using VB.NET to write a stand-alone client application that
connects to a Web service. I successfully send a request for a list
of items (i.e. getItemList), and successfully receive the list. I
then send a request for individual items from the list (i.e. getItem),
and successfully receive the item.

The situation is that the individual item/SOAP response contains
multipart MIME sections.

I would like to intercept (using SoapExtensions) the SOAP message
before it is deserialized and be able to decode the MIME sections,
before sending the SOAP message onto the deserializer.

I know I must intercept and decode the MIME as the deserializer
complains about the formatting of the SOAP message when it attempts to
read the message. (My requests are not encoded, only the responses
for the individual items are.)

I know that I must intercept the message when the message state is
BeforeDeserialize and perform the relevant actions.

I would be grateful if anyone can point me in the right direction for
HOW to decode the MIME and send the decoded message forward onto the
deserializer. Any examples would be greatly appreciated.

Thanks in advance.

AIM
Nov 15 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Hi!

Maybe I can point you somethings. Here we needed to add
some extra compression to the SOAP body, so we intercept
the messages, then add ZIP compression, and finally we let
the message go.

So, we created the CompressionExtension. This is a class
that inherits from:
System.Web.Services.Protocols.SoapExtension. Then, we
created the [CompressionExtension] attribute, that
inherits from: SoapExtensionAttribute. That attribute must
be added to each method that we want to use in the
compressed fashion... At the client, we compress the
outbound messages, and decode the inbound messages... in
the service, we do the opposite.

Hope it helps...

Cheers...
Mariano
-----Original Message-----
Hi,

Please bear with me as I have only 1 weeks .NET experience.
I am using VB.NET to write a stand-alone client application thatconnects to a Web service. I successfully send a request for a listof items (i.e. getItemList), and successfully receive the list. Ithen send a request for individual items from the list (i.e. getItem),and successfully receive the item.

The situation is that the individual item/SOAP response containsmultipart MIME sections.

I would like to intercept (using SoapExtensions) the SOAP messagebefore it is deserialized and be able to decode the MIME sections,before sending the SOAP message onto the deserializer.

I know I must intercept and decode the MIME as the deserializercomplains about the formatting of the SOAP message when it attempts toread the message. (My requests are not encoded, only the responsesfor the individual items are.)

I know that I must intercept the message when the message state isBeforeDeserialize and perform the relevant actions.

I would be grateful if anyone can point me in the right direction forHOW to decode the MIME and send the decoded message forward onto thedeserializer. Any examples would be greatly appreciated.

Thanks in advance.

AIM
.

Nov 15 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.