[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: HTTPS SOAP post gets HTTP/1.1 400 Bad Request.
Hello Mr. Raddatz and thanks for your response. You are correct that
the square bracket number shouldn't be there ([1] - [6]). I went back
and checked and they are not in the original, nor do they appear when I
checked my sent Email. Is it possible that these get created when my
Email is posted to this board? I honestly don't know where they came
from. Paul.
___________________________________________________________
Paul Reid
Application Developer III
Erb Group of Companies | 290 Hamilton Road | New Hamburg, Ontario | N3A
1A2
Phone: 519.662.6133 ext. 2363
Web: [1]http://www.erbgroup.com/
From: Thomas Raddatz <thomas.raddatz@xxxxxxxxxxx>
To: HTTPAPI and FTPAPI Projects <ftpapi@xxxxxxxxxxxxxxxxxxxxxx>
Date: 01/09/2013 01:30 PM
Subject: Re: HTTPS SOAP post gets HTTP/1.1 400 Bad Request.
Sent by: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
__________________________________________________________________
Paul,
I do not know who you got the request message out of soapUI but
definitely
the numbers in square brackets e.g. "[1]" are wrong. Please remove all
the
numbers in square brackets from your request message and try to call
the
web service again. ([1] - [6])
Basic sample messages are shown here:
[2]https://hos.myshawtracking.ca/QHOSWSNA/driver.asmx?op=VerifyAccess
Thomas.
Am 09.01.2013 17:53, schrieb PReid@xxxxxxxxxxxx:
> Hello. I am wondering if someone can help. I am attempting to
make a
> post request to a secure (https) web service and I keep getting
an
> error. I used the free version of SoapUI to get the xml for the
post.
> (The request works fine in soapUI.) I am using HTTPAPI V1.24,
which I
> believe is the most current version. Below is a copy of my code.
On
> line 009700 the value of rc = 400, and In my job log I receive
errors
> "Unable to retrieve query options file." & "HTTP/1.1 400 Bad
Request".
> Below my code I have also included a copy of my error log. Any
help
> would be much appreciated. Thanks in advance. Paul.
> 000100
>
*----------------------------------------------------------------------
> --*
> 000200 * EXPORTDRVR - Export Driver.
> *
> 000300
>
*----------------------------------------------------------------------
> --*
> 000400 *
> 000500 H BNDDIR('HTTPAPI':'QC2LE')
> 000600 *
> 000700 D EXPORTDRVR PR extpgm('EXPORTDRVR')
> 000800 D EXPORTDRVR PI
> 000900 *
> 001000 /copy httpapi_h
> 001100 *
> 001200 D Incoming PR
> 001300 D rate 8F
> 001400 D depth 10I 0 value
> 001500 D name 1024A varying const
> 001600 D path 24576A varying const
> 001700 D value 65535A varying const
> 001800 D attrs * dim(32767)
> 001900 D const
options(*varsize)
> 002000 *
> 002100 D SOAP s 32767A varying
> 002200 D rc s 10I 0
> 002300 D rate s 8F
> 002400 D Result s 12P 2
> 002500 *
> 002600 D success S 3A inz('No ')
> 002700 D expDrvLog S 1000A varying
> 002800 *
> 002900 /free
> 003000
> 003100 SOAP =
> 003200 '<?xml version="1.0" encoding="utf-8"?>'
> 003300 +' <soap:Envelope'
> 003400 +'
xmlns:soap="[1][3]http://www.w3.org/2003/05/soap-envelope"'
> 003500 +'
>
xmlns:wsa="[2][4]http://schemas.xmlsoap.org/ws/2004/03/addressing"'
> 003600 +'
xmlns:wsse="[3][5]http://docs.oasis-open.org/wss/2004/01/'
> 003700
+'oasis-200401-wss-wssecurity-secext-1.0.xsd"'
> 003800 +'
xmlns:wsu="[4][6]http://docs.oasis-open.org/wss/2004/01/'
> 003900
+'oasis-200401-wss-wssecurity-utility-1.0.xsd"'
> 004000 +' xmlns:xsd="[5][7]http://www.w3.org/2001/XMLSchema"'
> 004100 +'
xmlns:xsi="[6][8]http://www.w3.org/2001/XMLSchema-instance">'
> 004200 +'<soap:Header>'
> 004300 +'<wsa:Action>'
> 004400 +'http://www.qualcomm.com/VerifyAccess'
> 004500 +'</wsa:Action>'
> 004600 +'<wsa:MessageID>'
> 004700 +'urn:uuid:db5ab195-ceb1-4325-8e1a-3b293ee1b49b'
> 004800 +'</wsa:MessageID>'
> 004900 +'<wsa:ReplyTo>'
> 005000 +'<wsa:Address>'
> 005100
>
+'http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous'
> 005200 +'</wsa:Address>'
> 005300 +'</wsa:ReplyTo>'
> 005400 +'<wsa:To>'
> 005500 +'https://qhos.qualcommapps.com/qhoswsna/driver.asmx'
> 005600 +'<wsa:To>'
> 005700 +'<wsse:Security soap:mustUnderstand="1">'
> 005800 +'<wsse:UsernameToken
xmlns:wsu="[7][9]http://docs.oasisopen.'
> 005900
> +'org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"'
> 006000 +'
> wsu:Id="SecurityToken-fbd3add0-e734-4dc3-b717-609e4089228d">'
> 006100 +'<wsse:Username>Paul@Erb International</wsse:Username>'
> 006200 +'<wsse:Password
> Type="[8][10]http://docs.oasis-open.org/wss/2004/01/'
> 006300
> +'oasis-200401-wss-username-token-profile-1.0#'
> 006400
> +'PasswordText">Preid2363</wsse:Password>'
> 006500 +'</wsse:UsernameToken>'
> 006600 +'</wsse:Security>'
> 006700 +'</soap:Header>'
> 006800 +'<soap:Body>'
> 006900 +'<ExportDriver
xmlns="[9][11]http://www.qualcomm.com">'
> 007000 +'<request>'
> 007100 +'<Drivers>'
> 007200 +'<string>CGOES</string>'
> 007300 +'<string>LBOLT</string>'
> 007400 +'</Drivers>'
> 007500 +'<RuleSet>CANMain</RuleSet>'
> 007600 +'</request>'
> 007700 +'</ExportDriver>'
> 007800 +'</soap:Body>'
> 007900 +'</soap:Envelope>';
> 008000
> 008100 expDrvLog = '/home/PAULRE/expDrvLog.txt';
> 008200
> 008300 http_debug(*ON : expDrvLog);
> 008400
> 008500 rc = http_url_post_xml(
> 008600
> 'https://hos.myshawtracking.ca/QHOSWSNA/driver.asmx'
> 008700 : %addr(SOAP) + 2
> 008800 : %len(SOAP)
> 008900 : *NULL
> 009000 : %paddr(Incoming)
> 009100 : %addr(rate)
> 009200 : HTTP_TIMEOUT
> 009300 : HTTP_USERAGENT
> 009400 : 'text/xml'
> 009500 : 'http://www.qualcomm.com');
> 009600
> 009700 if (rc <> 1);
> 009800 http_crash();
> 009900 else;
> 010000 SUCCESS = 'Yes';
> 010100 endif;
> 010200
> 010300 *inlr = *on;
> 010400
> 010500 /end-free
> Below is what I am getting from http_debug:
> HTTPAPI Ver 1.24 released 2012-01-23
> OS/400 Ver V6R1M0
> http_persist_open(): entered
> http_long_ParseURL(): entered
> DNS resolver retrans: 2
> DNS resolver retry : 2
> DNS resolver options: x'00000136'
> DNS default domain: ERBGROUP.COM
> DNS server found: 192.168.2.6
> DNS server found: 216.171.96.38
> DNS server found: 216.16.248.50
>
-----------------------------------------------------------------------
> --------------
> Dump of server-side certificate information:
>
-----------------------------------------------------------------------
> --------------
> Cert Validation Code = 6000
> -----BEGIN CERTIFICATE-----
> MIIFxTCCBK2gAwIBAgIRAJ6b6zIgQQQtFOcPP2yFiw8wDQYJKoZIhvcNAQEFBQAw
> gYkxCzAJBgNVBAYTAkdCMRswGQYDVQQIExJHcmVhdGVyIE1hbmNoZXN0ZXIxEDAO
> BgNVBAcTB1NhbGZvcmQxGjAYBgNVBAoTEUNPTU9ETyBDQSBMaW1pdGVkMS8wLQYD
> VQQDEyZDT01PRE8gSGlnaCBBc3N1cmFuY2UgU2VjdXJlIFNlcnZlciBDQTAeFw0w
> OTEyMzAwMDAwMDBaFw0xNDEyMzAyMzU5NTlaMIHJMQswCQYDVQQGEwJDQTEPMA0G
> A1UEERMGVDJQNEw0MRAwDgYDVQQIEwdBbGJlcnRhMRAwDgYDVQQHEwdDYWxnYXJ5
> MRswGQYDVQQJExI2MzAgM3JkIEF2ZW51ZSBTLlcxJTAjBgNVBAoTHFNoYXcgU2F0
> ZWxsaXRlIFNlcnZpY2VzIEluYy4xIzAhBgNVBAsTGkNvbW9kbyBQcmVtaXVtU1NM
> IFdpbGRjYXJkMRwwGgYDVQQDFBMqLm15c2hhd3RyYWNraW5nLmNhMIIBIjANBgkq
> hkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAx5GdtwBunnAM2cPOeuNhj19A7zFFK9/6
> 2k4hmgieFfXZQkxMZrQ754yh5DOXWoXveLLC8BCyHo5XGoZ3HmwmSPk7t17vXVSt
> /8WeXKXlUvazitSbPrTW+9ex33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kRC280XdbOLUQ/Y4kSGyj6/KXheiGPJCAEpuegnGvCD
> i7A4pFisqX59ld3e3awMcwFsOW7aAsqZzuAexlpdQSF0uvhWT2zp/W72Cf9FnWjy
> adwnIF+xZLc9Q3fnrwV1XXGP+JnQejhm/oBHKcm4amo8L3j7vAbqc5GBadJkzs0c
> fNH2TYYssCpQJ+KYypRmGBev+cngAtjtcAd2zQUJl2HD8KbryerAfqA=
> -----END CERTIFICATE-----
> Serial Number: 00:9E:9B:EB:32:20:41:04:2D:14:E7:0F:3F:6C:85:8B:0F
> Common Name: *.myshawtracking.ca
> Country: CA
> State/Province: Alberta
> Locality: Calgary
> Org Unit: Shaw Satellite Services Inc.
> Org: Comodo PremiumSSL Wildcard
> PostalCode: T2P4L4
> Issuer CN: COMODO High Assurance Secure Server CA
> Issuer Country: GB
> Issuer State/Province: Greater Manchester
> Issuer Locality: Salford
> Issuer Org: COMODO CA Limited
> Version: 03
> not before: 20091229190000
> not after: 20141230185959
> pub key alg: 1.2.840.113549.1.1.5
> Protocol Used: TLS Version 1
> http_persist_post(): entered
> http_persist_req(POST) entered.
> http_long_ParseURL(): entered
> do_oper(POST): entered
> There are 0 cookies in the cache
> POST /QHOSWSNA/driver.asmx HTTP/1.1
> Host: hos.myshawtracking.ca
> User-Agent: http-api/1.24
> Content-Type: text/xml
> SOAPAction: [10][12]http://www.qualcomm.com
> Content-Length: 1458
> senddoc(): entered
> <?xml version="1.0" encoding="utf-8"?> <soap:Envelope
> xmlns:soap="[11][13]http://www.w3.org/2003/05/soap-envelope"
>
xmlns:wsa="[12][14]http://schemas.xmlsoap.org/ws/2004/03/addressing"
>
xmlns:wsse="[13][15]http://docs.oasis-open.org/wss/2004/01/oasis-200401
-wss
> -wssecurity-secext-1.0.xsd"
>
xmlns:wsu="[14][16]http://docs.oasis-open.org/wss/2004/01/oasis-200401-
wss-
> wssecurity-utility-1.0.xsd"
> xmlns:xsd="[15][17]http://www.w3.org/2001/XMLSchema"
>
xmlns:xsi="[16][18]http://www.w3.org/2001/XMLSchema-instance"><soap:Hea
der>
>
<wsa:Action>[17][19]http://www.qualcomm.com/VerifyAccess</wsa:Action><w
sa:M
>
essageID>urn:uuid:db5ab195-ceb1-4325-8e1a-3b293ee1b49b</wsa:MessageID><
>
wsa:ReplyTo><wsa:Address>[18][20]http://schemas.xmlsoap.org/ws/2004/08/
addr
>
essing/role/anonymous</wsa:Address></wsa:ReplyTo><wsa:To>[19][21]https:
//qh
> os.qualcommapps.com/qhoswsna/driver.asmx<wsa:To><wsse:Security
> soap:mustUnderstand="1"><wsse:UsernameToken
>
xmlns:wsu="[20][22]http://docs.oasisopen.org/wss/2004/01/oasis-200401-w
ss-w
> ssecurity-utility-1.0.xsd"
>
wsu:Id="SecurityToken-fbd3add0-e734-4dc3-b717-609e4089228d"><wsse:Usern
> ame>Paul@Erb International</wsse:Username><wsse:Password
>
Type="[21][23]http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-u
sern
>
ame-token-profile-1.0#PasswordText">Preid2363</wsse:Password></wsse:Use
> rnameToken></wsse:Security></soap:Header><soap:Body><ExportDriver
>
xmlns="[22][24]http://www.qualcomm.com"><request><Drivers><string>CGOES
</st
>
ring><string>LBOLT</string></Drivers><RuleSet>CANMain</RuleSet></reques
> t></ExportDriver></soap:Body></soap:Envelope>
> recvresp(): entered
> HTTP/1.1 400 Bad Request
> Connection: close
> Date: Wed, 09 Jan 2013 16:43:10 GMT
> Server: Microsoft-IIS/6.0
> X-Powered-By: ASP.NET
> X-AspNet-Version: 2.0.50727
> Cache-Control: private
> Content-Type: text/html
> SetError() #13: HTTP/1.1 400 Bad Request
> recvresp(): end with 400
> recvdoc parms: identity 0
> header_load_cookies() entered
> recvdoc(): entered
> SetError() #0:
> SetError() #44: CommSSL_read: connection broken
> SetError() #13: HTTP/1.1 400 Bad Request
> http_close(): entered
> Thanks again. Paul.
> ___________________________________________________________
> Paul Reid
> Application Developer III
> Erb Group of Companies | 290 Hamilton Road | New Hamburg, Ontario
| N3A
> 1A2
> Phone: 519.662.6133 ext. 2363
> Web: [23][25]http://www.erbgroup.com/
>
> References
>
> 1. [26]http://www.w3.org/2003/05/soap-envelope
> 2. [27]http://schemas.xmlsoap.org/ws/2004/03/addressing
> 3. [28]http://docs.oasis-open.org/wss/2004/01/'
> 4. [29]http://docs.oasis-open.org/wss/2004/01/'
> 5. [30]http://www.w3.org/2001/XMLSchema
> 6. [31]http://www.w3.org/2001/XMLSchema-instance
> 7. [32]http://docs.oasisopen.'/
> 8. [33]http://docs.oasis-open.org/wss/2004/01/'
> 9. [34]http://www.qualcomm.com/
> 10. [35]http://www.qualcomm.com/
> 11. [36]http://www.w3.org/2003/05/soap-envelope
> 12. [37]http://schemas.xmlsoap.org/ws/2004/03/addressing
> 13.
[38]http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-
secext-1.0.xsd
> 14.
[39]http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-
utility-1.0.xsd
> 15. [40]http://www.w3.org/2001/XMLSchema
> 16. [41]http://www.w3.org/2001/XMLSchema-instance
> 17. [42]http://www.qualcomm.com/VerifyAccess
> 18.
[43]http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous
> 19. [44]https://qhos.qualcommapps.com/qhoswsna/driver.asmx
> 20.
[45]http://docs.oasisopen.org/wss/2004/01/oasis-200401-wss-wssecurity-u
tility-1.0.xsd
> 21.
[46]http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-to
ken-profile-1.0#PasswordText
> 22. [47]http://www.qualcomm.com/
> 23. [48]http://www.erbgroup.com/
>
>
>
>
-----------------------------------------------------------------------
> This is the FTPAPI mailing list. To unsubscribe, please go to:
> [49]http://www.scottklement.com/mailman/listinfo/ftpapi
>
-----------------------------------------------------------------------
>
-----------------------------------------------------------------------
This is the FTPAPI mailing list. To unsubscribe, please go to:
[50]http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------
References
1. http://www.erbgroup.com/
2. https://hos.myshawtracking.ca/QHOSWSNA/driver.asmx?op=VerifyAccess
3. http://www.w3.org/2003/05/soap-envelope
4. http://schemas.xmlsoap.org/ws/2004/03/addressing
5. http://docs.oasis-open.org/wss/2004/01/'
6. http://docs.oasis-open.org/wss/2004/01/'
7. http://www.w3.org/2001/XMLSchema
8. http://www.w3.org/2001/XMLSchema-instance
9. http://docs.oasisopen.'/
10. http://docs.oasis-open.org/wss/2004/01/'
11. http://www.qualcomm.com/
12. http://www.qualcomm.com/
13. http://www.w3.org/2003/05/soap-envelope
14. http://schemas.xmlsoap.org/ws/2004/03/addressing
15. http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss
16. http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-
17. http://www.w3.org/2001/XMLSchema
18. http://www.w3.org/2001/XMLSchema-instance
19. http://www.qualcomm.com/VerifyAccess
20. http://schemas.xmlsoap.org/ws/2004/08/addr
21. https://qh/
22. http://docs.oasisopen.org/wss/2004/01/oasis-200401-wss-w
23. http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-usern
24. http://www.qualcomm.com/
25. http://www.erbgroup.com/
26. http://www.w3.org/2003/05/soap-envelope
27. http://schemas.xmlsoap.org/ws/2004/03/addressing
28. http://docs.oasis-open.org/wss/2004/01/'
29. http://docs.oasis-open.org/wss/2004/01/'
30. http://www.w3.org/2001/XMLSchema
31. http://www.w3.org/2001/XMLSchema-instance
32. http://docs.oasisopen.'/
33. http://docs.oasis-open.org/wss/2004/01/'
34. http://www.qualcomm.com/
35. http://www.qualcomm.com/
36. http://www.w3.org/2003/05/soap-envelope
37. http://schemas.xmlsoap.org/ws/2004/03/addressing
38. http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd
39. http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
40. http://www.w3.org/2001/XMLSchema
41. http://www.w3.org/2001/XMLSchema-instance
42. http://www.qualcomm.com/VerifyAccess
43. http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous
44. https://qhos.qualcommapps.com/qhoswsna/driver.asmx
45. http://docs.oasisopen.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
46. http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText
47. http://www.qualcomm.com/
48. http://www.erbgroup.com/
49. http://www.scottklement.com/mailman/listinfo/ftpapi
50. http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------
This is the FTPAPI mailing list. To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------