In an attempt to reduce future token bloat issues (no issues yet) and reduce our directories attack surface I've been tasked with removing specific Sid history. I've found a command that removes the entire thing, and the ADMT and ADSI tools remove individual accounts one-at-a-time, but I have 6,200 SID histories that need to be removed, and I cannot run the straight "clear attribute" command as there are still about 800 SID histories we need. So, does anyone know the best method on removing specific domain SID history on a large scale?
My three best leads thus far are:
- Remove specifically by domain: Use use Get-SIDHistory to target the removal population with a specific query. Second, pipe the output to Remove-SIDHistory. bit.ly/ucL2Df
- Remove specifically by CSV: I'm unable to find a script tha tallows me to remove by user and SID history specifically. The closest script I've found is here (shariqsheikh.com/blog/index.php/201012/powershell-how-do-i-clear-sidhistory-attribute/), but that one listed sitll only removes by the attribute entirely, and not specifically by domain/SID.
- Using JoeWare's free AdFind and AdMod tools (http://www.joeware.net/freetools/). This is probably my best bet, but because it is a third party application that leads me to not being sure how it'll be recieved in our environment.
Anyone have experience with those options, or have healthy alternatives? I've read all of PFE Ashley Mcglones SID blog posts (blogs.technet.com/b/ashleymcglone/), and every relevant search result on both Bing and Google for a few pages deep. Not too many options at this point.
Thanks for ANY input you guys have!