feat(mail): enforce owned profile self-service
This commit is contained in:
12
README.md
12
README.md
@@ -11,7 +11,7 @@ GovOPlaN Mail is the mail transport module. It owns reusable SMTP/IMAP profile m
|
||||
This repository owns:
|
||||
|
||||
- backend module manifest `mail`
|
||||
- mail permissions such as `mail:profile:read`, `mail:profile:write`, `mail:profile:use`, `mail:profile:test`, and `mail:mailbox:read`
|
||||
- mail permissions such as `mail:profile:read`, `mail:profile:write_own`, `mail:profile:write`, `mail:profile:use`, `mail:profile:test`, and `mail:mailbox:read`
|
||||
- SMTP/IMAP profile models, policy checks, encrypted credential storage, and profile resolution
|
||||
- SMTP send and IMAP append adapters, including mock transports for development
|
||||
- development mock mailbox endpoints used by test-send flows
|
||||
@@ -55,6 +55,16 @@ a non-secret audit event. Destructive module retirement applies the same rule
|
||||
to every remaining profile before any Mail table is dropped; a scrub or audit
|
||||
failure blocks retirement.
|
||||
|
||||
Personal profile self-service is a distinct authorization path. An actor with
|
||||
`mail:profile:write_own` can mutate only a user-scoped profile whose scope id is
|
||||
their current tenant membership id; `mail:secret:manage_own` applies the same
|
||||
ownership check to credentials. Neither scope permits profile-policy changes or
|
||||
management of tenant, group, campaign, system, or another user's profiles.
|
||||
Changing an SMTP/IMAP endpoint while a stored password remains is a secret
|
||||
operation and requires the matching credential permission. Deactivating a
|
||||
credential-free profile needs only profile-write authority; if a password will
|
||||
be scrubbed, credential authority is required and the deletion is audited.
|
||||
|
||||
## Development
|
||||
|
||||
Install through the core environment:
|
||||
|
||||
Reference in New Issue
Block a user