SUPPORT-8755: Fix

This commit is contained in:
Eduard Tihomirov 2024-12-26 10:23:29 +03:00
parent 3c4ea9b3dd
commit 21ad3e9192

View file

@ -47,7 +47,7 @@ public class JwtAuthenticationFilter extends AbstractAuthenticationProcessingFil
throws AuthenticationException {
String browser = httpServletRequest.getHeader("User-Agent");
if (browser == null || !browser.contains("YaBrowser") || !browser.contains("Chromium GOST")) {
if (browser == null || (!browser.contains("YaBrowser") && !browser.contains("Chromium GOST"))) {
LOGGER.error("Invalid browser. Use YaBrowser or Chromium GOST");
return clearCookieAndSetStatus(httpServletResponse);
}