Added socket abstraction.