Deploying and Executing code on a remote machine via Remoting/WCF?

The important thing to remember here is that WCF can be used to transfer data but not to tranfer execution logic You can send the result of an addition from one end to the other, but you cannot send some arbitary instruction (like adding or whatever) and let the other end magically execute it In other words, if you have a WCF client on the remote end, you could send it your DLL file (as a binary data ), and the client could then dynamically load and execute it using reflection (but what's without mentioning all the obvious security and compatibility concerns this would raise). Another maybe easier option would be to send scripts instead of compiled code, and execute them with some interpreter on the server side. But whatever trick you use, you'll need to do a lot of work outside of WCF as sending instructions is not the objective of WCF.

The important thing to remember here is that WCF can be used to transfer data, but not to tranfer execution logic. You can send the result of an addition from one end to the other, but you cannot send some arbitary instruction (like adding or whatever) and let the other end magically execute it. In other words, if you have a WCF client on the remote end, you could send it your DLL file (as a binary data), and the client could then dynamically load and execute it using reflection (but what's without mentioning all the obvious security and compatibility concerns this would raise).

Another maybe easier option would be to send scripts instead of compiled code, and execute them with some interpreter on the server side. But whatever trick you use, you'll need to do a lot of work outside of WCF as sending instructions is not the objective of WCF.

Sending binary data and reflecting it is exactly what I had in mind. How is sending scripts and interpreting them any more secure than sending binary data? – liortal May 20 at 12:28 I was talking about scripts more because of interoperability than security, if you need to communicate between a windows and BSD box for example, or environments with different versions of the framework.

That depends on your environment and needs. – Shtong May 20 at 13:06 luckily for us, all machines are in a Windows environment, and all have the . NET framework installed.

– liortal May 20 at 13:09.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions