Implement socks::handle_stream