The Connect Health AgentKey is the secret value used by the Microsoft Entra Connect Health agent during authentication. It is stored protected on the host, but if disclosed it can be used to obtain tokens and access publishing paths associated with the monitored hybrid identity environment.
Expanded Definition
Connect Health AgentKey is not a general-purpose account secret; it is the authentication secret that ties a Microsoft Entra Connect Health agent to the monitored environment and lets that agent request tokens for its publishing and health-reporting functions. In practice, it sits closer to a machine credential than to an ordinary application setting.
The important boundary is that the AgentKey is operationally sensitive because it authorises a trusted monitoring path, not because it grants broad interactive user access. If it is copied, cached, logged, or left on an unmanaged host, the compromise moves from “monitoring credential” to “usable trust anchor.” That makes secret handling, host protection, and revocation behaviour central to the term’s meaning.
Definitions in the industry are usually consistent here, but implementation detail matters: the secret may be protected on the host, yet still exposed through backups, endpoint access, or administrative tooling if lifecycle controls are weak. For a deeper NHI lifecycle view, NHIMG’s Ultimate Guide to NHIs frames why machine-held secrets need explicit ownership and rotation.
Examples and Use Cases
Connect Health AgentKey appears anywhere a Connect Health agent must authenticate back to Microsoft Entra and maintain trusted telemetry or publishing access. Typical environments include hybrid identity monitoring, sync health reporting, and administrative validation of agent connectivity.
- A directory team installs a new Connect Health agent on a server and binds it with an AgentKey so the service can publish health data without human sign-in.
- An operations team restores a host from backup and must confirm whether the AgentKey survived in the image, configuration export, or recovery tooling.
- A security engineer reviews endpoint and privileged-access logs to verify that the secret is not exposed through scripts, package caches, or deployment artifacts.
- An identity administrator replaces a server or rebuilds the agent and needs to re-establish trust cleanly rather than reuse an unknown copied secret.
The tradeoff is convenience versus containment: keeping the key available simplifies agent continuity, but expanding where the secret is stored increases the number of places an attacker or insider could recover it. That is why the monitoring path itself should be treated as a controlled credentialed dependency, not just a service setting.
Security Implications
If a Connect Health AgentKey is disclosed, the attacker or unauthorised operator can impersonate the agent’s trusted publishing identity and obtain access tokens associated with the monitored hybrid identity path. That turns a single secret into a foothold for trust abuse inside a visibility and control channel.
The failure mechanism is familiar across non-human identities: a secret is extracted from disk, memory, backup, pipeline output, or administrative tooling, then reused before it is rotated or revoked. The result may not be immediate domain takeover, but it can create false telemetry, concealment of real health issues, or misuse of the agent’s publishing permissions.
Practitioner observation matters here: monitoring secrets are often overlooked because they are not used by people, yet compromise of a low-visibility machine secret can undermine confidence in the whole reporting path. NHIMG research shows that 79% of organisations have experienced secrets leaks, with 77% of these incidents resulting in tangible damage, which is directly relevant to this class of credential exposure.
Domain and Governance Relevance
In hybrid identity governance, the AgentKey is a small object with outsized trust significance because it supports a service that bridges on-premises infrastructure and cloud identity operations. That means the key’s lifecycle should be governed like any other machine credential: owner, storage location, rotation path, and revocation trigger all matter.
For NHI programs, the term is a practical reminder that non-human identities are not limited to service accounts or API keys. Health agents, publishing agents, and identity connectors all introduce secrets that must be inventoried and controlled with the same discipline as workload identities. The relevant governance question is not “who can log in?” but “what process keeps this agent credential confined, rotated, and recoverable when the host changes?”
Where organisations rely on hybrid directory telemetry, this secret becomes part of assurance for monitoring integrity. If the AgentKey is unmanaged, the organisation may still receive reports, but it no longer has strong confidence that the reporting path is authentic.
Risk and Threat Considerations
The material risk is compromise of a trusted machine credential that can be reused to impersonate the Connect Health agent. Because the secret anchors a publishing and token-acquisition path, disclosure can create both access abuse and monitoring integrity loss.
Failure mechanism: The key is recovered from protected storage, backup media, logs, deployment artifacts, or an overprivileged admin workstation, then replayed before revocation or rotation closes the window. This is a recognised secret-theft pattern for non-human identities.
Impact: Attackers or unauthorised operators may gain access to publishing paths, distort health visibility, and inherit trust in a monitoring channel that defenders expect to be genuine.
Standards & Framework Alignment
This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.
OWASP Non-Human Identity Top 10 and MITRE ATT&CK address the attack and risk surface, while CIS Controls v8 and NIST CSF 2.0 set the governance and control requirements practitioners need to meet.
| Framework | Control / Reference | Relevance |
|---|---|---|
| OWASP Non-Human Identity Top 10 | NHI-01 — NHI Inventory and Ownership | AgentKey is a machine credential that needs explicit ownership and inventory. |
| NHI-02 — Secrets and Credential Management | The term is a secret value whose exposure enables authentication abuse. | |
| NHI-04 — Lifecycle and Offboarding | The secret must be revoked when hosts are replaced or trust is retired. | |
| Recommendation — Inventory the AgentKey as a managed NHI secret and assign a clear owner. Store the AgentKey in protected secret storage and rotate it on exposure or rebuild. Revoke and replace the AgentKey whenever the agent host or trust path changes. | ||
| CIS Controls v8 | 5.1 — Establish and Maintain an Inventory of Accounts | AgentKey-backed access should be tracked as part of governed non-human access. |
| 6.3 — Require MFA for Externally-Exposed Applications | The broader lesson is to harden access paths that rely on credentials and trust. | |
| Recommendation — Track the agent credential and its access path in your managed identity inventory. Harden the publishing path so stolen credentials alone do not provide easy reuse. | ||
| MITRE ATT&CK | T1552.001 — Unsecured Credentials: Credentials In Files | AgentKeys are often recovered from files, configs, or deployment artifacts. |
| Recommendation — Hunt for the AgentKey in files, images, and deployment outputs before attackers reuse it. | ||
| NIST CSF 2.0 | PR.AA-01 — Identity and Credential Management | The secret supports authenticated access for a non-human service identity. |
| Recommendation — Treat the AgentKey as a governed credential and enforce its rotation and revocation. | ||
Related resources from NHI Mgmt Group
Deepen Your Knowledge
Reviewed and updated by the NHIMG editorial team on September 6, 2026.
NHI Mgmt Group — the #1 independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org