OfficialSPIProtocol Mapper / ClaimActive
keycloak-filtered-group-membership-mapper
byteworks-ch/keycloak-filtered-group-membership-mapper ↗
Group membership mapper with filtering.フィルタ付きグループメンバーシップマッパー
- ★
- 2
- Forks
- 1
- Contributors
- 1
- Updated
- 2026-04-21
- KC
- 26.6.0
- License
- Other (see repo)
What it can doできること2
- Work like the built-in Group Membership mapper, but drop groups whose path matches a regex before they go into tokens.標準のGroup Membershipマッパーと同じ動作で、正規表現に一致するグループをトークンから除外できる
- Configure it per client scope to hide internal groups from some clients and keep tokens small.クライアントスコープ単位で設定でき、内部用のグループを特定のクライアントから隠したり、トークンを小さくしたりできる
What it cannot do / limitsできないこと・制約3
- Filters group names (paths) only — not roles or attributes.絞り込めるのはグループ名(パス)だけで、ロールや属性は対象外
- Exclusion only (no allow-list); a wrong regex can expose or hide groups unexpectedly.除外指定のみ(許可リストは不可)。正規表現を誤ると、意図せずグループが露出したり隠れたりする
- Only affects token output — group assignments in Keycloak are unchanged.影響するのはトークンの出力だけで、Keycloak上のグループ所属は変わらない
Requirements前提条件
- Build the JAR, copy it to
providersand restart Keycloak.JARをビルドしてprovidersに置き、Keycloakを再起動