patch the socket module