Skip to main content

Warden - Getting started

Transaction approval, change control and activity/read auditing for Dynamics 365 Finance & Operations. This guide takes an administrator or implementer from nothing installed → a first working policy, in the order the steps have to happen. Every setting it mentions is described field by field in Configuration reference. For concepts, personas and the blocking doctrine, see User guide; for every screen, Form reference; for the batch jobs, All batch processes.

What Warden does, in one line: where native change management restarts whole approval cycles (or doesn't reach at all), Warden classifies each field change - log it, tolerate it within a band, re-approve just the delta, or block it - places holds alongside native statuses, and routes native workflow work items. "Policy-intended gates block. The four named seams fail closed on an internal error" (the purchase order line and header seams and the two warehouse cycle-count seams), "because failing open there would let ungoverned stock or postings through." Elsewhere a Warden malfunction is meant to pass through and be attested.

Warden has five packages: A - Control Policies & Delta Re-approval (the platform foundation), B - Order & Journal Governance, C - Count Governance, D - Activity & Read Audit, and E - Evidence & Compliance Reporting.

1 Prerequisites what the environment needs before anything is installed
2 Install add Warden to source control and deploy it with your build
4 Verify the install the pages are there and the database is synchronised
5 Initialize once in EVERY legal entity, `dat` included
5a Number sequences the Warden module's four references
5b SoD rules one to create, one optional
5c Feature toggles one per area; six of seven start off
6 Workflows fifteen types; the ones you use must be configured
6b Batch jobs nothing is scheduled for you
7 Roles and security who holds what, and the integrations' identities
7b Environment settings production versus sandbox, per legal entity, copy-config
7c Validate Warden setup gaps, then the first-policy check
8 First policy compose, simulate, submit, see it govern

1. Prerequisites and dependencies​

1a. Dynamics 365 version​

Warden is compiled against Application 10.0.2527.196 and Platform 7.0.7858.163 (the 10.0.47 line). Install it on an environment at that build or later. Compiling against a platform newer than the target is the classic cause of a package that deploys cleanly and then fails at runtime with a missing-method error, and nothing in the build can detect it.

1b. Standard modules​

Warden adds side tables only: it extends no standard table, role, duty or security policy. Its descriptor (Descriptor/MGCWarden.xml) references 25 standard Microsoft modules, all part of a standard Finance and Operations installation: ApplicationCommon, ApplicationFoundation, ApplicationPlatform, ApplicationSuite, ApplicationWorkspaces, CaseManagement, CDSVirtualEntity, ContactPerson, Currency, Dimensions, Directory, ElectronicReporting, FiscalBooks, GeneralLedger, InboundTransportationManagement, Ledger, PersonnelCore, Policy, Project, Retail, SourceDocumentation, SourceDocumentationTypes, Tax, UnitOfMeasure and UserSecGov.

1c. The licensing module​

The package includes a licensing module; deploy it with the product and do not change it.

Usage counts. Once Warden is initialized (§4), it sends Magicite a daily count of how it is used: API calls, license refusals, simulations, audit events stored and evidence packs, each by a fixed name such as an operation or a pack type, never with records, users or companies. To stop it, set Usage telemetry enabled to No on System administration → Setup → Magicite → License parameters.

1d. License​

Warden reads its license from the Magicite licensing service, or from Entitlement expiry on Warden guard parameters when the service has no answer. A lapsed or unverifiable license warns: a row on Warden setup gaps and a warning when a Warden parameters page opens. On an environment the licensing service treats as production, once the environment is past its license block date, changing policy setup and building new evidence packs stop; holds, approvals and audit capture never do. Every other environment type only warns. The license clock starts when Initialize Warden first runs (§4); with no license stored, Warden warns for 14 days and blocks on production from day 15. Have the license arranged with Magicite before you initialize a production environment. To check the license now, run System administration → Setup → Magicite → License refresh. The details, and what stays open past the block date, are in Configuration reference.

1e. Feature management​

Each Warden area is a feature in Feature management, and six of the seven are off until you turn them on (§4c). Nothing is governed while a feature is off.

1f. Platform services some areas use​

ServiceNeeded forWithout it
Batch (the batch server)Every Warden batch job (§5b)Drains, sweeps, the audit writer and the rest never run
Workflow, including the platform's workflow message processingEvery Warden approval: all fifteen workflow types are native workflowsWork items and approval outcomes are not delivered
Key Vault parameters and an Azure Blob containerOnly a certified audit purge that exports before it deletesNo such purge can be proposed or executed
Electronic reportingOnly rendering evidence packs in a regulator formatThe text and HTML binders still work
Case management, with its case ID number sequenceThe duplicate requisition sweep files each finding as a native caseThe sweep records the finding in the governance event log and files an execution exception instead
Database log configuration key and table loggingThe change-history check on Sensitivity Register entries (setup-gap rules 6 to 9)Setup-gap rows; read capture itself is unaffected
Electronic signature (SIG configuration key, reason codes, a certificate per approver)Only policies that require an electronic signatureThe approval completes unsigned and the governance event log says why
Business eventsOnly if you set a Publish business events switchNothing is published; Warden's own alerts are in-client only and it sends no email

1g. Who does the setup​

Deploy Warden to your environment with your next build. Then an account with the System administrator role runs §3 to §5b. Everything Warden adds is named MGCWarden*; it is the Auditor half's tables that read MGCWardenAudit*, not every Auditor element. Search on MGCWarden* to find everything.


2. Install​

Add Warden to your source control and deploy it to your environment with your next build. The steps for sandbox, UAT, production and a unified developer environment are in the install guide. The package includes a licensing module; deploy it with the product and do not change it.

3. Verify the install​

Sign in as an administrator. Every Warden page is on System administration → Setup. The ones you need for setup:

Menu labelMenu itemWhat it is
Warden ControlsMGCWardenControlsWorkspaceThe guard workspace, with a Setup gaps tile
Warden AuditMGCWardenAuditWorkspaceThe audit workspace
Initialize WardenMGCWardenInitializeMenuItemOne-time initialization per legal entity (§4)
Warden setup gapsMGCWardenSetupGapsWhat is missing or wrong (§6c)
Warden guard parametersMGCWardenParametersMenuItemRetention, tolerance unit, break-glass, degrade-to-warn, license date
Warden audit parametersMGCWardenAuditParametersMenuItemCapture, anchoring, purge export, audit alerts
Warden audit compliance parametersMGCWardenAuditComplianceParametersMenuItemSensitive-role alerts, deprovisioning SLA, pack export
Count governance parametersMGCWardenCountParametersMenuItemRecount cap, case retention, MISSING alerts
Guard control policiesMGCWardenPolicyTableThe policy composer (§7)

All 82 entries on that menu, with what each does, are in Form reference.

Every change to a Warden parameter is evidence. Saving Warden guard parameters, Warden audit parameters, Warden audit compliance parameters or Count governance parameters - on the form, through their data entities, or from code - writes one Self-audit row per changed field into the audit store, naming the field, the old and new value, and who saved it. It cannot be switched off. Creating the records with their shipped defaults (Initialize Warden, or the first read in a new company) writes nothing; deleting one is recorded as the reset to defaults it causes.

Nothing there? Menu items are hidden without an entry-point permission. Assign Warden guard administrator (MGCWardenGuardAdministrator) or sign in as a System administrator.


4. Initialize (once per company)​

Run System administration → Setup → Initialize Warden as an administrator once in every legal entity, including ones Warden governs nothing in and the platform's dat. An erasure (D11) reads every legal entity and first checks that it can read each one's Warden parameters; it refuses, naming the legal entity, while one has none, whichever account asks. Warden setup gaps lists every legal entity without them under the code ERASURE. Run Initialize Warden again in any legal entity created later. It is safe to run again at any time.

What it does, in order (MGCWardenInitialize.main):

  1. Creates the guard parameters record for this legal entity with the shipped defaults, if it does not exist (retention windows, default tolerance unit Percent, a 4-hour break-glass grant). The other three parameter records are created the first time anything reads them.

  2. Seeds the shipped Sensitivity catalog: suggestions you can enrol from. It enrols nothing and captures nothing. The catalog is shared, so one run covers the environment.

  3. Puts every role that grants break-glass release (MGCWardenBreakGlassReleasePriv) on Sensitive roles, so a break-glass grant alerts like any other sensitive grant. Warden ships no break-glass role, so on a fresh install this adds nothing and says so. Create your break-glass role (§6), then run Initialize Warden again. It adds a role only when the list has no row of that name and never edits a row that is there; to take a role off the list, set its Effective to date rather than deleting the row, because a deleted row is added back on the next run. A warning that the privilege is not in this environment's security metadata means the database was not synchronized.

  4. Does the same for every role that grants identity resolution (MGCWardenIdentityResolvePriv). Warden ships that role, Warden identity resolver, so the first run adds it.

  5. Upgrades approved-value baselines written before work item 1304, and fills a break-glass grant duration left at zero by earlier builds. Both are no-ops on a fresh install, and both act on this legal entity only (see reminders 5 and 6 below).

  6. Registers Warden with the licensing service, which starts the license clock (§1d).

  7. Prints the entitlement line (which license source answered, and what it says), a warning if the license has lapsed, and six reminders:

    1. run the number sequence wizard (§4a);
    2. optionally, the author ≠ activator SoD rule, for reporting only (§4b);
    3. configure a workflow for each of the five policy activation types (§5);
    4. define the audit retention classes the shipped catalog suggests - FIN8Y, PRIV3Y, GXP10Y, PCI1Y - before activating any Sensitivity Register entry enrolled from it or proposing a purge. Retention horizons are a customer decision, so Warden names them and never creates them; define them on Audit retention classes;
    5. on an upgraded deployment, run MGCWardenBaselineScopeUpgrade once for all legal entities;
    6. on an upgraded deployment, run MGCWardenBreakGlassGrantFill once for all legal entities, and review standing break-glass role assignments where the duration had been zero.

    Neither class in reminders 5 and 6 has a menu item; each loops every legal entity itself, so run it once from any company with https://<environment>/?mi=SysClassRunner&cls=<class name>.

4a. Generate number sequences​

Warden registers its own number sequence module, Warden, with four references: Policy code, Hold ID, Diff set ID and Exception ID, each per legal entity. Run the wizard: Organization administration → Number sequences → Generate, and accept the Warden references, in each legal entity.

Holds, diff sets and execution exceptions draw from their sequences. Policy codes do not: the reference is registered, but nothing draws from it, and the author types the code when creating a policy.

Skipping this does not break capture - MGCWardenIdGenerator falls back to a prefix (WH, DS, EX) and a GUID fragment, so ID assignment never blocks a write (blocking doctrine). But do run the wizard; sequential IDs are what auditors expect to see. Exceptions written out of band always use the fallback, by design (Configuration reference).

If you will use sales governance's duplicate requisition sweep, also make sure Case management's case ID number sequence is set up: the sweep files each finding as a native case.

4b. Create the SoD rules​

Create native segregation of duties rules (System administration → Security → Segregation of duties → Segregation of duties rules) for these conflicts:

ConflictWhy
MGCWardenAuditAdministrationDuty × MGCWardenAuditInquiryDutyCreate it. The auditor must not administer the register and retention they audit (WRD-005)
MGCWardenPolicyAuthoringDuty × MGCWardenPolicyActivationDutyOptional, for reporting only. Policy author must not activate, but the rule is not what enforces it

Author ≠ activator is not carried by that rule. By design: "Author != activator is enforced by Warden's X++ gate on every approve channel. A native SoD rule is optional and used for reporting only." The gate refuses, on the in-client and the API approve channels alike, an approver who submitted the version, for all six activation families - the five policy families and the Sensitivity Register. Purge proposer ≠ approver is likewise enforced in code.

4c. Enable the feature toggles​

Every Warden process area but one ships default OFF in Feature management; with a toggle off, that area does zero evaluation and zero capture on new work - users see no change at all until something has already been governed. A toggle is an entry-point switch, not a stop button: read the boundary note below before you switch one off in a live environment. There are seven toggles - seven feature classes, one per row of the table below - and six of the seven return false from isEnabledByDefault; Trade Agreement Governance is the single exception and the note after the table says why. If the Warden features are not listed yet, run Check for updates on the Feature management workspace (feature metadata registers on demand, not at module load). Enable per area, per environment, deliberately:

FeatureFeature management moduleArea
Warden Order Guard (MGCWardenOrderGuardFeature)Procurement and sourcingPO change interception, holds, delta/excluded-class routing, firming gate
Warden Sales Governance (MGCWardenSalesGovFeature)Sales and marketingSO/quotation thresholds, duplicates, reconfirmation, price lock
Warden Trade Agreement Governance (MGCWardenTradeAgreementGovFeature)Sales and marketingPrice-floor guards on trade agreement journals, the submit-for-approval action, the retroactive/overlapping effective-date step, the approval sweep. ON by default, and it is the only one that is - see the note below
Warden Journal Governance (MGCWardenJournalGovFeature)Inventory and warehouse managementPosted-journal immutability, line-cost bands, attachments, reversal workflow
Warden Count Governance (MGCWardenCountGovFeature)Inventory and warehouse managementCount review cases, recounts, quarantine, consolidation
Warden Auditor (MGCWardenAuditFeature)System administrationRead capture sensors (double-gated with the Sensitivity Register) and the purge proposal generator. Form Access and Report grains are wired; Entity/OData is not supportable in this build and Deep Record ships dark
Warden Evidence & Compliance (MGCWardenAuditReportingFeature)Compliance and internal controlsTimeline, evidence packs (assembly, export and ER rendering), role capture, deprovisioning scan

Trade agreement governance split out, and it starts ON. Until this change the four trade-agreement classes read MGCWardenSalesGovFeature, so enabling sales order governance silently enabled price-journal gating and a customer could not have one without the other. They now read MGCWardenTradeAgreementGovFeature. Its default is ON, which is deliberate and is a migration decision rather than a product default: anyone already running with Sales Governance on has trade agreement gating live today, and defaulting the new toggle off would have switched an enforcing control off silently at upgrade rather than avoided a change. If you had Sales Governance ON and do not want price-journal gating, switch this one off - that is the case this toggle exists for. If you had Sales Governance OFF, the trade agreement classes now run but cannot refuse anything until you author a price-guard policy: with no active policy the evaluator resolves nothing for any scope and only writes evidence rows.

Switching a toggle OFF: what happens to work already in flight. A toggle stops the entry points - the seams that classify an edit, measure a threshold or capture an access. It does not reach backwards. Rows cut while the feature was on are still there, and what happens to them differs by area, because whether the enforcement seam also consults the toggle differs by area:

Toggle offIs a document already held still blocked?Is its approval still raised?
Order GuardYes. The purchase confirm, receipt, invoice, print and emit gates deliberately do not consult this toggle. A held PO stays unconfirmable.Yes, by every route - a confirmation attempt, Retry from the exception workbench, and the delta and firming route drains, which run regardless of the toggle.
Sales GovernanceNo. The fulfillment, send, confirm and emit gates all test this toggle first, so a held order is no longer refused.No. MGCWardenSalesGovRouteRetry stands down, and the sales governance policy sweep records a Skipped run.
Trade Agreement GovernanceNo. The write and posting seams test the toggle, so a gated journal is no longer blocked.No. Neither MGCWardenTARouteDrainBatch nor MGCWardenTARouteRetry raises one - both stand down with the toggle.
Journal GovernanceNo. The delete, copy and posting seams test the toggle.No. MGCWardenJournalRouteDrainBatch and MGCWardenJournalRouteRetry both stand down with the toggle.
Count GovernanceNot applicable - counts raise cases, not holds on native documents.Not applicable.

The rule, and every seam now follows it: raise the owed approval while the feature is off if and only if the document is still actually blocked while the feature is off. Where it stays blocked, refusing to raise the approval strands it. Where it is not blocked, raising the approval asks somebody to decide about a document that is already free to proceed.

What changed if you are upgrading. The delta and firming drain batches now run with Order Guard off, so purchase orders that had been sitting held on such an installation start acquiring the approval work items they were always owed. The sales and trade-agreement retry handlers now stand down, so approval work items that used to appear when an operator pressed Retry on those areas stop appearing while the toggle is off; the exception row closes as handled. Neither direction can leave a document ungoverned. Switching a toggle off in a live environment is still best done drained - confirm there are no open holds and no Pending routes first.

Purge approval and Sensitivity Register activation are gated by no toggle at all, and that is deliberate. Both are separation-of-duties controls, and a duties control that one person can switch off is not a duties control. Warden Auditor gates capture and the proposal generator, so with it off no new scheduled purge proposal is raised; a proposal already made still needs two signatures.

Evidence & Compliance stands down visibly. MGCWardenAuditReportingFeature is consulted by the timeline, the pack builder, the exporter, the ER renderer, role capture and the deprovisioning scan, each recording a ReportingFeatureOff self-audit row rather than failing silently. On deprovisioning the toggle gates the scan only: entries already proposed stay workable.


5. Configure the fifteen workflow types​

Warden registers fifteen native workflow types, all in the Warden workflow category (module System administration) - verified against MGCWarden\AxWorkflowTemplate\ on 2026-11-06. Configure each one you use in the workflow editor, in each legal entity where it is used (full native mechanics - hierarchy, escalation, delegation, completion policies). Warden's own refusal names the place as System administration > Workflow. A Submit with no enabled configuration in the current legal entity is refused: "… has no enabled workflow configuration in this company, so there is nothing to submit to. Nothing was changed…".

Workflow typeTemplateUsed forRequired when
Warden policy activationMGCWardenPolicyActivationTemplateActivating a core control policy versionAlways: no guard policy can leave Draft without it
Warden sales governance policy activationMGCWardenSalesGovPolicyActivationTemplateActivating a sales governance policy versionYou use sales governance
Warden price guard policy activationMGCWardenPriceGuardPolicyActivationTemplateActivating a price guard policy versionYou use trade agreement governance
Warden journal policy activationMGCWardenJournalPolicyActivationTemplateActivating a journal policy versionYou use journal governance
Warden count policy activationMGCWardenCountPolicyActivationTemplateActivating a count policy versionYou use count governance
Warden register activationMGCWardenRegisterActivationTemplateSensitivity Register changes (author ≠ activator)You capture reads
Warden delta approvalMGCWardenDeltaApprovalTemplateRe-approving a change diff on a governed documentA blocking guard policy routes
Warden excluded-class change approvalMGCWardenExcludedClassApprovalTemplateChanges on DD / intercompany / TMS-loaded POsA policy governs those classes
Warden firming approvalMGCWardenFirmingApprovalTemplateOver-threshold planned-order firmingsA firming policy routes
Warden sales governance approvalMGCWardenSalesGovApprovalTemplateSO/quotation threshold breachesA sales policy routes
Warden trade agreement approvalMGCWardenTAApprovalTemplateTA/price journal gatingA price guard policy routes
Warden journal reversal approvalMGCWardenJournalRevApprovalTemplateReversing a posted inventory journalA journal policy requires reversal approval
Warden journal banded reviewMGCWardenJournalReviewTemplateBand-driven journal review; step conditions read MGCWardenJournalGovState.RequiredStepTagA journal policy has a stepped band
Warden dual-control purge approvalMGCWardenPurgeApprovalTemplateSecond signatory on audit-store purgesYou purge the audit store
Warden erasure approvalMGCWardenErasureApprovalTemplateThe second person's approval of an erasure request (D11 phase 5)You use erasure

The activation workflows are not optional if you use those families. Every runtime gate that consumes a policy filters on Status == Active, and Status is not editable on any of the policy tables - so activation is reachable only through these workflows. Configure the activation workflow for each family you intend to use, or that family's guards are built and permanently unable to fire. Assign each to an approver who does not hold MGCWardenPolicyAuthoringDuty.

Three rules for the configurations themselves, each reported on Warden setup gaps when broken:

  • Mark one configuration of each type as the default, or resolution depends on activation conditions alone (rules 45 and 46).
  • Do not let escalation approve a step that a policy requires to be signed (rule 62): a deadline would approve with nobody's signature.
  • The erasure approval: assign it to the controls owner or another approver who does not hold the identity resolver role. Warden refuses an approver who raised the request, and an approval completed by escalation or a time limit approves nothing. The same is true of the purge approval: a completion with no person's Approve action purges nothing.

5b. Schedule the batch jobs​

Nothing schedules any Warden batch job for you. No installation step, and not Initialize Warden, creates a batch job or a recurrence, and Warden defines no batch group. Every job is on System administration → Setup; open it, set Run in the background, give it a Recurrence, and press OK. The table below is every Warden batch job (25 RunBaseBatch classes, verified 2026-11-06; Initialize Warden and Refresh shipped sensitivity catalog run at once and are not batch jobs). For what each does in detail, and for problems once it runs, follow its link. Warden batch framework covers what all of them share, and Standard batch and periodic processes with Warden installed the standard periodic processes Warden changes.

Required means a control or a piece of evidence does not work without it. Toggle names the feature the job stands down for (it logs or records that it did nothing); a dash means it runs whatever the toggles say. Scope says where to schedule it: each legal entity means one job in every legal entity that uses the area, because the job reads only the legal entity it runs in; one job means a single job for the environment, because it works on shared tables.

Batch job (menu label)ProcessRequiredToggleScopeIf it is never scheduled
Warden delta route drainroute-drainsYes, if a blocking guard policy routes. Every 5 minutes (below)-Each legal entityA changed PO that nobody tries to confirm again sits held with no work item, so no approver can clear it. Setup gaps: ROUTEDRAIN
Warden firming route drainroute-drainsYes, if a firming policy routes-Each legal entityA firming the run's own end-of-run drain missed leaves the PO held with no approver. FIRMDRAIN
Warden trade agreement route drainroute-drainsYes, if a price guard policy routesTrade Agreement GovernanceEach legal entityNothing unattended raises the approval a gated journal owes; it stays unpostable until someone presses Retry. TADRAIN
Warden journal route drainroute-drains, journal-reversal-routerYes, if a journal policy has a stepped bandJournal GovernanceEach legal entityA journal posted through a nested caller (warehouse counting, ITM, Rental, BOM report-finish, kit assembly) is refused for ever, because nothing else puts it in front of an approver. JOURNALDRAIN
Warden break-glass grant expirybreak-glass-expiryYes, once a break-glass role exists-One job. Role assignments are environment-wide, and a run measures every grant against the grant duration of the legal entity it runs in, so two jobs with different durations apply the shorter to everybodyEmergency grants never expire. A grant lives up to the duration plus one batch interval. BREAKGLASSEXP from the moment a role carries the break-glass privilege
Warden retention cleanupretention-cleanupRecommended-Each legal entityNothing is purged on the retention windows: holds, exceptions, run records, and diff sets and event-log rows past the evidence floor
Warden setup-gap snapshotsetup-gap-snapshotOptional-Each legal entityThe workspace Setup gaps tile shows a stale count, or zero where it never ran. The page itself always recomputes
Sales governance policy sweepsales-governance-sweepRecommended, with sales governanceSales GovernanceEach legal entityAfter a threshold is tightened, an open document keeps its old verdict until its content changes, and an order refused on an automated posting route is not routed until someone acts on it
Trade agreement approval sweeptrade-agreement-governance-sweepRecommended, with trade agreement governanceTrade Agreement GovernanceEach legal entityAfter a floor is tightened, an approved but unposted journal still posts under the old rule
Warden duplicate requisition sweepduplicate-requisition-sweepRecommended, if a sales policy detects duplicate requisitionsSales GovernanceEach legal entity; one run covers every legal entity when a policy asks for cross-company detectionDuplicates the save-time check cannot see (orders unchanged since the policy became active, saved while Sales Governance was off, or saved under Warn) never become audit cases
Count consolidation runcount-consolidationYes, with count governanceCount GovernanceEach legal entityAccepted count deltas never become a counting journal, which is their only posting path
Aged-MISSING monitormissing-queue-monitorYes, with count governanceCount GovernanceEach legal entityQuarantined MISSING entries past their SLA never age onto the write-off queue and nobody is alerted
Count case retention cleanupcount-retentionRecommended-Each legal entityClosed count cases are never purged
Audit queue writeraudit-writerYes, if you capture reads-One jobCaptures never reach the audit store, and overflow drops are never counted or alerted. AUDITWRITER
Guard event ingestionaudit-guard-ingestionYes, for governance evidence in the audit store-Each legal entityGovernance events are never forwarded to the audit store and age out of the event log at the evidence floor. GUARDINGEST
Audit chain integrityaudit-integrity-verificationYes, if you use the audit store-One jobNothing is anchored or verified, and no anchor reaches the feed. ANCHORFEED. Schedule it at the Anchor cadence target (24 hours shipped)
Audit health monitoraudit-health-checkRecommended-One jobHealth rules are never evaluated and nobody is alerted to writer lag, queue depth or drops. Its first run seeds three default rules. AUDITHEALTH once a rule is enabled
Role event captureaudit-role-captureYes, with Evidence & ComplianceEvidence & ComplianceEach legal entityRole grants and revocations are not recorded and no sensitive-role alert is sent. ROLECAPTURE
Role event retentionaudit-role-event-retentionRecommended-Each legal entityForwarded role events past their floor are never purged. ROLERETENTION
Evidence pack builderevidence-pack-builderAs neededEvidence & Compliance; also skipped past the license block dateEach legal entityNo packs. Its dialog takes a fixed period, so a recurring job rebuilds the same period. EVIDENCEPACK until a run completes
Propose audit store purgeaudit-purge-proposalsOptional: proposals can be raised by handAuditorOne jobNo scheduled proposals. Its dialog requires an Accountable proposer, an enabled user
Execute approved audit purgesaudit-purge-executionYes, once you purge-One job, in any legal entityAn approved purge stays approved for ever and deletes nothing. PURGEEXEC
HR deprovisioning scandeprovisioningYes, with Evidence & ComplianceEvidence & ComplianceEvery legal entity that employs peopleNo legal entity proposes its leavers. DEPROVISIONING
Deprovisioning overdue monitordeprovisioning-overdue-monitorYes, where the deprovisioning queue is used-Each legal entityAn entry past its SLA alerts nobody. DEPROVISIONING
Execute due erasureserasure-executionYes, if you use erasure-One jobApproved and due erasures are never carried out. ERASUREEXEC. Only the Warden identity resolver role can run it

The delta drain carries a timing promise, and this is it: no more than five minutes between a change being held and its approver seeing a work item. Schedule MGCWardenDeltaRouteDrainBatch on a 5-minute recurrence. That number is a service-level promise, not a technical default, and it is deliberately not a customer parameter - an interval long enough to make the delta loop feel broken is itself the defect, and exposing it invites a deployment to set one and then report the consequence as a bug. The other three drains take an interval you choose; for each, the interval is the maximum time a held document waits with nobody asked to decide it.

Why an approval can lag the edit at all. The hold is placed inside the edit's own transaction, so it commits or rolls back with the edit and the document is gated the instant the change lands. What is deferred is the workflow activation and the HoldPlaced business event, which are raised at the next transaction-free point: the next confirmation attempt, or this batch. Nothing can escape governance in the gap - the hold is already standing and the purchase gates already refuse the document. What is new is approver-queue latency, bounded by the recurrence you set.

Two of the four drains ignore their feature toggle and two stand down with it, and the split follows the §4c rule exactly. The delta and firming drains run regardless of the Order Guard toggle, because the purchase gates take no feature test and a held order is refused whether Order Guard is on or off. The journal and trade agreement drains stand down and log it, because with those toggles off nothing refuses the document.

What Warden setup gaps notices. It watches the schedule of fourteen of these jobs: the four drains, Execute approved audit purges, HR deprovisioning scan, Deprovisioning overdue monitor and Audit queue writer, Guard event ingestion, Role event capture, Role event retention, Audit health monitor, Execute due erasures and Warden break-glass grant expiry. Each shows a row only while its area is in use. A drain shows a row when it has no recurring job and work is waiting; with nothing waiting, only while its area is in use; and when it is scheduled but work has waited 4 hours. Audit chain integrity is watched through the anchor feed it publishes, once a feed destination is set. No rule notices that any other job is missing: the sweeps, the count jobs, the cleanups, the snapshot, the pack builder and the purge proposals (Warden batch framework).

A failed run can still read Ended. Most Warden batches catch their own failures, record them as execution exceptions and finish normally, so batch job history alone does not show that a run failed. Check System administration → Setup → Execution exceptions as well (Warden batch framework).

One job per class. The audit queue writer, Audit chain integrity and Propose audit store purge refuse to run while another task of the same class is running in any legal entity; Role event capture, the HR deprovisioning scan and the duplicate requisition sweep refuse within their legal entity. Two jobs of one of these classes refuse each other, so schedule one each, per legal entity where the scope says so.

Who can schedule them. Scheduling starts from the job's menu item, so the person who schedules a job needs its privilege: the four drains, the cleanups, the snapshot, break-glass expiry and the count jobs are on the Warden guard administrator role; the three sweeps on the Warden controls owner; the audit jobs on the Warden audit administrator (the pack builder on the Warden auditor too); erasure execution on the Warden identity resolver. The account a job runs under is stamped on what it records, including as the originator of every workflow a drain raises. Security model has the privilege behind each.


6. Assign roles​

Warden ships seven roles - seven AxSecurityRole elements, one per file in MGCWarden\AxSecurityRole\, which is how to re-derive the number if this section ever drifts again. Five of them are the governance roles. The other two are special-purpose: a deployment can finish its Warden setup without assigning either. The labels below are the ones Assign users to roles shows. Security model has every duty and privilege behind them.

The five governance roles​

RoleGrants
Warden guard administrator (MGCWardenGuardAdministrator)Policy authoring + simulate (all guard surfaces incl. B/C policies), inquiry, exception processing, route recovery. Cannot activate policies and does not hold break-glass
Warden controls owner (MGCWardenControlsOwner)Policy activation approval, inquiry, exception processing, the document approvals as a reachability floor, purge second signatory, erasure second signatory (approves erasure requests by reference, without vault access; D11 phase 5). Does not author policies and does not hold break-glass
Warden count supervisor (MGCWardenCountSupervisor)Count case processing + inquiry. May propose a write-off and never approve one
Warden audit administrator (MGCWardenAuditAdministrator)Sensitivity Register, retention classes, purge proposal, audit parameters, health, evidence pack build and export. Cannot approve purges
Warden auditor (MGCWardenAuditor)Read-only audit inquiry + evidence pack execution (SoD: conflicts with Audit Administrator)

The two special-purpose roles​

RoleGrants
Sales order viewer / production order creator (MGCWardenSalesOrderViewer)Read on every sales order and line, plus Create of a production order from a line (ProdTableNew). Governs nothing. ProdTableNew carries MaintainUserLicense=Activity, so a user holding only this role prices as Activity, not Team Members
Warden identity resolver (MGCWardenIdentityResolver)Turns a Warden subject reference (WP-…) into the person behind it and back, shows names beside codes, raises, submits and executes erasure requests (it cannot approve one). Ships assigned to nobody (D11)

Who should hold the sensitive grants​

  • Break-glass release (MGCWardenBreakGlassReleasePriv) ships on no duty and no role. Create a role of your own that carries it, then run Initialize Warden again so the role goes on Sensitive roles and every grant of it alerts. Grant it to a named person for an incident only, and let Warden break-glass grant expiry take it away after Break-glass grant duration (hours) (4 shipped, 168 at most) - which happens only if that job is scheduled (§5b). Set Break-glass alert recipients so each release is seen. Neither the controls owner nor the guard administrator role holds it, by design. See User guide.
  • Warden identity resolver: assign it to a named person for a named task, such as a data subject's request, and remove it afterwards. Every grant alerts and every lookup is recorded in the audit store. Do not give it to the person who approves erasure requests: Warden refuses an approver who raised the request.
  • Other privileges that ship in no role - duplicate-requisition override, count write-off (and its approval duty), deprovisioning disposition, leaver intake and leaver intake withdrawal - are listed, with whom each should go to, in User guide and Security model.

Assign the SoD-conflicting roles (§4b) to different people, and keep policy authors and activation approvers apart even though the gate enforces it.

Entra applications for the API and integrations​

Warden publishes six custom services in the service group MGCWardenServices (MGCWardenWorkItemService, MGCWardenPolicyLifecycleService, MGCWardenGuardOperationsService, MGCWardenCountOperationsService, MGCWardenAuditOperationsService, MGCWardenBatchService) and 71 data entities. An integration that calls them, or an HR system that writes leaver records to the WardenAuditLeaverIntakes entity, signs in as a Microsoft Entra application:

  1. Register an application in Microsoft Entra ID for the integration, with a client secret or a federated credential. Note its application (client) ID - <client-id> here; never put a real one in a document.
  2. In D365, System administration → Setup → Microsoft Entra applications, add <client-id> and map it to a dedicated D365 user, <integration-user>. The application acts as that user: its roles decide what it may do, and it is the identity recorded in every governance event.
  3. Give <integration-user> only the role the integration needs. For the HR leaver intake, attach MGCWardenLeaverIntakeDuty to a role made for that user alone, never to a role a person holds.
  4. Set the user's default company: a service operation runs in the caller's session company.

One application per identity: Warden's controls are about who acts, so an integration that submits and one that approves must not share a user.


6b. Environment-specific settings​

Production versus sandbox and UDE​

Warden's own code does not ask what kind of environment it is in. One thing differs by environment anyway:

SettingProductionSandbox, UAT, UDE
License block datePast the license block date, policy setup and new evidence packs stop; holds, approvals and capture carry onWarns only, never blocks. The licensing service decides the environment type; an environment it cannot classify is treated like UAT

Everything else is the same on every environment, and is set in each: the feature toggles (§4c), the workflows (§5), the batch jobs (§5b) and the license fields.

Most Warden configuration is per legal entity: the guard, compliance and count parameters, the policies, signing limits, sensitive roles, device-user mapping, evidence pack templates, re-approval exclusions, number sequences and workflow configurations. Shared by every legal entity: Warden audit parameters, the Sensitivity Register and catalog, audit retention classes and audit health alert rules. The full table is Configuration reference.

After a copy-config or a database copy​

  • Entitlement expiry and No license source are not carried by the Warden guard parameters data entity. Set them in each environment.
  • The three degrade-to-warn switches and both alert lists are carried, so a target can arrive with enforcement already degraded. Review them.
  • Warden audit parameters carries Export container, Export secret name and Export secret company. A sandbox that receives production's values points its purges at production's container through whatever secret reference that name finds there. Review them.
  • Evidence pack ER format mapping is not carried; set it where you render packs.
  • A source file that omits a numeric parameter column imports it as zero: several refuse zero, and the refusal says to add the column.

6c. Validate the setup​

Warden setup gaps​

Open System administration → Setup → Warden setup gaps in each legal entity. Every row says what cannot work and what to do about it; a row about a policy version shows its code and version, any other row an area code such as ROUTEDRAIN with version 0. The page is computed when it opens, so reopen it after a fix. The Setup gaps tile on the Warden Controls workspace counts the last snapshot instead and can lag.

Screenshot to add: Warden setup gaps in a newly initialized legal entity, showing a LICENSING row and a ROUTEDRAIN row with their Gap text.

A clean page means that, in that legal entity, Warden found nothing it can detect that stops a control, a recovery or a piece of evidence from working as configured. It does not mean the configuration suits your business, and it cannot see every omission: several batch jobs have no rule watching their schedule (§5b). A few rows state a boundary rather than a fault and cannot be cleared by a setting; on a fresh environment expect the license row (LICENSING) until the license is in place. Every one of the 87 rules, what raises it and how to clear it, is in Configuration reference.

The first-policy check​

§7 is the last check: a policy you compose, simulate and activate should hold a governed purchase order you then edit, with a diff set, a hold and event-log rows to show for it.


7. Day one - your first policy​

  1. Compose. Guard control policies → New: type a policy code, pick a document family (e.g. Purchase order), gated event, posture; add scope lines (Table/Group/All over items × vendors); classify fields on the Field change matrix tab (log-only / tolerance / re-approve-delta / block). For a purchase family, choose the invoice posture too, or Warden setup gaps asks you to (rule 32).
  2. Simulate. Click Simulate, choose a history window; review the impact report in Policy simulation results. Three counts, all real and all disjoint - each in-scope document lands in exactly one, under the strongest gate the policy would apply to it: Would have been blocked outright (a Block-class field in your matrix: the user's save is refused, no hold, no approval path), Would have routed for approval (the edit stands, the document is held and routed - the user is delayed, not refused) and Would have been logged only. They count only the orders your version would govern if it were active: an order your scope covers that another policy code's active version would win is listed as Governed by another policy, naming the winner, and counted apart under In scope, governed by another policy. An order where your version and another code's tie (equally specific scope, same priority) is listed as Ties with another policy (Submit refuses) and counted apart again; fix the tie before you submit. The run is resolved against the policies in force on the day your version would take effect - its Effective from date, or today when that is blank or past - and the message names that day. A version whose Effective to date has already passed is not simulated at all, nor is one whose Effective to falls before its own Effective from, which cannot be saved either. The run's Basis line states what the counts do and do not measure; read it before you quote them. Still scope coverage, not replayed edits: per-edit tolerance-band crossings need diff history that accrues only once governance is on.
  3. Submit for activation. The Warden policy activation workflow routes it to a Controls owner (not you - SoD). On approval the version goes Active; any prior active version is Superseded. If you gave the version an Effective from date in the future, approval leaves the prior version in force until the day before that date and the new one Takes effect on it - the policy form's In force column shows which is which. Submit and activation refuse a version that would tie with another active policy over the same scope at equal specificity and priority . On a production environment past its license block date, Submit is refused (§1d).
  4. Edit a governed PO inside scope (with Warden Order Guard on) and watch the diff set, hold, and event-log rows appear. If the policy routes, the approver's work item arrives within the delta drain's five minutes (§5b).
  5. Reopen Warden setup gaps. A new Active policy is where rules 28 to 32 look; the page should still be clean.

Where to next​