fix: 修复工作流公共 API 调用问题

- 限制远程文档仅访问公网地址并校验重定向目标

- 统一访问令牌 401/403 与过期执行状态 404 语义

- 校正节点查询参数和工作流状态文档
This commit is contained in:
2026-07-31 11:27:37 +08:00
parent 1cbee6b018
commit 41b056b7e3
12 changed files with 953 additions and 33 deletions

View File

@@ -25,8 +25,9 @@ public class PublicApiInterceptor implements HandlerInterceptor {
String requestURI = request.getRequestURI();
String apiKey = request.getHeader("ApiKey");
if (apiKey == null || apiKey.isEmpty()) {
if (apiKey == null || apiKey.isBlank()) {
Result<Void> failed = Result.fail(401, "密钥不正确");
response.setStatus(HttpServletResponse.SC_UNAUTHORIZED);
ResponseUtil.renderJson(response, failed);
return false;
}