kof22 prod (0.1.0-RC.7) shows authentik.mapper DEGRADED with only "Mapper drift detected" and findingCodes=group_attributes.warning. Nothing says which group or why.
The likely cause in kof22: the file-gateway-admins group grants file_gateway.connect, file_gateway.view and file_gateway.admin. qbit-file-gateway checks those names only in code. They are not in the instance's permission metadata, so they are not in the resolver catalog. The mapper reports them as "grants nothing" and does not grant them. That is a real gap, and this PR does not fix it; it is tracked separately. A group with no qqq.io/* attributes, such as kof22-admins on its static floor, was never flagged.
What
DriftFinding gets an optional reason: a short, safe summary for health outcomes. A 4-argument constructor keeps every existing call site.
The group-attribute findings set reasons:
grants nothing: <permission>. The permission name must match [A-Za-z0-9_.*-]{1,120}; otherwise it shows as (unprintable name).
malformed <attribute>. This gives the attribute name only, never the typed value.
superuser group carries qqq.io/permissions.
The authentik.mapper outcome message is now Mapper drift: <group> (<reasons>); ..., cut to 500 characters. New details: flaggedGroups and summary, alongside the existing findingCodes.
Service-account activity subjects (people) stay private and appear only as service-account activity (see the identity drift report). A group check that cannot run appears as group attributes check could not run.
The "grants nothing" drift message notes that a name an app checks only in code is not in the catalog.
Tests
AuthentikHealthChecksTest.mapperStates:
A group with no attributes is UP.
Unknown, malformed and superuser findings produce the exact message and details.
Typed values and person subjects never appear.
mapperOutcomeEdges covers a check that cannot run, control characters, unnamed groups, and the 500-character and 4 KiB bounds.
## Why
kof22 prod (`0.1.0-RC.7`) shows `authentik.mapper` DEGRADED with only "Mapper drift detected" and `findingCodes=group_attributes.warning`. Nothing says which group or why.
The likely cause in kof22: the `file-gateway-admins` group grants `file_gateway.connect`, `file_gateway.view` and `file_gateway.admin`. qbit-file-gateway checks those names only in code. They are not in the instance's permission metadata, so they are not in the resolver catalog. The mapper reports them as "grants nothing" and does not grant them. That is a real gap, and this PR does not fix it; it is tracked separately. A group with no `qqq.io/*` attributes, such as `kof22-admins` on its static floor, was never flagged.
## What
- `DriftFinding` gets an optional `reason`: a short, safe summary for health outcomes. A 4-argument constructor keeps every existing call site.
- The group-attribute findings set reasons:
- `grants nothing: <permission>`. The permission name must match `[A-Za-z0-9_.*-]{1,120}`; otherwise it shows as `(unprintable name)`.
- `malformed <attribute>`. This gives the attribute name only, never the typed value.
- `superuser group carries qqq.io/permissions`.
- The `authentik.mapper` outcome message is now `Mapper drift: <group> (<reasons>); ...`, cut to 500 characters. New details: `flaggedGroups` and `summary`, alongside the existing `findingCodes`.
- Service-account activity subjects (people) stay private and appear only as `service-account activity (see the identity drift report)`. A group check that cannot run appears as `group attributes check could not run`.
- The "grants nothing" drift message notes that a name an app checks only in code is not in the catalog.
## Tests
- `AuthentikHealthChecksTest.mapperStates`:
- A group with no attributes is UP.
- Unknown, malformed and superuser findings produce the exact message and details.
- Typed values and person subjects never appear.
- `mapperOutcomeEdges` covers a check that cannot run, control characters, unnamed groups, and the 500-character and 4 KiB bounds.
- `AuthentikDriftReportTest.malformedReasonKeepsOnlyTheAttribute`.
- `./mvnw verify -DskipITs` passes locally.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Why
kof22 prod (
0.1.0-RC.7) showsauthentik.mapperDEGRADED with only "Mapper drift detected" andfindingCodes=group_attributes.warning. Nothing says which group or why.The likely cause in kof22: the
file-gateway-adminsgroup grantsfile_gateway.connect,file_gateway.viewandfile_gateway.admin. qbit-file-gateway checks those names only in code. They are not in the instance's permission metadata, so they are not in the resolver catalog. The mapper reports them as "grants nothing" and does not grant them. That is a real gap, and this PR does not fix it; it is tracked separately. A group with noqqq.io/*attributes, such askof22-adminson its static floor, was never flagged.What
DriftFindinggets an optionalreason: a short, safe summary for health outcomes. A 4-argument constructor keeps every existing call site.grants nothing: <permission>. The permission name must match[A-Za-z0-9_.*-]{1,120}; otherwise it shows as(unprintable name).malformed <attribute>. This gives the attribute name only, never the typed value.superuser group carries qqq.io/permissions.authentik.mapperoutcome message is nowMapper drift: <group> (<reasons>); ..., cut to 500 characters. New details:flaggedGroupsandsummary, alongside the existingfindingCodes.service-account activity (see the identity drift report). A group check that cannot run appears asgroup attributes check could not run.Tests
AuthentikHealthChecksTest.mapperStates:mapperOutcomeEdgescovers a check that cannot run, control characters, unnamed groups, and the 500-character and 4 KiB bounds.AuthentikDriftReportTest.malformedReasonKeepsOnlyTheAttribute../mvnw verify -DskipITspasses locally.🤖 Generated with Claude Code