views:

353

answers:

3

I need to implement a remoting server in .NET C# and have the following requirements/restrictions for various reasons:

  • Use .NET remoting and NOT WCF
  • NOT hosted in IIS

There is no restriction on the version of .NET framework though (can be 3.5 if need be).

BUT: The server needs to be serving using HTTPS. I know I can do .NET remoting outside IIS with HTTP but how can I do HTTPS with the above requirements?

UPDATE: To clarify the requirements a bit further, I need to use SSL over any protocol for security reasons and port serve over port 80 for firewall reasons. I also need the protocol to be HTTPS so the deep inspection of packets on the firewall doesn't block the traffic. So using non-HTTP on port 80 is not quite the answer.

A: 

To leverage .Net remoting IIS is not mandatory, over config file (or even programmaticaly ) you can specify tcp:// to start listen/response over any IP port. In this case you just need to resolve issue how server will available for clients.

  • Create windows service
  • create console with infinite loop to handle incoming request.

IIS in case of remoting just works as service to host your dll, that is why you can replace it.

Dewfy
The question is about SSL and security which your answer doesn't address.
Khash
You don't need IIS. That is why you can serialize your object by any protocol, just crypt stream with asymmetric RSA.
Dewfy
Dewfy, thanks for the reply. That's exactly what I'm looking for: How to put my SslStream into the remoting framework on both server and client.
Khash
In MSDN look at example with IpcChannel - NO IIS, just a IPSec. IPSec - standard feature to provide secured way of Tcp communication (http://msdn.microsoft.com/en-us/library/aa302429.aspx)
Dewfy
A: 

Why not just use a TCP channel? Or if on the same machine IPC.

leppie
Can you comment on how to implement SSL on top of that please?
Khash
No, you cant. SSL is on top of HTTP, not TCP. You will need some other form of message/transport security. Not sure if SSH would work.
leppie
+1  A: 

I found the solution here: http://msdn.microsoft.com/en-us/magazine/cc300447.aspx

Khash