T05 · Unauthorized Access and Privilege Escalation
- Location
hooks/humanos-guard/handler.ts:113- Finding
Mandate constraints are retrieved but never enforced
- Content
View full analysis
).blocked = true; (event.context as Record).blockReason = reason; } } else { console.log( `[humanos-guard] ALLOWED: ${toolName} — mandate ${result.mandate?.id} valid until ${result.mandate?.validUntil}` ); } ``` ### Technical Analysis The hook queries mandates using only a broad scope and tool name. It does not send a canonical representation of the proposed action, including critical attributes such as the payment amount, recipient, document identifier, destination account, or affected resource. Although the API response can contain `mandate.constraints`, the hook merely copies those constraints into the result object. It never compares them with the actual tool arguments before allowing execution. Consequently, any non-expired and non-rev ...[truncated 1442 chars]- Remediation
View remediation
