Identify WCF Service client (intranet or internet)

Asked

Viewed 138 times

1

I wonder if it is possible to identify the call if a WCF Service on the server, if it was called by a client inside the network (intranet) or outside the network (internet).

I am implementing a data compression to be trafficked, but if the consumption was in the network I will traffic without compression.

I have case that the customer uses a notebook, when he is in the company is on the network (intranet), but when he goes home, consumes the service using the internet.

1 answer

0


With WCF you can identify the IP address of the client that is connected in your service, through the property RemoteEndpointMessageProperty. From the IP you can use some subnet-based rule to decide if the call is coming from the intranet or if it is an external call.

  • Thanks Carlos, I implemented the identification, now I’m going to go to the subnet calculations.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.