-
Notifications
You must be signed in to change notification settings - Fork 607
Use a dedicated service user/subservice for Redirects Package creation and replication #3710
Description
Type
Improvement
Referenced issue
Background
The new replication approach is a good optimization because it avoids replicating each redirect rule individually.
However, it is not appropriate to grant authors/content admins broad access to all packages. In practice, this caused issues because editor/content-admin responsibilities are intentionally limited, and they typically do not have access to /etc/packages.
Problem
Current implementation can require UI users (authors/content admins) to have package-related permissions, which violates least-privilege and role separation.
Temporary workaround
Grant limited permissions for package creation/replication to unblock operations.
Proposed long-term solution
Implement package management via a dedicated system user + Sling subservice that performs package creation and replication on behalf of users:
- UI users trigger replication without direct /etc/packages access.
- Backend service performs package operations using service credentials.
- Keep user permissions scoped to redirect configuration only.
Acceptance Criteria
- Authors/content admins can replicate redirect maps without direct permissions to /etc/packages.
- Package creation/assembly/replication runs through a dedicated subservice and system user.
- Service user permissions are minimal and documented (least privilege).
- Existing redirect replication functionality remains unchanged from a user perspective.
- Audit/logging clearly shows actions executed by the service user.
- Tests cover success and failure paths for service resolver acquisition and replication flow.