The event loop and TCP wrappers for the black box framework