

Tools t hat can aid in automating the process of the above steps include Mimikatz, SharpDPAPI, DSInternals, Impacket, and DonAPI.


Get new tools that automate the process.Replacing the backup key as part of a remediation process.This article will familiarize you with the following:

Today, we are going to change this reality! Setting expectations Currently, the only way to properly replace the key is by re-building the domain. The domain backup key is a unique RSA key pair that is generated only once during the domain inception. The encrypted copy is made for recovery purposes, and allows users to recover encrypted secrets if they forgot their password. įor Active Directory users, the Master Key is encrypted with the user's password, and another copy of the key is encrypted with the domain backup key. Replacing this key enables defenders to eliminate the ability of threat actors to indefinitely exploit a compromised key, and decrypt users’ secrets.ĭata Protection API (DPAPI) is a widely-used functionality within Windows applications that encrypts sensitive data, without implementing the underlying encryption algorithm itself.Įvery Windows user has a DPAPI Master Key that can be used to encrypt and decrypt data this data may be stored either locally or remotely. In this post, we demonstrate for the first time how defenders can replace their DPAPI backup key, to better defend their organization during or following an Active Directory compromise event. In recent years, the Windows DPAPI mechanism has been exploited by threat actors to extract secrets across an organization, using the immutable DPAPI domain backup key as a kind of ‘joker’ during the attack.
