Identity · Hybrid identity · Biira Bank

Enterprise IAM Lab: Hybrid Identity for a Regulated Bank

On-prem Active Directory with a tiered admin model, federated to Okta Workforce Identity and Microsoft Entra ID over SAML, OIDC and SWA, with network-aware conditional access and graduated MFA. Built to the regulatory drivers a real bank would have to satisfy, and now being rebuilt on a new forest from a written decision record.

Status
Phase 5 of 6 · rebuilding
Area
Identity
Period
2025 to present
Role
Design, build, operate, document
Stack
Active DirectoryWindows Server 2025Okta Workforce IdentityMicrosoft Entra IDSAML 2.0OIDCSWAOkta Expression LanguagePowerShellConditional AccessTerraform
Hybrid identity architecture diagram: network zones and authentication policies above Okta and Entra ID, with Active Directory on premises reached by the Okta AD Agent
Authentication flows top to bottom. A request is evaluated against the network zones first, then against the authentication policies in priority order. Okta is the primary IdP; Active Directory stays the source of record, reached by the AD Agent over outbound HTTPS only. Click to open full size.
35Accounts
20Organisational units
15Security groups
3Auth policy rules

The scenario

Biira Bank is a fictional state-chartered commercial bank: FDIC-insured, SEC-reporting, with the regulatory obligations that implies. Its identity architecture is not designed to a checklist of features but to the drivers a real bank would be examined against: GLBA safeguards, SOX separation of duties, PCI-DSS unique IDs and MFA for administrators, and the FFIEC’s 2021 authentication guidance on risk-based access. Every phase of the build names the regulation it answers.

The identity estate runs on the network documented in the sibling Enterprise Security Homelab; this project is the workload on top of it.

Architecture

Active Directory (corp.biirabank.com, on DC01, Windows Server 2025, VLAN 50) is the source of record for employee identity. The forest was rebuilt under that name in September 2026; the paragraph on version two below explains why, and what is still being restored on top of it. Okta Workforce Identity is the primary identity provider that applications federate to, reached through the Okta AD Agent over outbound HTTPS only, so nothing on the internet can initiate a connection to the domain controller. Microsoft Entra ID is the second cloud directory, planned for hybrid synchronisation and Microsoft 365 in Phase 6.

Authentication is evaluated in two layers. First the request is classified by network zone: an IP zone for the corporate network, a dynamic geographic zone for allowed countries, and a threat zone that recognises Tor exit nodes. Then the authentication policies apply in priority order, and the first match decides the assurance required:

  1. Restricted countries: deny.
  2. Public network: hardware-protected MFA.
  3. Corporate network: standard MFA.

What is built

  • Directory structure for a bank. Twenty organisational units, 27 employee accounts across six departments, 15 security groups, and a Microsoft-style tiered admin model (Tier 0 / 1 / 2) with seven hardened administrative accounts and the built-in Administrator disabled.
  • AD to Okta synchronisation with attribute mapping, OU-scoped user and group sync, a dedicated service account, and administrative accounts deliberately excluded from the cloud directory.
  • Application federation across protocol families. Dropbox Business over SAML 2.0 with automated provisioning and attribute mapping; Box over SWA with password vaulting; group-based assignment so access follows role, not individuals.
  • Dynamic groups with Okta Expression Language, driven by the AD country attribute, so a change in the directory changes application access without a ticket.
  • Network-based conditional access (Phase 5.1): three zones, three policy rules, tested with pilot users from both sides of the corporate boundary, with the flows recorded on video.
  • Regulatory traceability. Each phase guide names the driver it satisfies, from FFIEC IT examination requirements in Phase 1 to BSA/AML geographic controls in Phase 5.

Decisions worth explaining

Okta is primary, not Entra. A bank of this profile typically federates to a best-of-breed IdP and keeps Microsoft as one of several relying parties. Making Okta primary also forces the harder integration work (agent, attribute mapping, protocol variety) rather than the path of least resistance.

Admin accounts do not sync to the cloud. Tier 0 identity stays on the domain. If the cloud IdP is compromised, the blast radius stops short of the directory that everything else depends on.

Where you are changes what you must prove. Graduated MFA by network zone is more honest than a blanket policy: it pushes hardware-backed factors to the risky context (public networks) without punishing every corporate login, and it makes a deny-by-geography rule a first-class control rather than an afterthought.

Version two: a new forest, and a decision record first

The estate described above was built on ad.biira.online. That domain is being retired, and the public brand moved to biirabank.com, which left the directory named after something the bank no longer owns. Two other things happened at the same time. The Okta org was deleted for inactivity, which is what the free integrator tier does and is nobody’s fault but mine. And the first build had grown by accretion, without a written record of why any name was chosen.

So version two starts from a decision record, ADR-001, written before anything was touched.

The internal forest is corp.biirabank.com, not biirabank.com. A domain controller becomes the authoritative DNS server for its own domain name. Naming the forest after the public domain would have made the controller authoritative for the public zone, so the bank’s own website would have stopped resolving from inside the lab. The corp. prefix keeps the two namespaces apart, and a sign-in suffix means users still type name@biirabank.com and never see the internal name.

A rebuild, not a rename. Renaming a forest is supported and reboots every machine twice with no clean rollback, and that cost is the same whether the directory holds thirty-five accounts or thirty-five thousand. Exporting the directory, demoting the controller and promoting it into a new forest was the better trade at this size. The export was taken first, because the demotion is the one irreversible moment.

What this cost, honestly: every member machine lost its domain membership and has to rejoin, and the Okta directory agent points at a domain that no longer exists. What it bought: a directory rebuilt to a scripted baseline, a namespace that does not collide with the public site, and a written reason for both.

What is next

  • Rebuild the Okta org, configured with Terraform this time, so the tenant is a file in the repository rather than a sequence of clicks that cannot be replayed. Repoint the directory agent at the new forest.
  • Phase 5.2 to 5.5: adaptive, risk-based MFA; device trust and posture; privileged access management; behavioural analytics.
  • Phase 6: Entra ID hybrid synchronisation, seamless SSO and Microsoft 365, with federation decisions between Okta and Entra documented as a decision record.
  • Grow the endpoint estate on the homelab side so the identity policies have realistic workstations to protect. The first member workstation, WKS01, is joined and inside policy scope.
The build, chapter by chapter

Everything written so far, with the source one click away.

Every guide written so far, phase by phase. Each one opens on GitHub. The rebuild chapters live in the network repository, because the forest runs on that network. Anything not marked is current.

22 entries · 3 repositories

Start here

2 entries
Show all 2
  1. 0
    Biira Bank organisation profile (opens on GitHub)

    The fictional bank every decision is justified against: its size, its regulators, and the obligations that follow from them.

  2. PS
    Directory build scripts (opens on GitHub)

    The nine PowerShell scripts that create the organisational units, groups, tiered administrators and employee accounts, in the order they run. Passwords are prompted for, never stored.

Version two: the rebuild

3 entries

The forest moved to corp.biirabank.com in September 2026. These chapters record why and how.

Show all 3
  1. ADR-001
    Public domains and forest naming for the rebuild (opens on GitHub)

    Why the forest is corp.biirabank.com rather than the public name, how sign-in suffixes hide it from users, and what the old domain’s retirement costs.

    from enterprise-security-homelab

  2. 17
    Domain migration to corp.biirabank.com (opens on GitHub)

    Demote and repromote instead of a forest rename, a lockout after the promotion reboot and its recovery, and a directory rebuilt from an export and verified against it.

    from enterprise-security-homelab

  3. 18
    Public web presence and edge hardening (opens on GitHub)

    Hosting biirabank.com on Cloudflare Workers, a default-hostname bypass found by testing and closed, strict TLS and security headers, and the F to A+ evidence.

    from enterprise-security-homelab

Phase 1 · Foundation

1 entry

Phases 1 to 5 were written against the retired domain. The structure and configuration carried across to the new forest; the Okta tenant is being rebuilt with Terraform.

Show all 1
  1. 1.0
    Active Directory and the Okta tenant (opens on GitHub)

    Domain services on Windows Server 2025, split-brain DNS, and the integrator tenant the cloud half was built on.

    Version oneRead ↗

Phase 2 · Directory structure

2 entries
Show all 2
  1. 2.0
    Organisational structure for a bank (opens on GitHub)

    Twenty organisational units, the security groups Okta syncs, and employee accounts across six departments, mapped to separation-of-duties requirements.

  2. 2.1
    Tiered administrative accounts (opens on GitHub)

    Seven administrative accounts across three tiers, hardened so they cannot be delegated, and the built-in Administrator disabled.

Phase 3 · Okta integration

5 entries
Show all 5
  1. 3.0
    The Okta AD Agent and directory sync (opens on GitHub)

    Synchronising exactly the employee accounts and groups in scope, and keeping administrative accounts out of the cloud directory.

    Version oneRead ↗
  2. 3.1
    A dedicated sign-in subdomain (opens on GitHub)

    Moving the Okta custom domain off the primary name so the main domain stays free for the business.

    Version oneRead ↗
  3. 3.2
    Provisioning with AD as the source of truth (opens on GitHub)

    Which side owns which data, and the controls on what flows back to the directory.

    Version oneRead ↗
  4. 3.3
    Attribute mapping (opens on GitHub)

    The business attributes worth syncing, and the conditional logic for handling email addresses.

    Version oneRead ↗
  5. 3.4
    User lifecycle and staged import (opens on GitHub)

    Using Okta’s staged import so nobody gains access until someone decides they should.

    Version oneRead ↗

Phase 4 · Applications and groups

7 entries
Show all 7
  1. 4.0
    Phase summary (opens on GitHub)

    From directory sync to identity orchestration: dynamic groups, two application protocols and automated provisioning.

    Version oneRead ↗
  2. 4.1
    Dynamic groups with Expression Language (opens on GitHub)

    Group membership driven by a directory attribute, so a change in AD changes application access without a ticket.

    Version oneRead ↗
  3. 4.2
    SAML 2.0 with Dropbox Business (opens on GitHub)

    Single sign-on with certificate handling and automated provisioning, assigned by group.

    Version oneRead ↗
  4. 4.3
    SWA password vaulting with Box (opens on GitHub)

    Covering applications without federation support, and the browser plugin problems met on the way.

    Version oneRead ↗
  5. 4.4
    Automated provisioning (opens on GitHub)

    Account creation, updates and deactivation driven by the directory rather than by hand.

    Version oneRead ↗
  6. 4.5
    Testing and validation (opens on GitHub)

    End-to-end tests with real user scenarios across both protocols and provisioning.

    Version oneRead ↗
  7. 4.6
    Troubleshooting and operations (opens on GitHub)

    Monitoring, incident procedures and the fixes that keep the integration running.

    Version oneRead ↗

Phase 5 · Conditional access

2 entries
Show all 2
  1. 5.0
    Advanced authentication overview (opens on GitHub)

    The risk-based authentication the regulators ask for, and the five steps planned to deliver it.

    In progressRead ↗
  2. 5.1
    Network-based conditional access (opens on GitHub)

    Three network zones and three policy rules: deny restricted countries, demand stronger MFA on public networks, standard MFA at the office.

    Version oneRead ↗
Evidence

What it looks like when it is actually configured.

Screenshots from the build, named and captioned so each one can be traced to the configuration it proves.

Related writing

Notes from the same work.

All writing