woensdag 17 februari 2010

SharpWired : Windows Service

Since the tech I use usually requires admin I decided to let it run as a windows service.

This service will have the following features:

  • Multiple ‘clients’ can connect through it (each having its own GnucCOM instance)
  • Multiple clients can connect to the same GnucCOM instance (if the client that initially created the object allowed it)
  • Extend previous with support for remote connections to the GnucCOM instance
  • Protection against abuse by verifying the following properties:
    • Session id
    • client id
    • Password (for attach)
    • Client ip:port check (+optional cookie check)
    • Allow Remote (or not)

All this code will be GPL but I ask that IF you use the windows service, and modify it, that you let it listen on another address (port)!

One not, since we use ip:port check for protection, this means that (in case you would want more) you need to create a new webclient instance PER ‘local client’! Looking into this some more…

Considering adding ‘cookies’ above the ip:port check to further refine the ability to detect who is who.

Added! Makes it more difficult though to call methods BUT I will make a Web API wrapper for that (might release the code, we’ll see)

Example:

using (ToolsAPI.CookieContext(core.InnerChannel, myCookie))
{
    Console.WriteLine(core.GetClientAddress());
}


Disadvantage : Only works using HTTP-based WCF services.

Geen opmerkingen:

Een reactie posten