Authorization 오류 메시지 출력 변경 - 실제 사용하는 토큰헤더이름사용하도록 변경

This commit is contained in:
curry772
2026-04-17 09:42:13 +09:00
parent bebf5fa36d
commit 68cf1dff16
@@ -315,13 +315,13 @@ public class ApiAuthFilter implements HttpAdapterFilter {
if (StringUtils.isNotBlank(queryToken)) {
return queryToken.trim();
}
throw new JwtAuthException(ERROR_AUTHENTICATION_FAIL, "No have header info: Authorization");
throw new JwtAuthException(ERROR_AUTHENTICATION_FAIL, "No have header info: " + tokenHeaderName);
}
String[] components = authorization.trim().split("\\s+", 2);
if (components.length != 2) {
throw new JwtAuthException(ERROR_AUTHENTICATION_FAIL, "Malformat [Authorization] content");
throw new JwtAuthException(ERROR_AUTHENTICATION_FAIL, "Malformat [" + tokenHeaderName + "] content");
}
if (!StringUtils.equalsIgnoreCase(components[0], "Bearer")) {