{"id":454,"date":"2023-09-22T09:42:08","date_gmt":"2023-09-22T06:42:08","guid":{"rendered":"https:\/\/tech.zeleneew.ru\/?p=454"},"modified":"2023-09-25T21:49:54","modified_gmt":"2023-09-25T18:49:54","slug":"%d0%b0%d1%83%d0%b4%d0%b8%d1%82-%d0%bf%d0%b0%d1%80%d0%be%d0%bb%d0%b5%d0%b9-windows-ad","status":"publish","type":"post","link":"https:\/\/tech.zeleneew.ru\/?p=454","title":{"rendered":"\u0410\u0443\u0434\u0438\u0442 \u043f\u0430\u0440\u043e\u043b\u0435\u0439 Windows AD"},"content":{"rendered":"\n<p class=\"has-text-align-right\">\u041e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a <a href=\"https:\/\/www.dsinternals.com\/en\/auditing-active-directory-password-quality\/\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n\n\n\n<p>\u041f\u043e\u0441\u043b\u0435\u0434\u043d\u044f\u044f \u0432\u0435\u0440\u0441\u0438\u044f \u043c\u043e\u0434\u0443\u043b\u044f <a href=\"https:\/\/github.com\/MichaelGrafnetter\/DSInternals\">DSInternals PowerShell<\/a> \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043d\u043e\u0432\u044b\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 Test-PasswordQuality, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u043c\u043e\u0449\u043d\u044b\u0439, \u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442 \u0434\u043b\u044f \u0430\u0443\u0434\u0438\u0442\u0430 \u043f\u0430\u0440\u043e\u043b\u0435\u0439 Active Directory. \u041e\u043d \u043c\u043e\u0436\u0435\u0442 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u0432\u0430\u0442\u044c \u0441\u043b\u0430\u0431\u044b\u0435, \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u044e\u0449\u0438\u0435\u0441\u044f, \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435, \u0431\u0435\u0441\u0441\u0440\u043e\u0447\u043d\u044b\u0435 \u0438\u043b\u0438 \u043f\u0443\u0441\u0442\u044b\u0435 \u043f\u0430\u0440\u043e\u043b\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c \u0443\u0447\u0435\u0442\u043d\u044b\u0435 \u0437\u0430\u043f\u0438\u0441\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0430\u0440\u0443\u0448\u0430\u044e\u0442 \u043b\u0443\u0447\u0448\u0438\u0435 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0438 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u0438. \u0412\u0441\u0435 \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0430\u0442\u043e\u0440\u044b \u0434\u043e\u043c\u0435\u043d\u0430 \u0442\u0435\u043f\u0435\u0440\u044c \u043c\u043e\u0433\u0443\u0442 \u0440\u0435\u0433\u0443\u043b\u044f\u0440\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u043f\u0430\u0440\u043e\u043b\u0438 Active Directory \u0431\u0435\u0437 \u043a\u0430\u043a\u0438\u0445-\u043b\u0438\u0431\u043e \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0445 \u0437\u043d\u0430\u043d\u0438\u0439.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430<\/h2>\n\n\n\n<p>\u0412\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u043e\u043f\u0438\u0441\u0430\u043d\u044b <a href=\"https:\/\/github.com\/MichaelGrafnetter\/DSInternals\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n\n\n\n<h3 class=\"wp-block-heading has-text-align-center\">Offline \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u043c\u043e\u0434\u0443\u043b\u044f (PowerShell 3+)<\/h3>\n\n\n\n<ol class=\"wp-block-list\">\n<li>\u0421\u043a\u0430\u0447\u0430\u0439\u0442\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u0441 <a href=\"https:\/\/github.com\/MichaelGrafnetter\/DSInternals\/releases\">GitHub<\/a>. <\/li>\n\n\n\n<li>\u0418\u0437\u0432\u043b\u0435\u043a\u0438\u0442\u0435 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 DSInternals \u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 \u043c\u043e\u0434\u0443\u043b\u0435\u0439 PowerShell, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440. <code>C:\\Windows\\system32\\WindowsPowerShell\\v1.0\\Modules\\DSInternals<\/code> \u0438\u043b\u0438 <code>C:\\Users\\John\\Documents\\WindowsPowerShell\\Modules\\DSInternals<\/code>. <\/li>\n\n\n\n<li>(Optional) E\u0441\u043b\u0438 \u0432\u044b \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043b\u0438 \u043c\u043e\u0434\u0443\u043b\u044c \u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433, \u043e\u0442\u043b\u0438\u0447\u043d\u044b\u0439 \u043e\u0442 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u043d\u0430 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u043c \u0448\u0430\u0433\u0435, \u0432\u0430\u043c \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u0430 <code>Import-Module<\/code>.<\/li>\n<\/ol>\n\n\n\n<h2 class=\"wp-block-heading\">\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435<\/h2>\n\n\n\n<ol class=\"wp-block-list\">\n<li><\/li>\n<\/ol>\n\n\n\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 <code>Test-PasswordQuality<\/code> \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u0432\u044b\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u043e\u0432 <a href=\"https:\/\/www.dsinternals.com\/en\/dumping-ntds-dit-files-using-powershell\/\"><code>Get-ADDBAccount<\/code><\/a><code> <\/code>\u0438 <a href=\"https:\/\/www.dsinternals.com\/en\/retrieving-active-directory-passwords-remotely\/\"><code>Get-ADReplAccount<\/code><\/a>, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0430\u043d\u0430\u043b\u0438\u0437 \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u0432\u043e\u0434\u0438\u0442\u044c \u043a\u0430\u043a \u0432 \u0430\u0432\u0442\u043e\u043d\u043e\u043c\u043d\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435 (ntds.dit), \u0442\u0430\u043a \u0438 \u0432 \u043e\u043f\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435 (DCSync):<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-ADReplAccount -All -Server LON-DC1 -NamingContext \"dc=adatum,dc=com\" |\n   Test-PasswordQuality -WeakPasswordHashes .\\pwned-passwords-ntlm-ordered-by-count.txt -IncludeDisabledAccounts<\/code><\/pre>\n\n\n\n<p>\u041c\u043d\u043e\u0433\u043e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043f\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044e \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c <a href=\"https:\/\/winitpro.ru\/index.php\/2016\/09\/20\/audit-active-directory-password\/\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u041f\u0440\u0438\u043c\u0435\u0440<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code># \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u0443\u0435\u043c \u043c\u043e\u0434\u0443\u043b\u044c \nImport-Module DSInternals\n# \u0435\u0441\u043b\u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043e\u0442\u043e\u0431\u0440\u0430\u0437\u0438\u0442\u044c \u043f\u0430\u0440\u043e\u043b\u0438, \u0442\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043c\u043e\u0434\u0443\u043b\u044c \u0432\u0435\u0440\u0441\u0438\u0438 2.23\n# Import-Module DSInternals  -RequiredVersion 2.23\n# \n$DC = \"dc.zeleneew.ru\"\n$Domain = \"DC=dc,DC=zeleneew,dc=ru\"\n# \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c \u043f\u0443\u0442\u044c \u043a \u0441\u043b\u043e\u0432\u0430\u0440\u044e, \u043f\u043e \u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u0431\u0443\u0434\u0435\u043c \u043f\u043e\u0434\u0431\u0438\u0440\u0430\u0442\u044c \u043f\u0430\u0440\u043e\u043b\u0438\n$Dict = \"C:\\DSInternals\\PasswordDict.txt\"\n# \"\u0445\u044d\u0448\u0438\u0440\u0443\u0435\u043c\" \u0441\u043b\u043e\u0432\u0430\u0440\u044c\n$DictHash = Get-Content $Dict | ConvertTo-NTHashDictionary\n\nGet-ADReplAccount -All -Server $DC -NamingContext $Domain | Test-PasswordQuality -WeakPasswordHashes $DictHash -ShowPlainTextPasswords -IncludeDisabledAccounts\n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u041e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a \u0437\u0434\u0435\u0441\u044c. \u041f\u043e\u0441\u043b\u0435\u0434\u043d\u044f\u044f \u0432\u0435\u0440\u0441\u0438\u044f \u043c\u043e\u0434\u0443\u043b\u044f DSInternals PowerShell \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043d\u043e\u0432\u044b\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 Test-PasswordQuality, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u043c\u043e\u0449\u043d\u044b\u0439, \u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442 \u0434\u043b\u044f \u0430\u0443\u0434\u0438\u0442\u0430 \u043f\u0430\u0440\u043e\u043b\u0435\u0439 Active Directory. \u041e\u043d \u043c\u043e\u0436\u0435\u0442 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u0432\u0430\u0442\u044c \u0441\u043b\u0430\u0431\u044b\u0435, \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u044e\u0449\u0438\u0435\u0441\u044f, \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435, \u0431\u0435\u0441\u0441\u0440\u043e\u0447\u043d\u044b\u0435 \u0438\u043b\u0438 \u043f\u0443\u0441\u0442\u044b\u0435 \u043f\u0430\u0440\u043e\u043b\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c \u0443\u0447\u0435\u0442\u043d\u044b\u0435 &hellip; <a href=\"https:\/\/tech.zeleneew.ru\/?p=454\">\u0427\u0438\u0442\u0430\u0442\u044c \u0434\u0430\u043b\u0435\u0435 <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-454","post","type-post","status-publish","format-standard","hentry","category-1"],"_links":{"self":[{"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=\/wp\/v2\/posts\/454","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=454"}],"version-history":[{"count":3,"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=\/wp\/v2\/posts\/454\/revisions"}],"predecessor-version":[{"id":457,"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=\/wp\/v2\/posts\/454\/revisions\/457"}],"wp:attachment":[{"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=454"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=454"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tech.zeleneew.ru\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=454"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}