Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

RPC from Windows to linux

Is there some (working) example how to create RPC from windows to linux?

Client should be windows NT application, server is linux.

It needs to be MSRPC.

No Corba, no XML-RPC, SUN-RPC etc

MSDN says this:

RPC can be used in all client/server applications based on Windows operating systems. It can also be used to create client and server programs for heterogeneous network environments that include such operating systems as Unix and Apple.

Unfortunately after spending few hours on google I'm giving up.

My expectation:

  • Linux node should have samba installed, because their MSRPC implementation works.
  • Using IDL file I generate stubs for both client and server
  • Client is built using MSVC
  • Server is build using gcc with some includes/libraries from samba (or other libs)
  • Linux node must have such RPC port mapper

Can someone point me out?

like image 348
rkosegi Avatar asked Oct 26 '12 12:10

rkosegi


People also ask

Is RPC used in Linux?

Linux distributions provide an RPC version derived from the RPC facility developed by the Open Network Computing (ONC) group at Sun Microsystems.

Can Windows communicate with Linux?

If two people know the same language, they can talk with each other. Linux, Windows or let it be any Operating System which knows the language of communication protocols and then they can communicate using that protocols. There are multiple application layers like HTTP, SMTP and SMB which are layered on top of TCP.

What is RPC service in Linux?

Remote Procedure Call (RPC) is a protocol that programs can use to request services from other programs located on different computers. The portmap service controls RPC services by mapping RPC program numbers into DARPA protocol port numbers; it must be running in order to make RPC calls.


1 Answers

I think you have 2 possible ways to deal with this:

1- You can try using DCOM with wine, which means that you will actually write your code for windows, but at the same time you can test your results in the process and avoid using WinAPI calls that wine is not able to handle properly. This approach will allow you to generate stubs code from your IDL files.

2- You can try using Samba RPC Pluggable Modules, but I am afraid in this case the RPC communication will be more primitive.

Edit:

It seems there are many other ways. I found a list of libraries in DCOM-Wikipedia, j-Interop for example looks particularly promising.

like image 163
yms Avatar answered Oct 29 '22 22:10

yms