docs(ldap): apply the 2026-11-15 independent review to the NAM cutover plan
Blockers: no-role-no-login family standard (OtOpcUa Phase A refuses empty and mapper-throws logins, reversing Login_when_role_mapper_throws_signs_in_with_no_role_claims; new ScadaBridge Phase A2); OtOpcUa validates only the FallbackServers + BindMode/UserBindTemplate rules (the library validator would block boot on DEV's empty ServiceAccountDn). Majors: inject the library logger; shared-account lockout model, no-lockout ask, value verification, canary, stop rule; DEV automation identity; rolling standby-first restarts for config-only; HG case-sensitive GroupToRole (optional Phase A3); mxgw config-bound cert pin. Minors and nits applied; review disposition table in section 11. Claude-Session: https://claude.ai/code/session_01GT67AFKC45MBz1wPZnVbX8
This commit is contained in:
+19
-5
@@ -22,7 +22,7 @@ role in each ZB.MOM.WW app.
|
||||
| **OtOpcUa** (AdminUI) | `Viewer`, `Designer`, `Administrator`. The DB-overlay enum is `AdminRole.cs`. The `DriverOperator` policy also honours `Operator` (`Security/ServiceCollectionExtensions.cs:201-202`), but only through config `GroupToRole`, not the DB overlay. | `Security:Ldap:GroupToRole`, unioned with the `LdapGroupRoleMapping` DB overlay (`OtOpcUaGroupRoleMapper.cs`) | `Dictionary<string,string>` (`Security/Ldap/LdapOptions.cs:84`) |
|
||||
| **ScadaBridge** | `Administrator`, `Designer`, `Deployer`, `Viewer`, `Operator`, `Verifier` (`Security/Roles.cs:45-56`). **Each policy requires its own role:** `Administrator` does not imply `Deployer` (`Security/AuthorizationPolicies.cs:190-202`). | the **`LdapGroupMappings`** table (database), plus `SiteScopeRules` for site scoping | **unique** `LdapGroupName` (`ConfigurationDatabase/Configurations/SecurityConfiguration.cs:26`), one `Role` per row |
|
||||
| **MxAccessGateway** | `Viewer`, `Administrator`. The validator rejects anything else (`GatewayOptionsValidator.cs:506-517`). | `MxGateway:Dashboard:GroupToRole` | `Dictionary<string,string>` (`Configuration/DashboardOptions.cs:69`) |
|
||||
| **HistorianGateway** | `Viewer`, `Administrator` (`Dashboard/DashboardRoles.cs`) | `Dashboard:GroupToRole` | `IReadOnlyDictionary<string,string>` (`Dashboard/DashboardOptions.cs:44`) |
|
||||
| **HistorianGateway** | `Viewer`, `Administrator` (`Dashboard/DashboardRoles.cs`) | `Dashboard:GroupToRole` | `IReadOnlyDictionary<string,string>` (`Dashboard/DashboardOptions.cs:44`), **case-sensitive once bound** (plan §2B) |
|
||||
|
||||
Things that are easy to get wrong:
|
||||
|
||||
@@ -31,8 +31,20 @@ Things that are easy to get wrong:
|
||||
the configuration UI.
|
||||
- **`Administrator` is the literal string in all four apps.** MxGateway's constant is named
|
||||
`DashboardRoles.Admin`, but its value is `"Administrator"`.
|
||||
- **Every app fails closed when no group matches.** An unmapped group grants nothing, so leaving a group
|
||||
out is the safe default.
|
||||
- **No role, no login: the family standard (DECIDED 2026-11-15).** Every app refuses sign-in, cookie **and**
|
||||
token, when the user's groups map to no role, including when the role lookup fails.
|
||||
- **Today only mxgw** (`DashboardAuthenticator.cs:66-70`) **and HG** (`:56-64`) **do this.**
|
||||
- **OtOpcUa** (`Security/Endpoints/AuthEndpoints.cs:124-158`, even when the mapper throws) **and ScadaBridge**
|
||||
(`CentralUI/Auth/AuthEndpoints.cs:59-115`) sign such a user in with no roles. Their read-only pages
|
||||
(`AuthenticatedRead` / bare `[Authorize]`) would then be open to any AD user.
|
||||
- The cutover plan's Phase A (OtOpcUa) and A2 (ScadaBridge) fix this **before** either app is pointed at NAM.
|
||||
- Once fixed, an unmapped group grants nothing, so leaving a group out is the safe default.
|
||||
- **`Viewer` in OtOpcUa means "holds a role, so may sign in".** No OtOpcUa policy checks `Viewer`; its read pages
|
||||
only require an authenticated user. Under the standard above, being signed in requires *some* mapped role, so
|
||||
the `Viewer` cells (§4) are what grant AdminUI read access.
|
||||
- **HistorianGateway matches group names case-sensitively** in practice. The binder replaces its
|
||||
`OrdinalIgnoreCase` default with a plain `Dictionary` (cutover plan §2B). **Copy group names exactly as
|
||||
LdapProbe prints them** in every app.
|
||||
|
||||
## 2. Why one role per group
|
||||
|
||||
@@ -119,7 +131,8 @@ the interim `svc_igntadmin@nam.zimmer.com`, with the Ignition team's agreement.
|
||||
|
||||
```bash
|
||||
dotnet run --project tools/LdapProbe -- --insecure --svc '<svc account UPN>' -g 'UG_WW_*' # families + counts
|
||||
dotnet run --project tools/LdapProbe -- --insecure --svc '<svc account UPN>' --self-bind <sAMAccountName> # one person's groups
|
||||
dotnet run --project tools/LdapProbe -- --insecure --svc '<svc account UPN>' -u <sAMAccountName> # one person's groups (service-account path)
|
||||
dotnet run --project tools/LdapProbe -- --insecure --self-bind -u <sAMAccountName> # the same, binding as that person (--svc ignored)
|
||||
```
|
||||
|
||||
**Blast radius** (08-12 counts):
|
||||
@@ -150,7 +163,8 @@ dotnet run --project tools/LdapProbe -- --insecure --svc '<svc account UPN>' --s
|
||||
## 7. Prerequisites
|
||||
|
||||
1. **Auth library on every deployed build: met.** 0.4.1, and 0.5.0 for ScadaBridge (cutover plan §1.1).
|
||||
2. **OtOpcUa must pass `FallbackServers` through** before its cutover (cutover plan §2).
|
||||
2. **OtOpcUa must pass `FallbackServers` through and refuse zero-role logins** before its cutover (cutover plan §2).
|
||||
ScadaBridge must refuse zero-role logins before its cutover (§2A).
|
||||
3. **New AD groups and memberships come by ServiceNow ticket.** `UG_WW_APP_DEPLOY_{DEV,QA}` is the first
|
||||
(D6), and the dedicated service account is scadaproj#58.
|
||||
4. **Verify with real accounts** (§5) before rollout. The 08-12 inventory came from one architect
|
||||
|
||||
Reference in New Issue
Block a user