Basic socket wrapper