Make cookie banner origin immutable after creation

Origin is a fundamental identity property of a banner tied to consent
records for a specific site. Changing it would break the audit trail
and violate GDPR consent specificity requirements.

Signed-off-by: Émile Ré <emile@getprobo.com>
This commit is contained in:
Émile Ré
2026-04-24 17:46:00 +04:00
parent 4ec075fa80
commit 11f856740a
5 changed files with 1 additions and 16 deletions

View File

@@ -392,7 +392,6 @@ func (b *CookieBanner) Update(
UPDATE cookie_banners
SET
name = @name,
origin = @origin,
state = @state,
privacy_policy_url = @privacy_policy_url,
consent_expiry_days = @consent_expiry_days,
@@ -410,7 +409,6 @@ WHERE
args := pgx.StrictNamedArgs{
"id": b.ID,
"name": b.Name,
"origin": b.Origin,
"state": b.State,
"privacy_policy_url": b.PrivacyPolicyURL,
"consent_expiry_days": b.ConsentExpiryDays,