Home
%3CLINGO-SUB%20id%3D%22lingo-sub-440261%22%20slang%3D%22en-US%22%3EChanges%20to%20Ticket-Granting%20Ticket%20(TGT)%20Delegation%20Across%20Trusts%20in%20Windows%20Server%20(CIS%20edition)%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-440261%22%20slang%3D%22en-US%22%3E%3CP%3EHello%20Everyone!%20Allen%20Sudbring%20here%2C%20Premier%20Field%20Engineer%20at%20Microsoft.%20Today%20I'm%20putting%20a%20post%20out%20to%20get%20some%20critical%20information%20to%20everyone%20who%20supports%20Windows%20Server%20and%20Active%20Directory%20Domain%20Services.%3C%2FP%3E%0A%3CP%3EIf%20you%20haven%E2%80%99t%20seen%20the%20KB%20article%20that%20this%20post%20references%20I%20encourage%20you%20to%20check%20out%20its%20content%2C%20I%20promise%20it%E2%80%99s%20important!%3C%2FP%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4490425%2Fupdates-to-tgt-delegation-across-incoming-trusts-in-windows-server%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EKB4490425%20-%20Updates%20to%20TGT%20delegation%20across%20incoming%20trusts%20in%20Windows%20Server%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWith%20the%20introduction%20of%20Windows%20Server%202012%2C%20a%20new%20feature%20was%20added%20to%20Active%20Directory%20Domain%20Services%20that%20enforced%20the%20forest%20boundary%20for%20Kerberos%20unconstrained%20delegation.%20This%20allowed%20an%20administrator%20of%20a%20trusted%20forest%20to%20configure%20whether%20TGTs%20can%20be%20delegated%20to%20a%20service%20in%20the%20trusting%20forest.%20Unfortunately%2C%20an%20unsafe%2C%20default%20configuration%20exists%20within%20this%20feature%20when%20creating%20an%20inbound%20trust%20that%20could%20allow%20an%20attacker%20in%20the%20trusting%20forest%20to%20request%20the%20delegation%20of%20a%20TGT%20for%20an%20identity%20from%20the%20trusted%20forest.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ESo%20what%20does%20this%20all%20mean%3F%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ELet's%20back%20up%20a%20little%20bit%20and%20do%20a%20brief%20explanation%20on%20Kerberos%20delegation.%3C%2FP%3E%0A%3CP%3EThere%20are%20three%20kinds%20of%20Kerberos%20delegation%20in%20Active%20Directory%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%3CP%3E%3CSTRONG%3EUnconstrained%3C%2FSTRONG%3E%3CBR%20%2F%3EWhen%20a%20Domain%20Administrator%20configures%20a%20service%E2%80%99s%20account%20to%20be%20trusted%20for%20unconstrained%20delegation%2C%20that%20service%20has%20the%20ability%20to%20impersonate%20any%20user%20account%20to%20any%20other%20service.%20This%20is%20the%20most%20insecure%20delegation%20option%2C%20because%20a%20service%20could%20impersonate%20any%20user%20to%20any%20other%20service%20it%20likes.%20For%20a%20regular%20user%20account%2C%20not%20so%20bad%2C%20but%20for%20a%20Domain%20Admin%20or%20an%20Enterprise%20Admin%2C%20a%20rogue%20service%20could%20request%20information%20from%20the%20domain%20or%20change%20user%20account%20or%20group%20permissions%20in%20the%20name%20of%20the%20privileged%20account.%20For%20this%20reason%2C%20unconstrained%20Kerberos%20delegation%20is%20a%20high%20security%20risk.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%3CSTRONG%3EConstrained%3C%2FSTRONG%3E%3CBR%20%2F%3EFirst%20introduced%20with%20Windows%20Server%202003%2C%20constrained%20delegation%20allows%20an%20administrator%20to%20limit%20the%20services%20to%20which%20an%20impersonated%20account%20can%20connect%20to.%20Constrained%20delegation%20is%20difficult%20to%20configure%20and%20requires%20unique%20SPN's%20to%20be%20registered%20as%20well%20as%20Domain%20Admin%20rights%20to%20implement.%20Constrained%20delegation%20cannot%20cross%20domain%20or%20forest%20boundaries.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%3CSTRONG%3EResource-based%20Constrained%3C%2FSTRONG%3E%3CBR%20%2F%3EFirst%20introduced%20with%20Windows%20Server%202012%2C%20Resource-based%20constrained%20delegation%20improved%20on%20the%20constrained%20delegation%20introduced%20with%20Windows%20Server%202003.%20It%20eliminated%20the%20need%20for%20SPNs%20by%20switching%20to%20security%20descriptors.%20This%20removed%20the%20need%20for%20Domain%20Admin%20rights%20to%20implement%20and%20allowed%20server%20administrators%20of%20backend%20services%20to%20control%20which%20service%20principals%20can%20request%20Kerberos%20tickets%20for%20another%20user.%20Resource%20based%20allows%20delegation%20across%20domain%20and%20forest%20boundaries.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EFor%20more%20information%20on%20Kerberos%20delegation%2C%20refer%20to%20this%20documentation%3A%3C%2FP%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fwindows-server%2Fsecurity%2Fkerberos%2Fkerberos-constrained-delegation-overview%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EKerberos%20Constrained%20Delegation%20Overview%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAll%20currently%20supported%20versions%20of%20Windows%20Server%20that%20are%20utilized%20for%20Active%20Directory%20Domain%20controllers%20have%20this%20vulnerability%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%3CP%3E%3CSTRONG%3EWindows%20Server%202008%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%3CSTRONG%3EWindows%20Server%202008%20R2%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%3CSTRONG%3EWindows%20Server%202012%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%3CSTRONG%3EWindows%20Server%202012%20R2%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%3CSTRONG%3EWindows%20Server%202016%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%3CSTRONG%3EWindows%20Server%202019%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ELet%E2%80%99s%20say%20you%20are%20responsible%20for%20the%20Contoso%20forest%20and%20you%20have%20a%20partner%20who%20owns%20the%20Fabrikam%20forest%20whose%20resources%20your%20users%20use.%20How%20could%20an%20attacker%20in%20Fabrikam%20take%20advantage%20of%20this%20vulnerability%3F%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EFirst%2C%20they%20need%20to%20have%20the%20ability%20to%20configure%20a%20service%20they%20own%20to%20be%20trusted%20for%20unconstrained%20delegation.%20By%20default%2C%20this%20requires%20domain%20administrator%20privilege%20in%20the%20%3CA%20href%3D%22http%3A%2F%2Ffabrikam.com%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3Efabrikam.com%3C%2FA%3E%20forest.%3C%2FP%3E%0A%3CP%3ENext%2C%20they%20need%20to%20get%20your%20user%20to%20authenticate%20their%20rogue%20service%20in%20your%20partner%E2%80%99s%20Fabrikam%20forest.%3C%2FP%3E%0A%3CP%3ENow%20they%20have%20your%20user%E2%80%99s%20TGT%20which%20they%20can%20use%20to%20authenticate%20to%20any%20service%20as%20that%20user.%3C%2FP%3E%0A%3CH2%20class%3D%22mume-header%22%20id%3D%22toc-hId-1705536423%22%20id%3D%22toc-hId-1705536423%22%3E%26nbsp%3B%3C%2FH2%3E%0A%3CH2%20id%3D%22technical-overview-of-the-vulnerability%22%20class%3D%22mume-header%22%20id%3D%22toc-hId--846620538%22%20id%3D%22toc-hId--846620538%22%3ETechnical%20Overview%20of%20the%20Vulnerability%3C%2FH2%3E%0A%3CP%3EAs%20a%20consequence%20of%20this%20vulnerability%20an%20attacker%20who%20has%20control%20of%20a%20forest%20with%20an%20inbound%20trust%20to%20another%20forest%20can%20request%20a%20TGT%20for%20a%20user%20in%20the%20trusted%20forest%20by%20enabling%20unconstrained%20delegation%20on%20a%20service%20principal%20in%20the%20trusting%20forest.%20The%20attacker%20would%20need%20to%20convince%20the%20user%20to%20authenticate%20to%20the%20resource%20in%20the%20trusting%20forest%20thereby%20allowing%20the%20attacker%20to%20request%20a%20delegated%20TGT.%3C%2FP%3E%0A%3CP%3ETo%20mitigate%20this%20vulnerability%2C%20a%20netdom%20command%20can%20be%20executed%20that%20will%20disable%20TGT%20delegation.%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3EEnableTGTDelegation%3C%2FSTRONG%3E%20flag%20is%20enabled%20on%20Windows%20Server%202008%20and%20Windows%20Server%202008%20R2%20devices%20after%20installing%20the%20March%2012%2C%202019%20updates.%20Windows%20Server%202012%20and%20higher%2C%20the%20%3CSTRONG%3EEnableTGTDelegation%3C%2FSTRONG%3E%20flag%20is%20in%20the%20operating%20system%20out%20of%20the%20box.%3C%2FP%3E%0A%3CP%3ETGT%20delegation%20across%20an%20incoming%20trust%20can%20be%20disabled%20by%20setting%20the%20%3CSTRONG%3EEnableTGTDelegation%3C%2FSTRONG%3E%20flag%20to%20%3CSTRONG%3ENo%3C%2FSTRONG%3E%20on%20the%20trust%20using%20netdom.%3C%2FP%3E%0A%3CPRE%20class%3D%22language-cmd%22%20data-role%3D%22codeBlock%22%20data-info%3D%22cmd%22%3E%3CCODE%3Enetdom.exe%20trust%20fabrikam.com%20%2Fdomain%3Acontoso.com%20%2FEnableTGTDelegation%3ANo%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EThis%20flag%20should%20be%20set%20in%20the%20trusted%20forest%20root%20domain%20(such%20as%20%3CA%20href%3D%22http%3A%2F%2Fcontoso.com%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3Econtoso.com%3C%2FA%3E)%20for%20each%20trusting%20forest%20(such%20as%20%3CA%20href%3D%22http%3A%2F%2Ffabrikam.com%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3Efabrikam.com%3C%2FA%3E).%20After%20the%20flag%20is%20set%2C%20the%20trusted%20forest%20will%20no%20longer%20allow%20TGTs%20to%20be%20delegated%20to%20the%20trusting%20forest.%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EThe%20secure%20state%20is%20No.%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EAny%20application%20or%20service%20that%20relies%20on%20unconstrained%20delegation%20across%20forests%20will%20fail.%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EStarting%20with%20the%20March%202019%20security%20updates%2C%20this%20ability%20was%20backported%20to%20%3CSTRONG%3EWindows%20Server%202008%20and%202008%20R2%3C%2FSTRONG%3E.%20Below%20is%20the%20following%20timeline%20that%20Microsoft%20has%20announced%20to%20address%20this%20vulnerability%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EMarch%2012%2C%202019%3C%2FSTRONG%3E%3CBR%20%2F%3EAbility%20to%20disable%20TGT%20delegation%20added%20to%20Windows%20Server%202008%20and%202008%20R2.%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EIMPORTANT%3C%2FSTRONG%3E%20-%20A%20known%20issue%20with%20this%20update%20has%20been%20discovered%20in%20relation%20to%20intra-forest%20scenarios%20and%20Windows%20Server%202008%2F2008R2.%20Authentication%20requests%20for%20accounts%20configured%20for%20unconstrained%20Kerberos%20delegation%20will%20incorrectly%20fail%20in%20intra-forest%20scenarios%20after%20the%20Kerberos%20ticket%20expires%20due%20to%20an%20issue%20that%20occurs%20after%20the%20March%202019%20updates.%3C%2FP%3E%0A%3CP%3EThe%20following%20updates%20are%20affected%20by%20this%20issue%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EWindows%20Server%202008%20SP2%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4489880%2Fwindows-server-2008-kb4489880%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EMarch%2012%2C%202019%20%E2%80%94%20KB4489880%20(Monthly%20Rollup)%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4489876%2Fwindows-server-2008-kb4489876%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EMarch%2012%2C%202019%20%E2%80%94%20KB4489876%20(Security-only%20update)%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4489887%2Fwindows-server-2008-update-kb4489887%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EMarch%2019%2C%202019%20%E2%80%94%20KB4489887%20(Preview%20of%20Monthly%20Rollup)%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EWindows%20Server%202008%20R2%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4489878%2Fwindows-7-update-kb4489878%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EMarch%2012%2C%202019%20%E2%80%94%20KB4489878%20(Monthly%20Rollup)%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4489885%2Fwindows-7-update-kb4489885%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EMarch%2012%2C%202019%20%E2%80%94%20KB4489885%20(Security-only%20update)%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4489892%2Fwindows-7-update-kb4489892%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EMarch%2019%2C%202019%20%E2%80%94%20KB4489892%20(Preview%20of%20Monthly%20Rollup)%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EThe%20following%20workaround%20guidance%20is%20recommended%20if%20the%20update%20has%20been%20installed%3A%3C%2FP%3E%0A%3CP%3E%3CIMG%20src%3D%22https%3A%2F%2Fuser-images.githubusercontent.com%2F26909696%2F55690918-453d8100-595d-11e9-97a1-a037fb9f81b8.jpg%22%20border%3D%220%22%20alt%3D%22knownissue%22%20%2F%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EMay%2014%2C%202019%3C%2FSTRONG%3E%3CBR%20%2F%3EAn%20update%20will%20be%20released%20that%20will%20change%20the%20default%20behavior%20of%20%3CSTRONG%3EEnableTGTDelegation%3C%2FSTRONG%3E%20to%20add%20a%20safe%20default%20configuration.%20If%20delegation%20is%20required%20across%20trusts%2C%20this%20flag%20should%20be%20set%20to%20%3CSTRONG%3EYes%3C%2FSTRONG%3E%20before%20the%20July%202019%20updates%20are%20installed.%20After%20this%20update%2C%20any%20newly%20created%20trusts%20will%20have%20the%20new%20default%20of%20%3CSTRONG%3EEnableTGTDelegation%3C%2FSTRONG%3E%20trust%20flag%20set%20to%20%3CSTRONG%3ENo%3C%2FSTRONG%3E.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EJuly%209%2C%202019%3C%2FSTRONG%3E%3CBR%20%2F%3EAn%20update%20will%20be%20released%20that%20will%20force%20the%20trust%20flag%20on%20%3CSTRONG%3Eexisting%3C%2FSTRONG%3E%20trusts%20and%20disable%20TGT%20delegation%20by%20default.%20Any%20trust%20that%20has%20been%20configured%20to%20continue%20using%20delegation%20after%20May%2014%2C%202019%20will%20not%20be%20affected.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EThe%20July%202019%20update%20cycle%20is%20the%20one%20that%20could%20cause%20issues%20in%20an%20existing%20environment.%20After%20those%20month's%20updates%20are%20installed%2C%20any%20existing%20forest%20trusts%20will%20have%20TGT%20delegation%20disabled%20by%20default.%20This%20could%20cause%20applications%20and%20services%20to%20fail%20that%20require%20unconstrained%20delegation%20across%20a%20trust.%20Because%20of%20the%20possibility%20of%20this%20issue%20affecting%20customers%2C%20it%20is%20recommended%20that%20you%20start%20evaluating%20applications%20and%20accounts%20that%20might%20be%20affected%20by%20this%20change%20as%20soon%20as%20possible.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ETo%20help%20determine%20if%20any%20applications%20or%20accounts%20are%20using%20the%20unsafe%20delegation%2C%20use%20the%20following%20resources%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EPowerShell%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3EA%20quick%20command%20can%20be%20run%20against%20a%20trust%20from%20PowerShell%20that%20will%20determine%20if%20the%20flag%20is%20set%20on%20an%20inbound%20trust.%20Run%20this%20command%20from%20the%20forest%20that%20has%20the%20inbound%20trust%3A%3C%2FP%3E%0A%3CPRE%20class%3D%22language-powershell%22%20data-role%3D%22codeBlock%22%20data-info%3D%22powershell%22%3EGet%3CSPAN%20class%3D%22token%20operator%22%3E-%3C%2FSPAN%3EADTrust%20%3CSPAN%20class%3D%22token%20operator%22%3E-%3C%2FSPAN%3E%3CSPAN%20class%3D%22token%20keyword%22%3EFilter%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22token%20punctuation%22%3E%7B%3C%2FSPAN%3EDirection%20%3CSPAN%20class%3D%22token%20operator%22%3E-eq%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22token%20string%22%3E%22Inbound%22%3C%2FSPAN%3E%3CSPAN%20class%3D%22token%20punctuation%22%3E%7D%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22token%20punctuation%22%3E%7C%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22token%20function%22%3Eft%3C%2FSPAN%3E%20Name%3CSPAN%20class%3D%22token%20punctuation%22%3E%2C%3C%2FSPAN%3ETGTDelegation%0A%3C%2FPRE%3E%0A%3CP%3EThe%20value%20returned%20from%20the%20above%20command%20is%20counterintuitive%20and%20is%20backwards%20from%20what%20you%20might%20expect%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EFALSE%3C%2FSTRONG%3E%20-%20A%20return%20of%20false%20means%20that%20the%20delegation%20is%20enabled%20and%20is%20in%20the%20unsafe%20state.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3ETRUE%3C%2FSTRONG%3E%20-%20A%20return%20of%20true%20indicates%20that%20the%20delegation%20is%20disabled%20and%20is%20in%20the%20safe%20state.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3EA%20script%20has%20been%20created%20that%20can%20scan%20forests%20that%20have%20incoming%20trusts%20that%20allow%20TGT%20delegation.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3ERefer%20to%20this%20support%20article%20for%20the%20PowerShell%20code%3A%3CBR%20%2F%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4490425%2Fupdates-to-tgt-delegation-across-incoming-trusts-in-windows-server%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EKB4490425%20-%20Updates%20to%20TGT%20delegation%20across%20incoming%20trusts%20in%20Windows%20Server%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3ECopy%20and%20Paste%20the%20code%20from%20the%20support%20article%20into%20a%20file%20named%20%3CSTRONG%3EGet-RiskyServiceAccountsByTrust.ps1%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3EThere%20are%20two%20options%20switches%20that%20the%20script%20can%20be%20executed%20with%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3E-Collect%3C%2FSTRONG%3E%20will%20output%20any%20principals%20that%20have%20unconstrained%20delegation.%3C%2FP%3E%0A%3CPRE%20class%3D%22language-cmd%22%20data-role%3D%22codeBlock%22%20data-info%3D%22cmd%22%3E%3CCODE%3EGet-RiskyServiceAccountByTrust.ps1%20-Collect%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3E-Collect%20-Scanall%3C%2FSTRONG%3E%20will%20output%20security%20principals%20that%20have%20unconstrained%20delegation%20and%20search%20across%20trusts%20that%20do%20not%20allow%20TGT%20delegation%3C%2FP%3E%0A%3CPRE%20class%3D%22language-cmd%22%20data-role%3D%22codeBlock%22%20data-info%3D%22cmd%22%3E%3CCODE%3EGet-RiskyServiceAccountByTrust.ps1%20-Collect%20-ScanAll%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3E%3CSTRONG%3EExample%20of%20Output%3C%2FSTRONG%3E%3A%3CBR%20%2F%3E%3CIMG%20src%3D%22https%3A%2F%2Fuser-images.githubusercontent.com%2F26909696%2F55266886-3106cf00-524d-11e9-828e-8728879b232c.jpg%22%20border%3D%220%22%20alt%3D%22PoSHOutput.jpg%22%20%2F%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EEvent%20Viewer%2FEvent%20Logs%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3EIn%20an%20Active%20Directory%20domain%20when%20a%20Kerberos%20ticket%20is%20issued%2C%20the%20domain%20controller%20logs%20security%20events.%20These%20events%20contain%20information%20about%20the%20target%20domain%20and%20can%20be%20utilized%20to%20determine%20whether%20unconstrained%20delegation%20is%20being%20used%20across%20incoming%20trusts.%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3ECheck%20for%20events%20that%20contain%20a%20%3CSTRONG%3ETargetDomainName%3C%2FSTRONG%3E%20value%20that%20matches%20the%20trusted%20forest%20name.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3ECheck%20for%20events%20that%20contain%20a%20%3CSTRONG%3ETicketOptions%3C%2FSTRONG%3E%20value%20that%20contains%20the%20%3CSTRONG%3Eok_as_delegate%3C%2FSTRONG%3E%20flag%20(0x00040000)%3CBR%20%2F%3E%3CIMG%20src%3D%22https%3A%2F%2Fuser-images.githubusercontent.com%2F26909696%2F55169601-12b4ac80-5143-11e9-81c4-c3be6c05fae7.jpg%22%20border%3D%220%22%20alt%3D%22TGTEventLogID.jpg%22%20%2F%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CH2%20class%3D%22mume-header%22%20id%3D%22toc-hId-896189797%22%20id%3D%22toc-hId-896189797%22%3E%26nbsp%3B%3C%2FH2%3E%0A%3CH2%20id%3D%22next-steps%22%20class%3D%22mume-header%22%20id%3D%22toc-hId--1655967164%22%20id%3D%22toc-hId--1655967164%22%3ENext%20Steps%3C%2FH2%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3EUpdate%20any%20Windows%20Server%202008%20or%202008%20R2%20domain%20controllers%20with%20the%20March%202019%20security%20updates%20as%20soon%20as%20possible.%20%3CSTRONG%3EView%20known%20issues%20above%20before%20proceeding%3C%2FSTRONG%3E.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3EDetermine%20the%20applications%20and%20accounts%20that%20could%20be%20affected%20now%2C%20and%20if%20there%20aren't%20any%2C%20and%20a%20trust%20is%20in%20place%2C%20disable%20the%20delegation%20as%20soon%20as%20possible%20to%20be%20in%20a%20safe%20configuration.%3C%2FP%3E%0A%3CPRE%20class%3D%22language-cmd%22%20data-role%3D%22codeBlock%22%20data-info%3D%22cmd%22%3E%3CCODE%3Enetdom.exe%20trust%20fabrikam.com%20%2Fdomain%3Acontoso.com%20%2FEnableTGTDelegation%3ANo%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3EApplications%20that%20rely%20on%20unconstrained%20delegation%20should%20be%20configured%20to%20use%20resource-constrained%20delegation.%20See%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fwindows-server%2Fsecurity%2Fkerberos%2Fkerberos-constrained-delegation-overview%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EKerberos%20Constrained%20Delegation%20Overview%3C%2FA%3E%20for%20more%20information.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3EOnce%20you%20have%20set%20the%20applications%20to%20resource-based%20constrained%20delegation%2C%20set%20the%20flag%20to%20%3CSTRONG%3ENo%3C%2FSTRONG%3E.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3EIf%20it's%20determined%20that%20applications%20or%20accounts%20do%20exist%20that%20require%20this%20delegation%20in%20the%20environment%2C%20then%20set%20the%20flag%20to%20%3CSTRONG%3EYes%3C%2FSTRONG%3E%2C%20%3CSTRONG%3EBEFORE%3C%2FSTRONG%3E%20the%20July%202019%20updates.%20This%20is%20not%20recommended%20and%20should%20be%20avoided.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CH3%20class%3D%22mume-header%22%20id%3D%22toc-hId--109670334%22%20id%3D%22toc-hId--109670334%22%3E%26nbsp%3B%3C%2FH3%3E%0A%3CH3%20id%3D%22important-resources-and-links%22%20class%3D%22mume-header%22%20id%3D%22toc-hId-1633140001%22%20id%3D%22toc-hId-1633140001%22%3EImportant%20Resources%20and%20Links%3C%2FH3%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4490425%2Fupdates-to-tgt-delegation-across-incoming-trusts-in-windows-server%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EKB4490425%20-%20Updates%20to%20TGT%20delegation%20across%20incoming%20trusts%20in%20Windows%20Server%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fportal.msrc.microsoft.com%2Fen-us%2Fsecurity-guidance%2Fadvisory%2FADV190006%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EADV190006%20-%20Guidance%20to%20mitigate%20unconstrained%20delegation%20vulnerabilities%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fwindows-server%2Fsecurity%2Fkerberos%2Fkerberos-constrained-delegation-overview%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EKerberos%20Constrained%20Delegation%20Overview%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fblogs.technet.microsoft.com%2F389thoughts%2F2017%2F04%2F18%2Fget-rid-of-accounts-that-use-kerberos-unconstrained-delegation%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EGet%20rid%20of%20accounts%20that%20use%20Kerberos%20Unconstrained%20Delegation%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fwww.petri.com%2Funderstanding-kerberos-delegation-in-windows-server-active-directory%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3EUnderstanding%20Kerberos%20Delegation%20in%20Windows%20Server%20Active%20Directory%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fposts.specterops.io%2Fhunting-in-active-directory-unconstrained-delegation-forests-trusts-71f2b33688e1%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3EHunting%20in%20Active%20Directory%3A%20Unconstrained%20Delegation%20%26amp%3B%20Forests%20Trusts%3C%2FA%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CH3%20class%3D%22mume-header%22%20id%3D%22toc-hId--919016960%22%20id%3D%22toc-hId--919016960%22%3E%26nbsp%3B%3C%2FH3%3E%0A%3CH3%20id%3D%22acknowledgements%22%20class%3D%22mume-header%22%20id%3D%22toc-hId-823793375%22%20id%3D%22toc-hId-823793375%22%3EAcknowledgements%3C%2FH3%3E%0A%3CP%3EI%20would%20like%20to%20thank%20the%20following%20people%20for%20helping%20pull%20this%20post%20together%20and%20provide%20content%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EAlan%20La%20Pietra%20-%20Microsoft%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EDavid%20Loder%20-%20Microsoft%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3ESteve%20Syfuhs%20-%20Microsoft%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EBrandon%20Wilson%20%E2%80%93%20Microsoft%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EMichiko%20Short%20-%20Microsoft%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CSTRONG%3EPaul%20Miller%20-%20Microsoft%3C%2FSTRONG%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%3C%2FLINGO-BODY%3E%3CLINGO-TEASER%20id%3D%22lingo-teaser-440261%22%20slang%3D%22en-US%22%3E%3CP%3EHello%20Everyone!%20Allen%20Sudbring%20here%2C%20Premier%20Field%20Engineer%20at%20Microsoft.%20Today%20I'm%20putting%20a%20post%20out%20to%20get%20some%20critical%20information%20to%20everyone%20who%20supports%20Windows%20Server%20and%20Active%20Directory%20Domain%20Services.%3C%2FP%3E%0A%3CP%3EIf%20you%20haven%E2%80%99t%20seen%20the%20KB%20article%20that%20this%20post%20references%20I%20encourage%20you%20to%20check%20out%20its%20content%2C%20I%20promise%20it%E2%80%99s%20important!%3C%2FP%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Fhelp%2F4490425%2Fupdates-to-tgt-delegation-across-incoming-trusts-in-windows-server%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%20target%3D%22_blank%22%3EKB4490425%20-%20Updates%20to%20TGT%20delegation%20across%20incoming%20trusts%20in%20Windows%20Server%3C%2FA%3E%3C%2FP%3E%3C%2FLINGO-TEASER%3E%3CLINGO-LABS%20id%3D%22lingo-labs-440261%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3Eallen%20sudbring%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EProductAnnoucement%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Microsoft

Hello Everyone! Allen Sudbring here, Premier Field Engineer at Microsoft. Today I'm putting a post out to get some critical information to everyone who supports Windows Server and Active Directory Domain Services.

If you haven’t seen the KB article that this post references I encourage you to check out its content, I promise it’s important!

KB4490425 - Updates to TGT delegation across incoming trusts in Windows Server

 

With the introduction of Windows Server 2012, a new feature was added to Active Directory Domain Services that enforced the forest boundary for Kerberos unconstrained delegation. This allowed an administrator of a trusted forest to configure whether TGTs can be delegated to a service in the trusting forest. Unfortunately, an unsafe, default configuration exists within this feature when creating an inbound trust that could allow an attacker in the trusting forest to request the delegation of a TGT for an identity from the trusted forest.

 

So what does this all mean?

 

Let's back up a little bit and do a brief explanation on Kerberos delegation.

There are three kinds of Kerberos delegation in Active Directory:

  • Unconstrained
    When a Domain Administrator configures a service’s account to be trusted for unconstrained delegation, that service has the ability to impersonate any user account to any other service. This is the most insecure delegation option, because a service could impersonate any user to any other service it likes. For a regular user account, not so bad, but for a Domain Admin or an Enterprise Admin, a rogue service could request information from the domain or change user account or group permissions in the name of the privileged account. For this reason, unconstrained Kerberos delegation is a high security risk.

  • Constrained
    First introduced with Windows Server 2003, constrained delegation allows an administrator to limit the services to which an impersonated account can connect to. Constrained delegation is difficult to configure and requires unique SPN's to be registered as well as Domain Admin rights to implement. Constrained delegation cannot cross domain or forest boundaries.

  • Resource-based Constrained
    First introduced with Windows Server 2012, Resource-based constrained delegation improved on the constrained delegation introduced with Windows Server 2003. It eliminated the need for SPNs by switching to security descriptors. This removed the need for Domain Admin rights to implement and allowed server administrators of backend services to control which service principals can request Kerberos tickets for another user. Resource based allows delegation across domain and forest boundaries.

For more information on Kerberos delegation, refer to this documentation:

Kerberos Constrained Delegation Overview

 

All currently supported versions of Windows Server that are utilized for Active Directory Domain controllers have this vulnerability:

  • Windows Server 2008

  • Windows Server 2008 R2

  • Windows Server 2012

  • Windows Server 2012 R2

  • Windows Server 2016

  • Windows Server 2019

 

Let’s say you are responsible for the Contoso forest and you have a partner who owns the Fabrikam forest whose resources your users use. How could an attacker in Fabrikam take advantage of this vulnerability?

 

First, they need to have the ability to configure a service they own to be trusted for unconstrained delegation. By default, this requires domain administrator privilege in the fabrikam.com forest.

Next, they need to get your user to authenticate their rogue service in your partner’s Fabrikam forest.

Now they have your user’s TGT which they can use to authenticate to any service as that user.

 

Technical Overview of the Vulnerability

As a consequence of this vulnerability an attacker who has control of a forest with an inbound trust to another forest can request a TGT for a user in the trusted forest by enabling unconstrained delegation on a service principal in the trusting forest. The attacker would need to convince the user to authenticate to the resource in the trusting forest thereby allowing the attacker to request a delegated TGT.

To mitigate this vulnerability, a netdom command can be executed that will disable TGT delegation.

EnableTGTDelegation flag is enabled on Windows Server 2008 and Windows Server 2008 R2 devices after installing the March 12, 2019 updates. Windows Server 2012 and higher, the EnableTGTDelegation flag is in the operating system out of the box.

TGT delegation across an incoming trust can be disabled by setting the EnableTGTDelegation flag to No on the trust using netdom.

netdom.exe trust fabrikam.com /domain:contoso.com /EnableTGTDelegation:No
  • This flag should be set in the trusted forest root domain (such as contoso.com) for each trusting forest (such as fabrikam.com). After the flag is set, the trusted forest will no longer allow TGTs to be delegated to the trusting forest.

  • The secure state is No.

  • Any application or service that relies on unconstrained delegation across forests will fail.

Starting with the March 2019 security updates, this ability was backported to Windows Server 2008 and 2008 R2. Below is the following timeline that Microsoft has announced to address this vulnerability:

  • March 12, 2019
    Ability to disable TGT delegation added to Windows Server 2008 and 2008 R2.

    The following workaround guidance is recommended if the update has been installed:

    knownissue

  • May 14, 2019
    An update will be released that will change the default behavior of EnableTGTDelegation to add a safe default configuration. If delegation is required across trusts, this flag should be set to Yes before the July 2019 updates are installed. After this update, any newly created trusts will have the new default of EnableTGTDelegation trust flag set to No.

  • July 9, 2019
    An update will be released that will force the trust flag on existing trusts and disable TGT delegation by default. Any trust that has been configured to continue using delegation after May 14, 2019 will not be affected.

The July 2019 update cycle is the one that could cause issues in an existing environment. After those month's updates are installed, any existing forest trusts will have TGT delegation disabled by default. This could cause applications and services to fail that require unconstrained delegation across a trust. Because of the possibility of this issue affecting customers, it is recommended that you start evaluating applications and accounts that might be affected by this change as soon as possible.

 

To help determine if any applications or accounts are using the unsafe delegation, use the following resources:

  • PowerShell

    • A quick command can be run against a trust from PowerShell that will determine if the flag is set on an inbound trust. Run this command from the forest that has the inbound trust:

      Get-ADTrust -Filter {Direction -eq "Inbound"} | ft Name,TGTDelegation
      

      The value returned from the above command is counterintuitive and is backwards from what you might expect:

      • FALSE - A return of false means that the delegation is enabled and is in the unsafe state.

      • TRUE - A return of true indicates that the delegation is disabled and is in the safe state.

    • A script has been created that can scan forests that have incoming trusts that allow TGT delegation.

    • Refer to this support article for the PowerShell code:
      KB4490425 - Updates to TGT delegation across incoming trusts in Windows Server

    • Copy and Paste the code from the support article into a file named Get-RiskyServiceAccountsByTrust.ps1

    • There are two options switches that the script can be executed with:

      • -Collect will output any principals that have unconstrained delegation.

        Get-RiskyServiceAccountByTrust.ps1 -Collect
        
      • -Collect -Scanall will output security principals that have unconstrained delegation and search across trusts that do not allow TGT delegation

        Get-RiskyServiceAccountByTrust.ps1 -Collect -ScanAll
        

      Example of Output:
      PoSHOutput.jpg

  • Event Viewer/Event Logs

    • In an Active Directory domain when a Kerberos ticket is issued, the domain controller logs security events. These events contain information about the target domain and can be utilized to determine whether unconstrained delegation is being used across incoming trusts.

      • Check for events that contain a TargetDomainName value that matches the trusted forest name.

      • Check for events that contain a TicketOptions value that contains the ok_as_delegate flag (0x00040000)
        TGTEventLogID.jpg

 

Next Steps

  • Update any Windows Server 2008 or 2008 R2 domain controllers with the March 2019 security updates as soon as possible. View known issues above before proceeding.

  • Determine the applications and accounts that could be affected now, and if there aren't any, and a trust is in place, disable the delegation as soon as possible to be in a safe configuration.

    netdom.exe trust fabrikam.com /domain:contoso.com /EnableTGTDelegation:No
    
  • Applications that rely on unconstrained delegation should be configured to use resource-constrained delegation. See Kerberos Constrained Delegation Overview for more information.

  • Once you have set the applications to resource-based constrained delegation, set the flag to No.

  • If it's determined that applications or accounts do exist that require this delegation in the environment, then set the flag to Yes, BEFORE the July 2019 updates. This is not recommended and should be avoided.

 

 

Acknowledgements

I would like to thank the following people for helping pull this post together and provide content:

  • Alan La Pietra - Microsoft

  • David Loder - Microsoft

  • Steve Syfuhs - Microsoft

  • Brandon Wilson – Microsoft

  • Michiko Short - Microsoft

  • Paul Miller - Microsoft