nishigandharajurkar / wsdl2objc

Automatically exported from code.google.com/p/wsdl2objc
MIT License
0 stars 0 forks source link

SOAP 1.2 require the SOAP Action to be included in Content-Type header #44

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Build a WebService using Asp.Net 3.5
2. Call the WebService from the iPhone

What is the expected output?
"Hello World"

What do you see instead?
"Unable to handle request without a valid action parameter. Please supply a 
valid soap action"

What version of the product are you using? On what operating system?
0,6

Please provide any additional information below.
Adding action=http://tempuri.org/HelloWorld solved the problem.

Original issue reported on code.google.com by vdesm...@gmail.com on 12 Oct 2009 at 2:03

GoogleCodeExporter commented 9 years ago
- (void)sendHTTPCallUsingBody:(NSString *)outputBody soapAction:(NSString 
*)soapAction forOperation:(DefaultSoapOperation *)operation
{
...
    [request setValue:@"wsdl2objc" forHTTPHeaderField:@"User-Agent"];
    [request setValue:soapAction forHTTPHeaderField:@"SOAPAction"];

        //Fix the Content-Type require action for SOAP 1.2 issue
    [request setValue:[NSString stringWithFormat:@"application/soap+xml; charset=utf-8;action=%@", soapAction] forHTTPHeaderField:@"Content-Type"];
        //End of fix

    [request setValue:[NSString stringWithFormat:@"%u", [bodyData length]] forHTTPHeaderField:@"Content-Length"];
    [request setValue:self.address.host forHTTPHeaderField:@"Host"];
    [request setHTTPMethod: @"POST"];
...

Original comment by vdesm...@gmail.com on 15 Oct 2009 at 9:31

GoogleCodeExporter commented 9 years ago
Should be already fixed in the trunk.

Original comment by hasse...@gmail.com on 4 Mar 2011 at 6:36