Workflow Tools Control Yard

Home / Email and M365

dsregcmd /status reader

Paste the output of dsregcmd /status from a Windows device. The page says how the device is joined, explains each field, and points at the values that Microsoft's documentation ties to a problem, such as AzureAdPrt : NO or a failed KeySignTest. The text stays in your browser.

How to run it

Run dsregcmd /status twice. In a normal command prompt, as the user, it shows the User State and SSO State sections, which need the user's context. From an elevated command prompt it runs its diagnostics in the SYSTEM context, the context a real join runs in, and it can run KeySignTest, which needs elevated rights.

How the join state is read

Three fields of the Device State section give the join state. A device that is only Microsoft Entra registered shows WorkplaceJoined : YES in the User State section instead.

AzureAdJoinedEnterpriseJoinedDomainJoinedJoin state
YESNONOMicrosoft Entra joined
NONOYESDomain joined
YESNOYESMicrosoft Entra hybrid joined
NOYESYESOn-premises DRS joined

Some sections appear only for some devices. Device Details and Tenant Details: only for a device that is Microsoft Entra joined or hybrid joined. The pre-join diagnostics: only for a domain joined device that could not hybrid join. A join that fails in the join phase with DirectoryError is expected for a sync join, until Microsoft Entra Connect has synchronized the device; then it can join.

The fields

The page reads the pasted fields against this table. Field names that are not in it are shown as not described.

FieldWhat it meansPoints at a problem
Device State
AzureAdJoinedYES when the device is joined to Microsoft Entra ID.
EnterpriseJoinedYES when the device is joined to an on-premises Active Directory (AD); with DomainJoined YES, the join state table calls this on-premises DRS joined. A device cannot be both EnterpriseJoined and AzureAdJoined.
DomainJoinedYES when the device is joined to an Active Directory domain.
DomainNameThe name of the domain, when the device is joined to one.
Device Details
DeviceIdThe device's ID in the Microsoft Entra tenant.
ThumbprintThe thumbprint of the device certificate.
DeviceCertificateValidityWhen the device certificate is valid: from the first time to the second. The page compares them with this computer's clock.
KeyContainerIdThe container ID of the device's private key, the key of the device certificate.
KeyProviderWhere the device's private key is kept: in hardware or in software.
TpmProtectedYES when the device's private key is kept in a hardware TPM.
DeviceAuthStatusA check of the device's health in Microsoft Entra ID: SUCCESS when the device is there and enabled. Added in Windows 10 version 21H1.FAILED. Device is either disabled or deleted: The device is disabled or deleted in Microsoft Entra ID. FAILED. ERROR: The check could not run; it needs a network connection to Microsoft Entra ID in the system context.
Virtual DesktopWhether there is VDI device metadata: NOT SET, YES (the provider, type, user mode and extensions follow) or INVALID.INVALID: The VDI device metadata is there but not set correctly.
ProviderVDI: the name of the VDI vendor.
TypeVDI: persistent or non-persistent.
User modeVDI: single user or multi-user.
ExtensionsVDI: how many key-value pairs of optional vendor metadata there are, then the pairs.
Tenant Details
MdmUrlThe address for enrollment in mobile device management (MDM). Empty when no MDM is set up or the user is not in scope of MDM enrollment. A URL here does not mean the device is managed.
MdmTouUrlAn MDM address (terms of use). Empty when no MDM is set up or the user is not in scope.
MdmComplianceUrlAn MDM address (compliance). Empty when no MDM is set up or the user is not in scope.
Other fieldsOne of the tenant details shown for a device joined to Microsoft Entra ID. The article describes the section, not each field.
User State
NgcSetYES when the signed-in user has a Windows Hello key.
NgcKeyIdThe ID of the user's Windows Hello key, when there is one.
CanResetWhether the user can reset the Windows Hello key: DestructiveOnly, NonDestructiveOnly, DestructiveAndNonDestructive, or Unknown on an error.
WorkplaceJoinedYES when Microsoft Entra registered accounts have been added to the device in the current user's profile: this is the Microsoft Entra registered state.
WamDefaultSetYES when a Web Account Manager (WAM) default WebAccount exists for the signed-in user.ERROR: It can show an error when dsregcmd /status runs from an elevated command prompt: run it again from one that is not elevated.
WamDefaultAuthorityorganizations for Microsoft Entra ID.
WamDefaultIdhttps://login.microsoft.com for Microsoft Entra ID.
WamDefaultGUIDThe GUID of the WAM provider (Microsoft Entra ID or Microsoft account) for the default WebAccount.
SSO State
AzureAdPrtYES when the signed-in user has a Primary Refresh Token (PRT) on the device.NO: There is no PRT for this user on this device, and without one there is no single sign-on to Microsoft 365 and other cloud apps. On a Microsoft Entra joined or hybrid joined device, Windows gets a PRT when the user signs in with organization credentials. When AcquirePrtDiagnostics or RefreshPrtDiagnostics is PRESENT, the fields after it describe the last failed attempt.
AzureAdPrtUpdateTimeWhen the PRT was last updated, in UTC.
AzureAdPrtExpiryTimeWhen the PRT expires if it is not renewed, in UTC.
AzureAdPrtAuthorityThe Microsoft Entra authority URL.
EnterprisePrtYES when the device has a PRT from on-premises AD FS. A hybrid joined device can have one from both; an on-premises joined device has only this one.
EnterprisePrtUpdateTimeWhen the enterprise PRT was last updated, in UTC.
EnterprisePrtExpiryTimeWhen the enterprise PRT expires if it is not renewed, in UTC.
EnterprisePrtAuthorityThe AD FS authority URL.
AcquirePrtDiagnosticsPRESENT when there is diagnostic information about getting a PRT; the fields after it describe the last failed attempt. Shown only for a failure after the last successful update; on a shared device it can come from another user's sign-in.PRESENT: A PRT could not be got: read Attempt Status, Server Error Code and Server Error Description below it.
Previous Prt AttemptWhen the failed PRT attempt happened.
Attempt StatusThe client error code that came back (an HRESULT).
User IdentityThe UPN of the user the attempt was for.
Credential TypeWhat was used to get or refresh the PRT, such as Password or Next Generation Credential (NGC, Windows Hello).
Correlation IDThe correlation ID the server sent for the failed attempt.
Endpoint URIThe last endpoint reached before the failure.
HTTP MethodThe HTTP method used with that endpoint.
HTTP ErrorA WinHttp transport error code.
HTTP StatusThe HTTP status the endpoint returned.
Server Error CodeThe error code from the server.
Server Error DescriptionThe error message from the server.
RefreshPrtDiagnosticsPRESENT when there is diagnostic information about refreshing the PRT; the same fields follow it.PRESENT: Refreshing the PRT failed: read Attempt Status, Server Error Code and Server Error Description below it.
OnPremTgtYES when the user has a Cloud Kerberos ticket for on-premises resources. Windows 11 version 21H2 and later.
CloudTgtYES when the user has a Cloud Kerberos ticket for cloud resources.
KerbTopLevelNamesThe top-level Kerberos realm names for Cloud Kerberos.
Diagnostic Data
User ContextThe context the diagnostics ran in: SYSTEM, UN-ELEVATED User or ELEVATED User. SYSTEM is the closest to a real join, which runs as SYSTEM.
Client TimeThe system time, in UTC.
AD Connectivity TestTests the connection to a domain controller.FAIL: A failure here likely leads to join errors in the pre-check phase.
AD Configuration TestChecks that the Service Connection Point (SCP) object is set up in the on-premises forest.FAIL: A failure here likely leads to join errors in the discover phase, with error 0x801c001d.
DRS Discovery TestGets the DRS endpoints from the discovery metadata and makes a user realm request.FAIL: A failure here likely leads to join errors in the discover phase.
DRS Connectivity TestA basic test of the connection to the DRS endpoint.FAIL: The device cannot reach the DRS endpoint.
Token Acquisition TestTries to get a Microsoft Entra authentication token, when the user's tenant is federated.FAIL: A failure here likely leads to join errors in the auth phase. Windows then falls back to sync join, unless that is turned off.
Fallback to Sync-JoinENABLED unless the registry value FallbackToSyncJoin under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\CDJ turns it off (0). Windows 10 version 1803 and later.
Previous RegistrationWhen the last failed join attempt happened. Only failed attempts are logged.
Error PhaseThe stage the join stopped in: pre-check, discover, auth or join.Any other value: A join attempt failed: read Client ErrorCode, Server ErrorCode and Server Message.
Client ErrorCodeThe client error code that came back (an HRESULT).
Server ErrorCodeThe server's error code, when the server answered with one.
Server MessageThe server's message that came with the error code.
Https StatusThe HTTP status the server returned.
Request IDThe request ID the client sent, to match with the server's logs.
AadRecoveryEnabledYES when the keys on the device are not usable and the device is marked for recovery.YES: The next sign-in starts the recovery and registers the device again.
KeySignTestPASSED when the device keys are in good health. It needs elevated rights.Any other value: The device is usually marked for recovery then, and the next sign-in registers it again: silently on a hybrid joined device, with a prompt on a joined or registered one.
Ngc Prerequisite Check
IsDeviceJoinedYES when the device is joined to Microsoft Entra ID.NO: A Windows Hello for Business prerequisite that is not met.
IsUserAzureADYES when the signed-in user is in Microsoft Entra ID.NO: A Windows Hello for Business prerequisite that is not met.
PolicyEnabledYES when the Windows Hello for Business policy is on for the device.NO: A Windows Hello for Business prerequisite that is not met.
PostLogonEnabledYES when Windows itself starts Windows Hello for Business enrollment; NO when something custom starts it.
DeviceEligibleYES when the device meets the hardware requirement for Windows Hello for Business.NO: A Windows Hello for Business prerequisite that is not met.
SessionIsNotRemoteYES when the user is signed in at the device, not remotely.NO: A Windows Hello for Business prerequisite that is not met.
CertEnrollmentCertificate trust: enrollment authority when the policy comes from Group Policy, mobile device management when it comes from MDM, none otherwise.
AdfsRefreshTokenCertificate trust with an enrollment authority: whether the device has an enterprise PRT for the user.
AdfsRaIsReadyCertificate trust with an enrollment authority: YES when AD FS says in its discovery metadata that it supports Windows Hello for Business, and the logon certificate template is available.NO: A Windows Hello for Business prerequisite that is not met.
LogonCertTemplateReadyCertificate trust with an enrollment authority: YES when the logon certificate template is valid.NO: A Windows Hello for Business prerequisite that is not met.
PreReqResultThe result of all the checks above: WillProvision when enrollment will start as the user next signs in.Any other value: Windows Hello for Business will not be set up at the next sign-in. The NO values above say why.
OnPremTGTCloud Kerberos trust, when CertEnrollment is none: YES when the device has a Cloud Kerberos ticket for on-premises resources. Before Windows 11 version 23H2 it was called CloudTGT.
CloudTGTThe name of OnPremTGT before Windows 11 version 23H2.

Sources

More Email and M365 tools