[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: Https within a Rpg program (SetError() #7: Timeout issue)
Mike,
When I ping the External Web Service site, I get the IP Address and
the following info.
No response from host within 1 seconds for connection verification
1.
No response from host within 1 seconds for connection verification
2.
No response from host within 1 seconds for connection verification
3.
No response from host within 1 seconds for connection verification
4.
No response from host within 1 seconds for connection verification
5.
Connection verification statistics: 0 of 5 successful (0
%).
When I ping the Interanl Web Service site, I get the IP Address and
the following info.
PING reply 1 from 10.200.3.33 took 0 ms. 256 bytes. TTL 127.
PING reply 2 from 10.200.3.33 took 0 ms. 256 bytes. TTL 127.
PING reply 3 from 10.200.3.33 took 0 ms. 256 bytes. TTL 127.
PING reply 4 from 10.200.3.33 took 0 ms. 256 bytes. TTL 127.
PING reply 5 from 10.200.3.33 took 0 ms. 256 bytes. TTL 127.
Round-trip (in milliseconds) min/avg/max = 0/0/0.
Connection verification statistics: 5 of 5 successful (100 %).
Best regards,
Bryan
> From: mkrebs@xxxxxxxxxxxxxxxxxx
> To: ftpapi@xxxxxxxxxxxxxxxxxxxxxx
> Date: Thu, 11 Aug 2011 12:27:59 -0500
> Subject: RE: Https within a Rpg program (SetError() #7: Timeout
issue)
>
> Scott provided a good explanation and knows the process HTTPAPI uses
but I am wondering if you failed at step 1. From your i, if you:
>
> Ping 'www.XXXX.com'
>
> What do you get?
>
> If that works correctly, check that port 443 is allowed through your
firewall or that you are using the proxy support in HTTPAPI to connect
(see examples).
>
> Mike
>
> -----Original Message-----
> From: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
[mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Scott
Klement
> Sent: Thursday, August 11, 2011 10:45 AM
> To: HTTPAPI and FTPAPI Projects
> Subject: Re: Https within a Rpg program (SetError() #7: Timeout
issue)
>
> Hi Bryan,
>
> I don't see how this could possibly be a certificate issue. A
firewall
> issue is the most probable cause.
>
> Making a connection over a TCP/IP network is much like calling
someone
> on a phone. Let's say you wanted to order a pizza on the phone, the
> process might look like this:
>
> 1) Look up the number (phone number)
> 2) Dial the number
> 3) Wait for someone to answer.
> 4) Give credentials (name, phone number, address)
> 5) Give your order
>
> The SSL conversation is very similar.
>
> 1) Look up the number, (IP address)
> 2) Dial the number (ask the OS to connect)
> 3) Wait for some program to answer.
> 4) Give credentials (SSL certificate)
> 5) Start encryption
> 6) Request a document (like "give your order")
>
>
> You are succeeding in steps 1 & 2. You are timing out on step #3! It
> has send a request to connect, and it's waiting for a response...
> waiting... waiting... and eventually giving up. Just like you'd give
up
> eventually if nobody at the pizza place answered the phone.
>
> Now, if nobody answered the phone at the pizza place, and your wife
> asked "why didn't you order the pizza", would you say "They didn't
> answer because they didn't like our house address". That's not
> possible, because you never told them your address!
>
> Same with SSL. If you haven't connected successfully, they can't
> possibly dislike your certificate, because you haven't sent it to
them!
>
> (However, once you solve your connection problem, THEN you might
have a
> certificate problem... but that hasn't happened yet!)
>
>
> On 8/11/2011 8:58 AM, BBB Rhodes wrote:
> >
> > All
> >
> > Our company is working with an outside web service product where
we
> > need to pull data into the iSeries via RPG. I am a novice to
> > using HTTPAPI and this is the first time our company is going to
an
> > external web service.
> >
> >
> > Currently we have RPG programs which use the HTTPAPI connect to a
> > internal web service.
> >
> >
> > Based on our research, we believe our issue is with our firewall
> > (iSeries/internet) and a certificate that is needed, but not sure
> > where and how to get that information.
> >
> >
> > We have seen references to Dump of server-side/local-side
> > certificate information but did not see coding on getting this
> > information dumped.
> >
> >
> > In our RPG program, we have setup the following code:
> >
> >
> > https_init(our_App');
> >
> >
> > http_XmlStripCRLF(*OFF);
> >
> >
> > SOAP
> > =
> >
> > '<soapenv:Envelope
> > '
> >
> > +'xmlns:soapenv="[1]http://schemas.xmlsoap.org/soap/envelope/"
> > '
> >
> > +'xmlns:con="[2]http://www.xxxxx.com/contracts/services/contract"
> > '
> >
> > +'xmlns:auth="[3]http://www.xxxxx.com/contracts/types/auth"
> > '
> >
> >
+'xmlns:con1="[4]http://www.xxxxx.com/contracts/types/domain/contra
> > ct"
> >
> > +'<soapenv:Header/>'
> >
> > +'
> > <soapenv:Body>'
> >
> > +'
> > <con:get-lines-request>'
> >
> > +'
> > <con:authentication'
> >
> > +'<auth:user>user</auth:user>'
> >
> > +'
> > <auth:credential>'
> >
> > +'
> > <auth:password>word</auth:password>'
> >
> > +'
> > </auth:credential>'
> >
> > +'
> > </con:authentication>'
> >
> > +'
> > <con:request-data>'
> >
> > +'
> > <con1:id>xx218f4a20034002a97aefa4763b97xx</con1:id>'
> >
> > +'
> > </con:request-data>'
> >
> > +'
> > </con:get-lines-request>'
> >
> > +'</soapenv:Body>
> > '
> >
> > +'</soapenv:Envelope>';
> >
> >
> >
> > http_debug(*ON);
> >
> >
> >
> > rc =
> > http_url_post_xml(
> >
> > 'https://xxxxxxxxxxxxxxx.xxxxxxxx.com/webservices/servic
> > es
> >
> > /ContractServices
> > '
> >
> > : %addr(SOAP) +
> > 2
> >
> > :
> > %len(SOAP)
> >
> > :
> > *NULL
> >
> > :
> > %paddr(Incoming)
> >
> > : %addr(Result)
> >
> > :
> > HTTP_TIMEOUT
> >
> > :
> > HTTP_USERAGENT
> >
> > :
> > 'text/xml'
> >
> > :
> > 'https://xxxxxxxxxxxxxxxx.xxxxxxxxx.com/webservices/service
> >
> > /ContractServices ');
> >
> >
> > The process times out with the following info placed in the
> > debug log.
> >
> >
> > /tmp/httpapi_debug.txt
> >
> > HTTPAPI Ver 1.23 released
> > 2008-04-24
> >
> > OS/400 Ver
> > V6R1M0
> >
> >
> >
> > New iconv() objects set, PostRem=819. PostLoc=0. ProtRem=819.
> > ProtLoc=0
> >
> > http_persist_open():
> > entered
> >
> > http_long_ParseURL():
> > entered
> >
> > DNS resolver retrans: 2
> >
> > DNS resolver retry :
> > 2
> >
> > DNS resolver options:
> > x'00000136'
> >
> > DNS default domain: --our internal Web Services--
> >
> > DNS server found: --our IP address--
> >
> > DNS server found: --our IP address--
> >
> > SetError() #7: Timeout occurred while trying to connect to
> > server!
> >
> >
> >
> >
> > Any help would be greatly appreciated.
> >
> >
> >
> > Regards,
> > Bryan
> >
> > References
> >
> > 1. http://schemas.xmlsoap.org/soap/envelope/
> > 2. http://www.xxxxx.com/contracts/services/contract
> > 3. http://www.xxxxx.com/contracts/types/auth
> > 4. http://www.xxxxx.com/contracts/types/domain/contract
> >
> >
> >
> >
> >
----------------------------------------------------------------------
-
> > This is the FTPAPI mailing list. To unsubscribe, please go to:
> > 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
>
----------------------------------------------------------------------
-
>
----------------------------------------------------------------------
-
> This is the FTPAPI mailing list. To unsubscribe, please go to:
> 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
-----------------------------------------------------------------------