Escape characters to pass the validation