Forum Cross Platform with Xamarin
We are excited to announce that the Xamarin Forums are moving to the new Microsoft Q&A experience. Q&A is the home for technical questions and answers at across all products at Microsoft now including Xamarin!

We encourage you to head over to Microsoft Q&A for .NET for posting new questions and get involved today.

Client/server RPC over TCP/IP


I'm currently looking for a portable RPC framework for handling client/server communications on a local network.
The server will run on a Windows PC and the clients will be iOS and Android devices.

It seems that System.Runtime.Remoting is not supported on iOS and that System.ServiceModel.NetTcpBinding (needed for WCF over TCP/IP) is not available in Xamarin.

I know that the lack of run-time code generation on iOS makes the generation of proxy classes impossible, it's why the solution will probably involve ahead-of-time code generation.

Are there any already existing solutions for doing RPC over TCP/IP with Xamarin?


  • MihaMarkicMihaMarkic SI ✭✭✭✭

    Out of curiosity, why do you need tcp/ip? Is RESTful Web service out of question?

  • NurgoNurgo USMember

    Web services could be ok but the server must be easily installable without admin rights, which seems to be a problem for WCF web services. Do you have any good RESTful frameworks to suggest?

  • MihaMarkicMihaMarkic SI ✭✭✭✭

    AFAIK WCF server can be easily self hosted. And WebAPI as well. So, you can run them in console or something.

  • NurgoNurgo USMember

    Unfortunately, when I try to start a self-hosted WCF web service without admin rights, I get the following exception:
    AddressAccessDeniedException: HTTP could not register URL http://localhost:80/MyService/. Your process does not have access rights to this namespace (see for details).

  • MihaMarkicMihaMarkic SI ✭✭✭✭

    Is running an one time command using admin rights a problem for you?
    See this.

  • NurgoNurgo USMember

    Yes, the server have to be easily installable by the user, even if he has no admin rights. It's why I first tried to use NetTcpBinding which doesn't have this limitation, but NetTcpBinding is not implemented in Xamarin.

  • MihaMarkicMihaMarkic SI ✭✭✭✭

    you can still open a socket and send serialized (json perhaps) content forth and back. However even doing so the user would have to open the firewall on server side.

Sign In or Register to comment.