How the TameMyCerts Policy Module for Active Directory Certificate Services (ADCS) can help secure scenarios with Microsoft Intune and other Mobile Device Management (MDM) systems

Companies use Mobile Device Management (MDM) Products for managing, configuring and updating mobile devices such as smartphones, tablet computers or desktop systems via the Internet (over-the-air, OTA).

Common mobile device management products are:

TameMyCerts is a Policy moduleto secure the Microsoft certification authority (Active Directory Certificate Services). It extends the functions of the certification authority and enables the Extended application of regulationsto enable the secure automation of certificate issuance. TameMyCerts is unique in the Microsoft ecosystem and is available under a free license. It can downloaded via GitHub and can be used free of charge.

TameMyCerts is open source and can be used free of charge. For use in the corporate sector, however, we recommend the Conclusion of a maintenance contract. This ensures that you receive qualified support and that the module can be further developed to a high quality in the long term.

Functionality

All of these systems use a similar concept in conjunction with a Microsoft certification authority: they act as a middleman between the managed device, the company's directory service and the certification authority. In PKI terms, they perform the role of the Registration Authority (RA) from. They all use a type of connector to transfer certificate requests to the Microsoft AD CS certification authority.

All common MDM systems therefore require that the configured certificate template is set up as an offline certificate template, i.e. that the identity contained in the certificate and confirmed by the certification authority is specified by the applicant, i.e. the MDM system ("enrollee supplies subject").

The certification body has therefore no knowledge of the requested certificate contentit issues the certificate requests blindly and must trust the MDM system completely.

Misplacements by the MDM system are not uncommon

Unfortunately, it is not uncommon for incorrect settings to be made by the MDM system or with its authorizations. Possible reasons could be

  • Misconfiguration of the MDM system.
  • Misbehavior of the MDM system. For example, certificates may be requested for devices that are no longer assigned to an existing user. In this case, certificates with empty identities may be requested.
  • Compromising the service account used and exploiting its application authorizations (see ESC1 attack).

This opens the door to security and data protection incidents.

The usual installations of MDM systems in conjunction with Microsoft Active Directory Certificate Services are therefore vulnerable to the Swiss cheese modelin which small gaps running through the chain of all systems involved can lead to major damage.

Swiss cheese model. Image source (adapted): Wikipedia / Davidmack, licensed under CC BY-SA 3.0.

Specific example: No valid user is assigned to a managed device

In practice, it often happens with MDM systems that no valid user account is assigned to a managed end device.

In a simple case, for example, it would be configured that the Subject Distinguished Name (DN) of a certificate contains a commonName with the variable of the user name.

CN={EnrollmentUser}

In this example, the syntax of VMware Workspace One is used, but all common MDM systems work in a similar way.

If this variable is now empty because no valid user account is assigned to the end device, a certificate request with an empty Subject Distinguished Name (DN) may be generated. MDM systems obviously behave differently here:

If the application that checks the certificate at logon (e.g. a single sign-on (SSO) system) is unlucky enough to be unable to handle such a case adequately, it may happen that the identity of another valid user is assigned with such a certificate at logon. The data protection and security incident is complete.

The solution: TameMyCerts

The TameMyCerts Policy Module for Microsoft Active Directory Certificate Services can close the gap at the certificate authority level by controlling certificate requests by enforcing a fine-grained set of rules.

The possibilities include, among others:

Certificate requests that violate the defined rules will be rejected and the incident logged. This means that an alarm can also be set up to follow up potential security incidents.

TameMyCerts has rejected a certificate application that violated the defined rules.

Microsoft Intune uses the Network Device Enrollment Service (NDES) as a connector between Intune and the certification authority. NDES, as well as the certification authority itself, can be extended with policy modules. Microsoft provides a policy module for NDES for Intune, so no further policy module can be added to an NDES instance that has been configured for Intune. However, since TameMyCerts operates at the level of the certification authority and is installed on it, the advantages of both modules can be easily combined.

Related links:

External sources

en_USEnglish