I\'ve been enamoured with component based programming (be it with COM, another system, or just using the paradigm in plain C++). It requires a bit of getting used to, if one is
I think you should take a look into VortexLibrary.
It is a complete BEEP implementation which provides a good foundation to develop any peer to peer application protocol. It already integrates authentication (using SASL) and secure connections (using TLS), both optionals.
Vortex also includes an implementation of the XML-RPC profile with an IDL compiler which should provide you with the enough foundation for the marshalling stuff....and the best is that you can later provide a more particular protocol, on top of the same session, to do binary transfer without being limited by XML-RPC.
It is programmed with C but also works with c++. Currently it is running, with regression tests ensuring its function under Linux, Windows and MAC.
Cheers!