feat(ssf): 增加连接操作审计与追踪证据

安全事件连接的成功和运行时失败现在写入脱敏审计,响应携带 Trace ID 与 Audit ID,管理页面展示最近一次成功操作证据。审计仅记录连接状态、健康模式和错误类别,不采集授权头、Token、Bearer 或 Secret。\n\n验证:HTTP API、Store、Security Events Go 测试以及 Web Vitest、TypeScript 类型检查通过。
This commit is contained in:
2026-07-16 10:55:21 +08:00
parent 42ddc70b27
commit 2ccf041b35
4 changed files with 138 additions and 20 deletions
@@ -471,6 +471,8 @@ function SecurityEventConnectionPanel(props: {
<span>Stream ID: {connection.streamId ?? '正在创建'}</span>
<span>: {securityEventHealthLabel(connection.healthMode)}</span>
<span> Verification: {connection.lastVerificationAt ? new Date(connection.lastVerificationAt).toLocaleString() : '尚未成功'}</span>
{props.connection?.traceId && <span> Trace ID: {props.connection.traceId}</span>}
{props.connection?.auditId && <span> Audit ID: {props.connection.auditId}</span>}
{connection.lastErrorCategory && <span>: {connection.lastErrorCategory}</span>}
</div>
<div className="fileStorageToolbar">