SOAP connect error

SOAP connect error

am 09.02.2010 22:05:31 von Eric Lommatsch

------_=_NextPart_001_01CAA9CB.B0B96BDC
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Hello,
=20
I am working with the SOAP package of PHP and I am trying make a =
connection
from a hosted website to a server in our office.=20
=20
I can get to the server perfectly fine from within our office, but I =
cannot
connect from the eternal site.
=20
I have checked and I am certain that the firewall for the server is =
open.
When I attempt to use the login page that I have created for the website =
I am
getting the following error message:
=20
Connect Error to XX.XX.XX.XXX:8080
=20
Where XX.XX.XX.XXX mask the actual ip address of the server. I have =
tried to
interogate all the values that soap_fault documents that it can return =
and
the only information I have been able to find beside the above message, =
which
is the $errorstring, is that my $faultcode =3D "HTTP".
=20
The information that I am getting is very cryptic. if I include our ip
address when I search I get no results. If I put in connect error :8080 =
I get
millions of meaningless results.
=20
Can someone please help to figure out how to get more meaningful =
information
from soap_fault for this problem so that I can figure out how to fix it.
=20
Thank you
=20
Eric H. Lommatsch
Programmer
360 Business=20
2087 South Grant Street
Denver, CO 80210
Tel 303-777-8939 Ext 23
Fax 888-282-9927
=20
ericl@360b.com
=20

------_=_NextPart_001_01CAA9CB.B0B96BDC--

Re: SOAP connect error

am 09.02.2010 23:07:18 von Shawn McKenzie

Eric Lommatsch wrote:
> Hello,
>
> I am working with the SOAP package of PHP and I am trying make a connection
> from a hosted website to a server in our office.
>
> I can get to the server perfectly fine from within our office, but I cannot
> connect from the eternal site.
>
> I have checked and I am certain that the firewall for the server is open.
> When I attempt to use the login page that I have created for the website I am
> getting the following error message:
>
> Connect Error to XX.XX.XX.XXX:8080
>
> Where XX.XX.XX.XXX mask the actual ip address of the server. I have tried to
> interogate all the values that soap_fault documents that it can return and
> the only information I have been able to find beside the above message, which
> is the $errorstring, is that my $faultcode = "HTTP".
>
> The information that I am getting is very cryptic. if I include our ip
> address when I search I get no results. If I put in connect error :8080 I get
> millions of meaningless results.
>
> Can someone please help to figure out how to get more meaningful information
> from soap_fault for this problem so that I can figure out how to fix it.
>
> Thank you
>
> Eric H. Lommatsch
> Programmer
> 360 Business
> 2087 South Grant Street
> Denver, CO 80210
> Tel 303-777-8939 Ext 23
> Fax 888-282-9927
>
> ericl@360b.com
>
>

If you go home or to Starbucks can you get to http://XX.XX.XX.XXX:8080 ?
If not, then the external server can't either. It could be a network
firewall/proxy sever in your office, or any number of things.

--
Thanks!
-Shawn
http://www.spidean.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

RE: SOAP connect error

am 09.02.2010 23:14:14 von Eric Lommatsch

>-----Original Message-----
>From: Shawn McKenzie [mailto:nospam@mckenzies.net]=20
>Sent: Tuesday, February 09, 2010 3:07 PM
>To: Eric Lommatsch
>Cc: php-general@lists.php.net
>Subject: Re: SOAP connect error
>
>Eric Lommatsch wrote:
>> Hello,
>> =20
>> I am working with the SOAP package of PHP and I am trying make a=20
>> connection from a hosted website to a server in our office.
>> =20
>> I can get to the server perfectly fine from within our office, but I=20
>> cannot connect from the eternal site.
>> =20
>> I have checked and I am certain that the firewall for the server is =
open.
>> When I attempt to use the login page that I have created for the=20
>> website I am getting the following error message:
>> =20
>> Connect Error to XX.XX.XX.XXX:8080
>> =20
>> Where XX.XX.XX.XXX mask the actual ip address of the server. I have=20
>> tried to interogate all the values that soap_fault documents that it=20
>> can return and the only information I have been able to find beside=20
>> the above message, which is the $errorstring, is that my $faultcode =
=3D
"HTTP".
>> =20
>> The information that I am getting is very cryptic. if I include our =
ip=20
>> address when I search I get no results. If I put in connect error=20
>> :8080 I get millions of meaningless results.
>> =20
>> Can someone please help to figure out how to get more meaningful=20
>> information from soap_fault for this problem so that I can figure out =
how
to fix it.
>> =20
>> Thank you
>> =20
>> Eric H. Lommatsch
>> Programmer
>> 360 Business
>> 2087 South Grant Street
>> Denver, CO 80210
>> Tel 303-777-8939 Ext 23
>> Fax 888-282-9927
>> =20
>> ericl@360b.com
>> =20
>>=20
>
>If you go home or to Starbucks can you get to http://XX.XX.XX.XXX:8080 =
?
> If not, then the external server can't either. It could be a network
firewall/proxy sever in your office, or any number of things.
>
>--
>Thanks!
>-Shawn
>http://www.spidean.com


I have connected to a clients computer that is remote from our office =
and I
am able to get to http://XX.XX.XX.XXX:8080. I probably should have =
mentioned
that when I try to get the webservice outside of the PHP site I am =
developing
I can get into that just fine. It is just when I try to use the PHP SOAP
client to access the webservice that I am getting the issue.


Thank you
=20
Eric H. Lommatsch
Programmer
360 Business=20
2087 South Grant Street
Denver, CO 80210
Tel 303-777-8939 Ext 23
Fax 888-282-9927
=20
ericl@360b.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Re: RE: SOAP connect error

am 10.02.2010 12:53:02 von Richard Quadling

On 9 February 2010 22:14, Eric Lommatsch wrote:
>>-----Original Message-----
>>From: Shawn McKenzie [mailto:nospam@mckenzies.net]
>>Sent: Tuesday, February 09, 2010 3:07 PM
>>To: Eric Lommatsch
>>Cc: php-general@lists.php.net
>>Subject: Re: SOAP connect error
>>
>>Eric Lommatsch wrote:
>>> Hello,
>>>
>>> I am working with the SOAP package of PHP and I am trying make a
>>> connection from a hosted website to a server in our office.
>>>
>>> I can get to the server perfectly fine from within our office, but I
>>> cannot connect from the eternal site.
>>>
>>> I have checked and I am certain that the firewall for the server is ope=
n.
>>> When I attempt to use the login page that I have created for the
>>> website I am getting the following error message:
>>>
>>> Connect Error to XX.XX.XX.XXX:8080
>>>
>>> Where XX.XX.XX.XXX mask the actual ip address of the server. I have
>>> tried to interogate all the values that soap_fault documents that it
>>> can return and the only information I have been able to find beside
>>> the above message, which is the $errorstring, is that my $faultcode =3D
> "HTTP".
>>>
>>> The information that I am getting is very cryptic. if I include our ip
>>> address when I search I get no results. If I put in connect error
>>> :8080 I get millions of meaningless results.
>>>
>>> Can someone please help to figure out how to get more meaningful
>>> information from soap_fault for this problem so that I can figure out h=
ow
> to fix it.
>>>
>>> Thank you
>>>
>>> Eric H. Lommatsch
>>> Programmer
>>> 360 Business
>>> 2087 South Grant Street
>>> Denver, CO 80210
>>> Tel 303-777-8939 Ext 23
>>> Fax 888-282-9927
>>>
>>> ericl@360b.com
>>>
>>>
>>
>>If you go home or to Starbucks can you get to http://XX.XX.XX.XXX:8080 ?
>> If not, then the external server can't either.  It could be a netwo=
rk
> firewall/proxy sever in your office, or any number of things.
>>
>>--
>>Thanks!
>>-Shawn
>>http://www.spidean.com
>
>
> I have connected to a clients computer that is remote from our office and=
I
> am able to get to http://XX.XX.XX.XXX:8080. I probably should have mentio=
ned
> that when I try to get the webservice outside of the PHP site I am develo=
ping
> I can get into that just fine. It is just when I try to use the PHP SOAP
> client to access the webservice that I am getting the issue.
>
>
> Thank you
>
> Eric H. Lommatsch
> Programmer
> 360 Business
> 2087 South Grant Street
> Denver, CO 80210
> Tel 303-777-8939 Ext 23
> Fax 888-282-9927
>
> ericl@360b.com
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

Are you using wsdl? If so, does the WSDL file contain the information
that the port to use for the requests is on port 8080?

--=20
-----
Richard Quadling
"Standing on the shoulders of some very clever giants!"
EE : http://www.experts-exchange.com/M_248814.html
EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp
Zend Certified Engineer : http://zend.com/zce.php?c=3DZEND002498&r=3D213474=
731
ZOPA : http://uk.zopa.com/member/RQuadling

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

RE: RE: SOAP connect error

am 11.02.2010 17:04:21 von Eric Lommatsch

>Are you using wsdl? If so, does the WSDL file contain the information =
that
the port to use for the requests is on port 8080?
>
>--
>-----
>Richard Quadling
>"Standing on the shoulders of some very clever giants!"
>EE : http://www.experts-exchange.com/M_248814.html
>EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp
>Zend Certified Engineer : =
http://zend.com/zce.php?c=3DZEND002498&r=3D213474731
>ZOPA : http://uk.zopa.com/member/RQuadling

First, I am sorry for not getting back to this yesterday. I had some =
other
things come up.

As far as I know this website is using WSDL. I know that one of the =
early
issues I ran into in trying to get this to work was not having the =
wsdl.php
file in the path.

That having been said are you talking about the wsdl file on the server =
that
is providing the service or are you talking about the wsdl file on the =
system
hosting the webpage.=20

I can get everything to work correctly when I am working from our =
internal
development server. But when I attempt to put the file on the hosted =
site our
clients would ultimately be using I am getting the connect error.=20

I have compared the wsdl.php files on these two servers and neither of =
them
have specific information about the port in them.

Here is the code that I am using to connect to the webservice:

$webservices_uri =3D
"http://xx.xx.xx.xx:8080/jasperserver/services/repository";

Here is the code where I am trying to connect:

function ws_checkUsername($username, $password)
{
$connection_params =3D array("user" =3D> $username, "pass" =3D>
$password);
$info =3D new SOAP_client($GLOBALS["webservices_uri"], false,
false, $connection_params);
=09
$op_xml =3D " operationName=3D\"list\"> wsType=3D\"folder\"
uriString=3D\"\" isNew=3D\"false\">".
"
";
=09
$params =3D array("request" =3D> $op_xml );
$response =3D $info->call("list",$params,array('namespace' =3D>
$GLOBALS["namespace"]));
=09
return $response;
}

This is working when I use the IP address of the server behind the =
firewall,
but when I try to use the address that is open through the firewall it =
is not
connecting. I can connect to the external IP address by entering it into =
the
browser and it does ask for the username and password.

Thank you
=20
Eric H. Lommatsch
Programmer
360 Business=20
2087 South Grant Street
Denver, CO 80210
Tel 303-777-8939 Ext 23
Fax 888-282-9927
=20
ericl@360b.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Re: RE: SOAP connect error

am 12.02.2010 11:19:43 von Richard Quadling

On 11 February 2010 16:04, Eric Lommatsch wrote:
>
>>Are you using wsdl? If so, does the WSDL file contain the information tha=
t
> the port to use for the requests is on port 8080?
>>
>>--
>>-----
>>Richard Quadling
>>"Standing on the shoulders of some very clever giants!"
>>EE : http://www.experts-exchange.com/M_248814.html
>>EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp
>>Zend Certified Engineer : http://zend.com/zce.php?c=3DZEND002498&r=3D2134=
74731
>>ZOPA : http://uk.zopa.com/member/RQuadling
>
> First, I am sorry for not getting back to this yesterday. I had some othe=
r
> things come up.
>
> As far as I know this website is using WSDL. I know that one of the early
> issues I ran into in trying to get this to work was not having the wsdl.p=
hp
> file in the path.
>
> That having been said are you talking about the wsdl file on the server t=
hat
> is providing the service or are you talking about the wsdl file on the sy=
stem
> hosting the webpage.
>
> I can get everything to work correctly when I am working from our interna=
l
> development server. But when I attempt to put the file on the hosted site=
our
> clients would ultimately be using I am getting the connect error.
>
> I have compared the wsdl.php files on these two servers and neither of th=
em
> have specific information about the port in them.
>
> Here is the code that I am using to connect to the webservice:
>
>        $webservices_uri =3D
> "http://xx.xx.xx.xx:8080/jasperserver/services/repository";
>
> Here is the code where I am trying to connect:
>
>        function ws_checkUsername($username, $password=
)
>        {
>                $connection_params=
=3D array("user" =3D> $username, "pass" =3D>
> $password);
>                $info =3D new SOAP=
_client($GLOBALS["webservices_uri"], false,
> false, $connection_params);
>
>                $op_xml =3D " est
> operationName=3D\"list\"> r\"
> uriString=3D\"\" isNew=3D\"false\">".
>                " resourceDescriptor>";
>
>                $params =3D array(=
"request" =3D> $op_xml );
>                $response =3D $inf=
o->call("list",$params,array('namespace' =3D>
> $GLOBALS["namespace"]));
>
>                return $response;
>        }
>
> This is working when I use the IP address of the server behind the firewa=
ll,
> but when I try to use the address that is open through the firewall it is=
not
> connecting. I can connect to the external IP address by entering it into =
the
> browser and it does ask for the username and password.
>
> Thank you
>
> Eric H. Lommatsch
> Programmer
> 360 Business
> 2087 South Grant Street
> Denver, CO 80210
> Tel 303-777-8939 Ext 23
> Fax 888-282-9927
>
> ericl@360b.com
>

Run this at the command line ...

php -r "echo file_get_contents('http://www.google.com');"

Do you get the google home page?

I suspect your browser is using a proxy, but your default gateway is
set to something different


There should only be 1 WSDL url. That is the URL of the WSDL file
associated with the service you are using.

It may be cached to a physical file.

Either way, it probably doesn't know that YOU are behind a firewall.

So. You need to proxy the calls.

You can use the default stream context.

Take a look at my user note on
http://www.php.net/manual/en/function.stream-context-get-def ault.php.
The site it relates to is probably dead now.

You may be able to assign the proxy details to the SOAPClient.

"For HTTP authentication, the login and password options can be used
to supply credentials. For making an HTTP connection through a proxy
server, the options proxy_host, proxy_port, proxy_login and
proxy_password are also available. For HTTPS client certificate
authentication use local_cert and passphrase options. An
authentication may be supplied in the authentication option. The
authentication method may be either SOAP_AUTHENTICATION_BASIC
(default) or SOAP_AUTHENTICATION_DIGEST."
(http://www.php.net/manual/en/soapclient.soapclient.php#soap client.soapclie=
nt.parameters)


Does any of that help?

--=20
-----
Richard Quadling
"Standing on the shoulders of some very clever giants!"
EE : http://www.experts-exchange.com/M_248814.html
EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp
Zend Certified Engineer : http://zend.com/zce.php?c=3DZEND002498&r=3D213474=
731
ZOPA : http://uk.zopa.com/member/RQuadling

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php