AD AdminCount 1

๐Ÿ”’Secure Bits๐Ÿ’ก
Do you know ๐˜„๐—ต๐—ฎ๐˜ ๐—”๐—ฑ๐—บ๐—ถ๐—ป๐—–๐—ผ๐˜‚๐—ป๐˜ ๐Ÿญ ๐—ฎ๐˜๐˜๐—ฟ๐—ถ๐—ฏ๐˜‚๐˜๐—ฒ ๐—บ๐—ฒ๐—ฎ๐—ป๐˜€ย ? 2/2

In a previous post, I explained what AdminSDHolder is, but it is also important to know what it protects and how.

We already know that the AdminSDHolder process runs every 60 minutes (you can also trigger this) and sets ACLs on protected accounts and groups. By default, the following are protected:

๐Ÿ”ธAccount Operators
๐Ÿ”ธAdministrator
๐Ÿ”ธAdministrators
๐Ÿ”ธBackup Operators
๐Ÿ”ธDomain Admins
๐Ÿ”ธDomain Controllers
๐Ÿ”ธEnterprise Admins
๐Ÿ”ธEnterprise Key Admins
๐Ÿ”ธKey Admins
๐Ÿ”ธKrbtgt
๐Ÿ”ธPrint Operators
๐Ÿ”ธRead-only Domain Controllers
๐Ÿ”ธReplicator
๐Ÿ”ธSchema Admins
๐Ÿ”ธServer Operators

They all have something in common:
1) They have the attribute AdminCount set to 1
2) They have disabled inheritance of permissions
+ they have the same ACL from AdminSDHolder. This is also what happens to your account if you add it, for example, to the Domain Admins group.

Two very important things to mention:

โš ๏ธ If you remove your account from any protected group mentioned above, and the AdminSDHolder process has already run, no changes are reverted. This means you still have disabled inheritance and the AdminCount 1 attribute. There is a reason for this, and if you wish to keep using the account afterward, you should revert it manually, or better delete it and create a new one.

โš ๏ธ Whenever the AdminSDHolder process must reset the ACL on some protected account or group, it generates Event ID 4780, which is very useful for monitoring your environment for malicious activities. However, this event does not always work:

“๐˜๐˜ฐ๐˜ณ ๐˜ด๐˜ฐ๐˜ฎ๐˜ฆ ๐˜ณ๐˜ฆ๐˜ข๐˜ด๐˜ฐ๐˜ฏ, ๐˜ต๐˜ฉ๐˜ช๐˜ด ๐˜ฆ๐˜ท๐˜ฆ๐˜ฏ๐˜ต ๐˜ฅ๐˜ฐ๐˜ฆ๐˜ด๐˜ฏโ€™๐˜ต ๐˜จ๐˜ฆ๐˜ฏ๐˜ฆ๐˜ณ๐˜ข๐˜ต๐˜ฆ ๐˜ฐ๐˜ฏ ๐˜ด๐˜ฐ๐˜ฎ๐˜ฆ ๐˜–๐˜š ๐˜ท๐˜ฆ๐˜ณ๐˜ด๐˜ช๐˜ฐ๐˜ฏ๐˜ด.”

๐—™๐—ผ๐—น๐—น๐—ผ๐˜„ ๐˜‚๐˜€ for more insights and free courses.