Active Directory Certificate Services ESC1

๐Ÿ”’ Secure Bits ๐Ÿ’ก
Have you ever heard of ๐—˜๐—ฆ๐—– ๐˜ƒ๐˜‚๐—น๐—ป๐—ฒ๐—ฟ๐—ฎ๐—ฏ๐—ถ๐—น๐—ถ๐˜๐—ถ๐—ฒ๐˜€? I guess you have.

If you’re running ๐—”๐—ฐ๐˜๐—ถ๐˜ƒ๐—ฒ ๐——๐—ถ๐—ฟ๐—ฒ๐—ฐ๐˜๐—ผ๐—ฟ๐˜† ๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฐ๐—ฎ๐˜๐—ฒ ๐—ฆ๐—ฒ๐—ฟ๐˜ƒ๐—ถ๐—ฐ๐—ฒ๐˜€ (๐—”๐—— ๐—–๐—ฆ) and haven’t audited it for ESC misconfigurations โ€” you may be sitting on a ๐˜๐—ถ๐—ฐ๐—ธ๐—ถ๐—ป๐—ด ๐˜๐—ถ๐—บ๐—ฒ ๐—ฏ๐—ผ๐—บ๐—ฏ.ย ๐Ÿ’ฃ

๐ŸŽฏ ESC vulnerabilities (Enterprise PKI Escalation Paths) are incredibly ๐—ฐ๐—ผ๐—บ๐—บ๐—ผ๐—ปย and highly ๐—ฑ๐—ฎ๐—ป๐—ด๐—ฒ๐—ฟ๐—ผ๐˜‚๐˜€. Yetโ€ฆ most environments I assess treat AD CS like a black box โ€” โ€œItโ€™s working, so letโ€™s not touch it.โ€

But attackers love AD CS โ€” it often lets them ๐—ฒ๐˜€๐—ฐ๐—ฎ๐—น๐—ฎ๐˜๐—ฒ ๐˜๐—ผ ๐——๐—ผ๐—บ๐—ฎ๐—ถ๐—ป ๐—”๐—ฑ๐—บ๐—ถ๐—ป using just a basic user account. No exploits. Just misconfigurations.

๐—Ÿ๐—ฒ๐˜โ€™๐˜€ ๐—ฏ๐—ฟ๐—ฒ๐—ฎ๐—ธ ๐—ฑ๐—ผ๐˜„๐—ป ๐—˜๐—ฆ๐—–๐Ÿญย ๐Ÿ‘‡
ESC1 = Certificate Template Misconfig
It lets a regular user request a certificate that can later be used to authenticate as someone else โ€” including privileged users.

๐—ง๐—ผ ๐—ฏ๐—ฒ ๐˜ƒ๐˜‚๐—น๐—ป๐—ฒ๐—ฟ๐—ฎ๐—ฏ๐—น๐—ฒ, ๐—ฎ๐—น๐—น ๐—ผ๐—ณ ๐˜๐—ต๐—ฒ๐˜€๐—ฒ ๐—ฎ๐—ฟ๐—ฒ ๐˜๐—ฟ๐˜‚๐—ฒ:
โœ… Non-privileged users can enroll in a certificate template
โœ… Manager approval is not required
โœ… No authorized signature is required
โœ… The template supports client authentication (PKINIT, Smart Card, etc.)
โœ… The requester can define the Subject Alternative Name (SAN)

๐—˜๐—ป๐—ฑ ๐—ฟ๐—ฒ๐˜€๐˜‚๐—น๐˜?
A low-privileged user can impersonate anyone โ€” including a Domain Admin โ€” using the certificate.

๐Ÿ› ๏ธ ๐—›๐—ผ๐˜„ ๐˜๐—ผ ๐—ฐ๐—ต๐—ฒ๐—ฐ๐—ธ ๐˜†๐—ผ๐˜‚๐—ฟ ๐—ฒ๐—ป๐˜ƒ๐—ถ๐—ฟ๐—ผ๐—ป๐—บ๐—ฒ๐—ป๐˜:
There are free tools for this:
๐Ÿ”น ADProbe โ€” My AD vulnerability scanner
๐Ÿ”น Locksmith by Jake Hildreth โ€” covers almost all ESC vulnerabilities
๐Ÿ”น …

๐ŸŽฏ There are ๐Ÿญ๐Ÿฒ ๐—˜๐—ฆ๐—–๐˜€ ๐—ถ๐—ป ๐˜๐—ผ๐˜๐—ฎ๐—น.

Iโ€™ll be covering them in upcoming Secure Bits posts.

๐Ÿ‘‰ Did you already know what ESC1 was about?