diff --git a/src/main/java/it/finanze/sanita/fse2/ms/gtw/dispatcher/service/impl/JwtSRV.java b/src/main/java/it/finanze/sanita/fse2/ms/gtw/dispatcher/service/impl/JwtSRV.java index 31ee202..6895956 100644 --- a/src/main/java/it/finanze/sanita/fse2/ms/gtw/dispatcher/service/impl/JwtSRV.java +++ b/src/main/java/it/finanze/sanita/fse2/ms/gtw/dispatcher/service/impl/JwtSRV.java @@ -259,7 +259,7 @@ private ValidationException buildValidationException() { public void isValidLocality(String input) { - String regex = "^[a-zA-Z0-9]+[^\\^]*\\^\\^\\^\\^\\^\\&[^&]*\\&ISO\\^\\^\\^\\^[^\\^&]*$"; + String regex = "[a-zA-Z0-9]+[^\\^\\\\]*\\\\\\^\\^\\^\\^\\^\\&[^\\&]*\\&ISO\\\\\\^\\^\\^\\^\\[^\\^&]*$"; boolean isValid = Pattern.matches(regex, input); if (!isValid) { throw buildValidationException();