added: multi-platform socket wrapper