security: validate JSON metadata fields to prevent mass assignment #14
Labels
No labels
P1
P2
P3
PHP
agent-ready
bug
clotho
discovery
docs
epic
refactor
review
security
testing
athena
athena-gemini
audit
clotho
clotho-gemini
codex
darbs-claude
security
wiki
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: core/php-admin#14
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Issue
Models with JSON
metadatafields in$fillablearrays lack validation, risking large payloads or malicious data.Affected Models
Service Model (src/Mod/Hub/Models/Service.php)
Current:
Risk:
metadatais JSON column, can contain arbitrary dataHoneypotHit Model (src/Mod/Hub/Models/HoneypotHit.php)
Current:
Risk:
headersarray can be arbitrarily largeRecommended Fixes
1. Add Validation to Service Model
2. Add Validation to HoneypotHit Model
3. Add Input Validation Rules
In controllers/components that create these models:
Additional Concerns
Service::setMeta() Method (line 143-148)
Current:
Issue:
$keyis not empty$keydoesn't contain special charactersRecommended:
Testing Requirements
Priority
Medium - Defense-in-depth, not immediately exploitable but best practice.
Discovered by
Automatic codebase scan (issue #3)