Match client and server's regex (in validation).