Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / August 2004

Tip: Looking for answers? Try searching our database.

WSE 2.0 SP1 SoapClient/Service and NAT

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Christopher Crooker - 02 Aug 2004 00:21 GMT
I have been working with WSE 2.0 for a few weeks now and it works great when I use endpoints that are completely local (soap.tcp://localhost/...).  However, in my network environment I am behind a NAT router and I can't figure out how to get the client and service to communicate because WSE seems to be picky about addressing.

I have a dynamic DNS address that refers to the machine externally, and binding to that address as the SoapService's EndpointReference fails because the transport address cannot be associated with a local interface.  I have read alot of documentation, forums and blogs and tried many configurations to get this to work with differing results including a socket exceptiona because the connection is being actively refused and AddressingFaults of Destination Unreachable.

I have attempted to "manually" route the messages using Via, making the client anonymous by having the From field set to http://schemas.xmlsoap.org/ws/2004/03/addressing/role/anonymous, assign the correct adress to the SoapService using the SoapActor attribute, modify my router's port access (to ensure it wasn't an external problem) etc. and all to no avail.  It must be a WSE issue because I can connect to the SoapService from an external machine via telnet when I bind it to "localhost", but WSE can't communicate properly.

The bottom line question is: How can you use WSE 2.0 to start a service bound to a local interface address and then connect to that service using a different externally visible address?  Any help would be immensely appreciated.  (Just to clarify, there is only one NIC connected to a network.)

Thanks,
Chris
Hervey Wilson [MSFT] - 03 Aug 2004 17:17 GMT
Comments inline.

> I have been working with WSE 2.0 for a few weeks now
> and it works great when I use endpoints that are completely local
> (soap.tcp://localhost/...).  However, in my network environment I
> am behind a NAT router and I can't figure out how to get the client
> and service to communicate because WSE seems to be picky about addressing.

It is picky for security reasons, for example preventing cross-transport
message dispatch.

> I have a dynamic DNS address that refers to the machine externally, and
> binding to that address as the SoapService's EndpointReference fails because
[quoted text clipped - 3 lines]
> the connection is being actively refused and AddressingFaults of Destination
> Unreachable.

I assume that what you mean here is that your Router/NAT, not the actual
computer, has an external address and is then forwarding traffic on a
specific port to the machine behind the NAT? If so, you cannot bind the
SoapService on the computer to the IP address that is being used by the NAT
device, you must bind it to the IP address on the computer (presumably this
is an address in one of the private IP address ranges).

> I have attempted to "manually" route the messages using Via, making the client
> anonymous by having the From field set to
[quoted text clipped - 4 lines]
> SoapService from an external machine via telnet when I bind it to "localhost",
> but WSE can't communicate properly.

wsa:From is not interesting in this scenario, the important addressing data
is wsa:To and the Via used by the client. The SoapService should be
registered with a logical name and a Via that specifies the local machine,
for example urn:MyService / soap.tcp://<machinename>. Binding to localhost
won't help - the loopback interface is only accessible to processes on the
same computer, it is not routable.

The client should use wsa:To of urn:MyService and via of
soap.tcp://<router_dns_name>. This should cause the connection to be made to
the router that will then forward to the computer behind the NAT and the
message should be dispatched correctly. If not, we'll do some more
investigation.

> The bottom line question is: How can you use WSE 2.0 to start a service bound to a local interface address and then connect to that service using a
different externally visible address?  Any help would be immensely
appreciated.  (Just to clarify, there is only one NIC connected to a
network.)

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.