A vendor's app made itself Global Admin: ConnectWise, Entra service principals and stolen app secrets
In October 2026 a stolen vendor credential let ConnectWise Cloud Management apps assign themselves directory roles in customer Entra tenants. Weeks later a second campaign signed in as customers' own apps using client secrets found in GitHub. What the audit trail looks like, how we test for it, and what to change.
By Ahmed PingerPublished
10 min read0 views
OperationName: Add member to role
InitiatedBy: ConnectWise Cloud Management - MS Teams (service principal)
TargetResource: Global Administrator
The block above is an illustrative audit entry, modelled on what Huntress reported from a customer tenant on 15 October 2026. At 03:44 UTC the ConnectWise Cloud Management app for Microsoft Teams added itself to the Global Administrator role. It did it again at 03:48, and client secrets were added to two other applications. The actor was an application, not a person, so there was no interactive sign-in for MFA to challenge. A service principal changed its own privileges, and that is a legitimate-looking event in a log most organisations never read.
What happened
Huntress's timeline, which it kept updating through 27 October, runs like this:
- From 01:58 UTC on 15 October, service principals belonging to ConnectWise Cloud Management apps assigned themselves directory roles, mostly Exchange Administrator, in about 50 tenants Huntress monitors.
- In one tenant, the Teams app made itself Global Administrator and new client secrets were added to an MSP management app and the Huntress application, with expiry dates in 2028.
- By 19:00 UTC on 16 October, Huntress had confirmed unauthorised sign-ins in 162 tenants. It later reported almost 1,000 tenants with sign-in activity from the same address and over 300 successful.
- ConnectWise says it disabled the seven application identities at 07:00 UTC on 17 October, which prevents new authentication through those connections but does not reverse changes already made inside a tenant. Huntress's advice was to disable, not delete, the ConnectWise Cloud Backup (formerly SkyKick) and Cloud Management Teams apps.
On 21 October Microsoft attributed the compromise of the multi-tenant application to the actor it tracks as Storm-0940, saying the actor used the ARTEX agentic framework and attempted sign-ins to "more than 2,250 tenants". It also described a password spray on 327 accounts across eight organisations between 10 and 14 October: 151,000+ failed logons, with no successful authentication observed. We use these as the vendors' own figures. Tenant counts differ between reports, and we attribute each to its source.
ConnectWise has not described a vulnerability in its product. This was a compromised vendor credential, and the apps' standing permissions in every customer tenant did the rest.
Why a vendor app holds that much power
When a customer installs a vendor's multi-tenant application, Entra creates a service principal for it in the customer's tenant. The customer grants it permissions, either application permissions (the app acts as itself) or directory roles. Backup, migration and management tools often ask for broad ones: mail read and write, directory write, an admin role.
Three properties make that a high-value target:
- The credential lives with the vendor. The client secret or certificate that proves the app's identity sits on the app registration in the vendor's tenant. If an attacker gets it, they can request a token for every customer tenant where the app was consented.
- There is no user to challenge. Client credential sign-ins have no MFA step, no device check and no human to notice a prompt.
- It can change itself. If the app holds a role that lets it manage roles or applications, it can grant itself more and add new credentials of its own. That is how the Teams app became Global Administrator and how secrets expiring in 2028 appeared in other apps. A new credential on a customer-side app survives the vendor rotating its own.
The second campaign: your own app's secret
Two weeks later, a different mechanism with the same ending. Microsoft (5 November) described an agentic framework that, from August, issued large volumes of GitHub queries for credentials, then from 28 October used leaked application credentials to sign in as service principals in Entra tenants. The compromised apps accessed SharePoint and OneDrive, including file downloads and mailbox items.
Todyl, whose report covers the same actor behaviour, counted about 45 app registrations at roughly 18 organisations targeted in its 3 November post (updated 6 November), more than 33 of them authenticating successfully, and through those apps the actor reached 27 organisations including MSPs' downstream clients, and noted that 95% of sign-ins came from scripted clients. Two error codes are the tell: AADSTS7000215 (invalid client secret) and AADSTS7000222 (expired client secret). A failure with one of those codes, then a success for the same app from the same address minutes later, is a secret being tested.
Both campaigns land on the same weak point: a non-human identity with standing permission and a long-lived secret.
How we test for it
In an Entra and Microsoft 365 internal test we enumerate service principals the way an attacker holding a vendor's credential would, then rank them by what they can do. Everything below uses the Microsoft Graph API through az rest and jq.
1. Which service principals hold directory roles?
az rest --method GET \
--url 'https://graph.microsoft.com/v1.0/roleManagement/directory/roleAssignments?$expand=principal' \
| jq -r '.value[]
| select(.principal["@odata.type"]=="#microsoft.graph.servicePrincipal")
| "\(.principal.displayName)\t\(.principal.appId)\t\(.roleDefinitionId)"'
az rest --method GET --url 'https://graph.microsoft.com/v1.0/roleManagement/directory/roleDefinitions?$select=id,displayName' \
| jq -r '.value[] | "\(.id)\t\(.displayName)"'
Join the two lists, and follow @odata.nextLink for large tenants. Any vendor application holding Global Administrator, Privileged Authentication Administrator or Exchange Administrator is a finding by itself. Huntress specifically recommends reviewing the Privileged Authentication Administrator role too.
2. Which third-party apps are installed, and which have we stopped using?
TENANT=$(az account show --query tenantId -o tsv)
az rest --method GET \
--url 'https://graph.microsoft.com/v1.0/servicePrincipals?$select=id,appId,displayName,appOwnerOrganizationId,accountEnabled,passwordCredentials,keyCredentials&$top=999' \
| jq -r --arg t "$TENANT" '.value[]
| select(.appOwnerOrganizationId != $t)
| "\(.displayName)\t\(.appId)\t\(.accountEnabled)"'
The result lists applications that belong to other organisations. Each one is a vendor we ask the client about: do you still use it, who consented, and what can it do? Follow @odata.nextLink for large tenants.
3. Who can add credentials? Application Administrator and Cloud Application Administrator can add secrets to any application, and so can owners of a given app. Enumerate role members and app owners. Anyone in that set can turn a low-privilege foothold into a persistent one.
4. Show the persistence. In a scoped internal test, with an identity that can manage a test application, add a second secret, authenticate as the app, and show it survives a password reset on the account that created it.
az ad app credential reset --id <appId> --append --display-name "ab-test" --years 1
We delete it at the end and note the audit events this produces, so the client can check their alerting fired.
5. Review exclusions. Conditional Access exclusions that bypass a vendor app, break-glass accounts that are excluded everywhere, and a policy list that has nothing at all for workload identities.
Detection
Everything below starts with Entra audit and sign-in logs sent to a SIEM. Without them the questions are unanswerable, so first check retention and that service principal sign-ins are exported, not only user sign-ins.
A service principal changing its own roles or credentials. Huntress names three audit operations: "Add member to role", "Update application" and "Add service principal credentials". In Sentinel:
AuditLogs
| where TimeGenerated > ago(30d)
| where OperationName in ("Add member to role", "Update application", "Add service principal credentials", "Add service principal")
| extend ActorApp = tostring(InitiatedBy.app.displayName),
ActorSpId = tostring(InitiatedBy.app.servicePrincipalId),
ActorUser = tostring(InitiatedBy.user.userPrincipalName)
| where isnotempty(ActorApp)
| project TimeGenerated, OperationName, ActorApp, ActorSpId, TargetResources, Result
| order by TimeGenerated desc
An app, not a person, adding itself or another app to a directory role is rare enough that every hit deserves a look.
Known indicators from the ConnectWise incident. Search by application ID, not display name, as Microsoft advises. Huntress publishes these:
| App | Application ID |
|---|---|
| ConnectWise Cloud Backup (formerly SkyKick) | 506e08f9-6e9a-4da4-942b-a099a03644ae |
| ConnectWise Cloud Management | 2399d300-6fca-4e6a-a686-399fefe75b83 |
| Cloud Management, MS Teams | 24205314-2b89-4e07-a2a4-579e898a5640 |
| Cloud Management, Exchange Online | b78f6a77-d4e5-46fb-87e5-d1648bd02519 |
| Cloud Management, MS Graph | 0de14c77-b9b0-4137-9360-34878a929827 |
| Cloud Management, SharePoint Online | b2b55f5b-7758-4719-8d8f-88ae172e6bdb |
| Cloud Management, Partner Center | 412dcf96-176d-4b3a-a1b0-4981ad66971e |
AADServicePrincipalSignInLogs
| where TimeGenerated between (datetime(2026-10-01) .. now())
| where AppId in ("506e08f9-6e9a-4da4-942b-a099a03644ae","2399d300-6fca-4e6a-a686-399fefe75b83",
"24205314-2b89-4e07-a2a4-579e898a5640","b78f6a77-d4e5-46fb-87e5-d1648bd02519",
"0de14c77-b9b0-4137-9360-34878a929827","b2b55f5b-7758-4719-8d8f-88ae172e6bdb",
"412dcf96-176d-4b3a-a1b0-4981ad66971e")
| summarize signins = count(), ips = make_set(IPAddress, 20) by AppId, ResultType
Huntress's primary IP in that campaign was 144.172.64.128 and Microsoft and Todyl both report sign-ins from 199.19.77.84 in the second. Search them as a bonus, and expect them to age out fast. A clean result does not prove safety: Huntress says a clean log check does not rule out access, and says to disable the app regardless. Microsoft advises reviewing sign-ins from at least 15 October and extending to 1 October where records exist.
Secret testing against your own apps. This is the Todyl and Microsoft pattern:
AADServicePrincipalSignInLogs
| where TimeGenerated > ago(14d)
| summarize failures = countif(ResultType in ("7000215","7000222")),
successes = countif(ResultType == "0"),
apps = dcount(AppId)
by IPAddress
| where failures > 0 and successes > 0
Add Microsoft's behavioural rule: one address authenticating as three or more service principals in a short window with mixed success. Also look at failures that never succeed from hosting providers, because success-only detections miss them.
Credential and role changes as alerts, not reports. Alert on Add service principal credentials where the actor is not a named automation account, and on any directory role assignment to a service principal.
Fix
In order:
- Inventory third-party apps and their grants. Use the queries above. Remove apps you no longer use. An abandoned vendor integration with a Global Administrator role is the worst combination.
- Disable, do not delete, a suspect app. Microsoft says to preserve evidence first, and Huntress says deleting an app removes its consent. Set
accountEnabledto false on the service principal (az ad sp update --id <objectId> --set accountEnabled=false), then review audit history, then remove confirmed unauthorised credentials, grants and role assignments. - Strip roles the vendor does not need. Move vendors from directory roles to scoped application permissions, and review consent grants. A backup tool needs mail or file access for its job, not the ability to manage roles.
- Cap who can add credentials. Limit Application Administrator, Cloud Application Administrator and app ownership. Microsoft also recommends restricting who can register apps.
- Use app management policies. Restrict user-provided app passwords and cap secret lifetime on the apps you own.
- Retire client secrets. Move your own apps to managed identities or workload identity federation. A secret that does not exist cannot land in a public repository.
- Add workload identity Conditional Access, knowing its limits. Microsoft notes it needs Workload ID Premium and covers only single-tenant apps in your own tenant. That helps with your own apps and does nothing for a multi-tenant vendor app, where disabling the service principal is the lever.
- Stop secrets leaving. Turn on secret scanning and push protection, and rotate anything that was ever public even after deleting it.
- Review Conditional Access exclusions. Huntress specifically asks for exclusions that could bypass blocks on a vendor app.
- For MSP relationships, review partner access. Both Microsoft and Todyl point MSPs to Partner Center access and GDAP relationships.
Take this away
The attack needed no exploit and no malware on a laptop. It needed one stolen credential and standing permission that nobody had reviewed. Every tenant has a list of applications that can act as an administrator without a person present. Know what is on yours, who can add a secret to each entry, and what your log shows when one of them changes its own privileges.
References
- Huntress, ConnectWise (SkyKick) vendor credential abuse (16 October 2026, updated through 27 October): https://www.huntress.com/blog/vendor-credential-enables-unauthorized-access
- Microsoft Security Blog, Storm-0940 uses ARTEX in the ConnectWise supply-chain compromise (21 October 2026): https://www.microsoft.com/en-us/security/blog/2026/10/21/storm-0940-uses-artex-agentic-ai-connectwise-supply-chain-compromise/
- Microsoft Security Blog, threat actors use agentic AI tooling to find and abuse exposed secrets (5 November 2026): https://www.microsoft.com/en-us/security/blog/2026/11/05/threat-actors-use-agentic-ai-tooling-to-find-and-abuse-exposed-secrets/
- Todyl, stolen app credentials: an actor signing into Entra ID as your workloads (3 November 2026, updated 6 November): https://www.todyl.com/blog/stolen-app-credentials-real-access-an-actor-is-signing-into-entra-id-and-azure-devops-as-your-workloads
- ConnectWise security advisories: https://www.connectwise.com/company/trust/advisories
- BleepingComputer, ConnectWise disabling the seven application identities (18 October 2026 update): https://www.bleepingcomputer.com/news/security/hackers-breach-microsoft-365-tenants-via-connectwise-supply-chain-attack
Was this useful?
Get the next write-up by email
New technical write-ups by email when we publish. No sales sequence, and every email has an unsubscribe link.
Prefer a feed? RSS. How we handle your address: privacy notice.
Comments
Loading comments…