Skip to content

About

Identity, credential and access platform shaped by DND's CAF ICAM project: Keycloak MFA, OpenBao certificates, OPA ABAC for web, servers and badge doors, hash-chained audit

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

ICAM Testbed: identity, credentials and access for 300 people

An identity, credential and access management (ICAM) platform shaped by the public description of the Canadian Armed Forces Identity, Credential and Access Management Project: unique identities for every person and device, a central identity broker, credential management, central authentication and authorization policy, logical and physical access control, and integrated monitoring, auditing and reporting.

Independent personal research by Taki Sadik. Not affiliated with, funded by, or submitted to DND or the CAF. Every person, badge and document is synthetic. Project page: https://tyfsadik.org/work/defence/identity-credential-access-management

HR file (source of truth) ──icamctl jml──► OpenLDAP ──federation──► Keycloak (broker, MFA, sessions)
                                                                    │ OIDC
                       ┌───────────────────────────┬────────────────┼──────────────────┐
                 mission app                Grafana            icam-cli ──JWT──► OpenBao
                 (OIDC + OPA, back-channel   (SSO, role          (60 s tokens)      SSH user CA ──► srv1, srv2
                  logout)                      mapping)                             SSH host CA     (cert-only, KRL)
                       │                                                            device PKI ──► badge readers
                       └──────────── OPA (policy as code) ◄──── door controller ◄──mTLS── reader (Pi + PN532)
every component ──► audit collector (one record shape, SHA-256 hash chain) ──► Loki ──► Grafana "Access Audit"
CAF ICAM requirement Here
Unique identity for each person and device HR file → OpenLDAP; unique uid, service number, badge; devices get OpenBao certificates and directory entries
Centralized identity data broker Keycloak 26 federating the directory
Credential management OpenBao 2.1: SSH user and host certificates, device PKI, revocation; TOTP and WebAuthn in Keycloak
Central authentication and authorization policy Keycloak (MFA, lockout, sessions) and OPA (RBAC + ABAC policy as code)
Centralized logical access control web app, Linux servers (SSH certificates), Grafana, all through the broker
Integrated physical access control door controller on the same identities and policy engine; readers prove identity with certificates
Integrated monitoring, auditing, reporting hash-chained audit log, Loki, Prometheus, Grafana dashboard, access review report

Results (local rehearsal, final run)

Check Result
People, badges, service numbers 300 people, all unique; directory and Keycloak in step
MFA authenticator enrolled at first sign-in; password alone refused; wrong code refused; 65 people enrolled in the run
Web app decisions (RBAC + ABAC) vs an independent oracle 390 of 390 agree (44 allowed); median 3.1 ms per request
Door decisions vs the oracle 280 of 280 agree; unknown badge refused; reader without a certificate refused
Revoked badge reader refused 0.0 s after revocation (controller refresh pushed)
SSH sysadmin certificate works on both servers as admin; staff refused an admin certificate; operator certificate refused as admin; host verified by CA, no trust-on-first-use; certificate key ID names the person
Brute force 5 wrong passwords lock the account (correct password refused); unlocked after 29.2 s
Leaver: web session, new sign-in, existing SSH certificate, door all gone 0.98 s after the HR change
Leaver: an already-issued CLI token at OpenBao refused after 64.72 s (60 s token life + 5 s leeway)
Mover: log -> intel coalition threat assessment 403 before, 200 after signing in again
Grafana single sign-on security officer Admin, sysadmin Viewer, staff refused
Audit 2018 records, hash chain intact; every source present: keycloak 322, keycloak-admin 39, openbao 157, opa 1191, door 286, ssh 16, lifecycle 6, mission-app 1

Access Audit dashboard after the run

Everything the rehearsal found and fixed: docs/04-findings.md.

Quick start

./local/rehearse.sh up     # about 5 minutes: 300 people, Keycloak, OpenBao, OPA, doors, servers, monitoring
./local/rehearse.sh test   # the scenarios; results/rehearsal/report.json and access-review.md

Docs

  1. Physical setup: Raspberry Pi badge reader, door strike, hardware keys
  2. Deploy
  3. Before anything real
  4. What the rehearsal found

Repository map

icam/          organisation generator, directory (JML), Keycloak and OpenBao as code, audit records
policies/      OPA policies (mission app, doors) with tests
services/      audit collector, mission app, door controller, reader client
hardware/      Raspberry Pi badge reader (PN532 + relay)
stacks/        docker compose, OpenBao, Prometheus, Loki, Grafana, Linux server image
tools/         icamctl (seed, configure, jml, devices, report), access review, server join, dashboard
local/         rehearsal script and the end-to-end scenarios
tests/         unit tests
results/       rehearsal runs

MIT licence.

About

Identity, credential and access platform shaped by DND's CAF ICAM project: Keycloak MFA, OpenBao certificates, OPA ABAC for web, servers and badge doors, hash-chained audit

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages