An Attempt Was Made To Access A Socket In A Way Forbidden By Its
|
On Tuesday, October 7th 2008 at 04:24 PM By ActivelyX |
|
I have written a web service that runs on IIS 6 on a server on our
intranet. I have written a vb.net client application that accesses web
methods in the web service on the remote server. It uses a client
proxy that was created with the wsdl tool. This is pretty standard
stuff.
I am logged in as a local administrator. The machine is running
Windows XP SP2.
The firewall is disabled on the client machine. I can access the web
service methods when I launch Internet Explorer. I can ping the web
server. I cannot access the web service from my vb.net application. I
get the following errors.
Unable to connect to remote server
An attempt was made to access a socket in a way forbidden by its
access permissions.
So I created a new code group in the Machine's Security Policy and
made its membership criteria my client application's strong name. I
copied the local intranet permission set. I added the Socket
permission (Connect via TCP). That didn't work.
So I changed the permission set to full trust. That didn't work
either.
Then I moved the code group to My_Computer_Zone. That didn't work.
Why can't I access a remote server running a web service on my
intranet from a vb.net application that uses a standard proxy that was
generated by wsdl? I can access the remote server using IE.
All of this code works when the client application is running on the
same machine as the web service. |
Re: An attempt was made to access a socket in a way forbidden by its by ActivelyX on Tuesday, October 7th 2008 at 06:43 PM
|
More details:
I created a test environment that is similar to that which is running
on our intranet.
I have an isolated network. One machine is running XP Pro SP3. The
server is running W2K3 SP2. Both machines have .Net Framework v 2.0.
I run the same code on each machine. The application works fine.
Something is not configured properly on the client machine on our
intranet. Note that I do have to use a remote desktop program called
"LogMeIn" to access the machines on our intranet.
I can access the web service with IE. I cannot access it with the
vb.net client application. I am a local administrator on the client
machine. |
Re: An attempt was made to access a socket in a way forbidden by its by ActivelyX on Wednesday, October 8th 2008 at 02:59 PM
|
McAfee firewall was blocking my connection request. The Windows
Firewall was off. I didn't know the Total Protection Service was
running. |