一、前言: Windows Server 2008提供了新的 [Fine-Grained Password Policies]來處理這類的需求。要使用這個功能必須網域的功能等級先提昇為Windows Server 2008等級,接著透過AD網域中新的[Password Settings Container]的位置來進行設定,這個位置可使用[AD Users and Computers]管理工具,使用[Advanced Features]來開啟System位置就可看到,不過您必須要使用[Adsiedit.msc]或[Ldifde]工具來設定!
二、做法: 1. 請先建立一個全域安全性群組,例如:GSGroup1. 2. 將您想要排除的Account加為GSGroup1的成員. 3. 建立PSO
4. To create a PSO using ADSI Edit
All the PSO objects that have been created in the selected domain appear.
Attribute sample:
Attribute name
Description
Acceptable value range
Example value
msDS-PasswordSettingsPrecedence
Password Settings Precedence
Greater than 0
10
msDS-PasswordReversibleEncryptionEnabled
Password reversible encryption status for user accounts
FALSE / TRUE (Recommended: FALSE)
FALSE
msDS-PasswordHistoryLength
Password History Length for user accounts
0 through 1024
24
msDS-PasswordComplexityEnabled
Password complexity status for user accounts
FALSE / TRUE (Recommended: TRUE)
TRUE
msDS-MinimumPasswordLength
Minimum Password Length for user accounts
0 through 255
8
msDS-MinimumPasswordAge
Minimum Password Age for user accounts
· (None)
· 00:00:00:00 through msDS-MaximumPasswordAge value
1:00:00:00 (1 day)
msDS-MaximumPasswordAge
Maximum Password Age for user accounts
· (Never)
· msDS-MinimumPasswordAge value through (Never)
· msDS-MaximumPasswordAge cannot be set to zero
42:00:00:00 (42 days)
msDS-LockoutThreshold
Lockout threshold for lockout of user accounts
0 through 65535
msDS-LockoutObservationWindow
Observation Window for lockout of user accounts
· 00:00:00:01 through msDS-LockoutDuration value
0:00:30:00 (30 minutes)
msDS-LockoutDuration
Lockout duration for locked out user accounts
· msDS-LockoutObservationWindow value through (Never)
msDS-PSOAppliesTo
Links to objects that this password settings object applies to (forward link)
0 or more DNs of users or global security groups
“CN=u1,CN=Users,DC=DC1,DC=contoso
12. On the last screen of the wizard, click More Attributes.
13. On the Select which property to view menu, click Optional or Both.
14. In the Select a property to view drop-down list, select msDS-PSOAppliesTo.
15. In Edit Attribute, add the distinguished names of users or global security groups that the PSO is to be applied to, and then click Add.
16. Repeat step 15 to apply the PSO to more users or global security groups.
17. Click Finish.
5. To apply PSOs to users or global security groups using the Windows interface
Where?
三、注意事項: 透過PSO物件的屬性設定來套用,極可能會有衝突的情形產生(多個PSO設定到單一物件),因此PSO有一個重要屬性[msDS-PasswordSettingsPrecedence]! 這屬性是一個1以上的整數值,越低的數字代表有較高的排序(優先權),例如有兩個PSO分別的屬性值為10與20,10的優先權比較高因此會真的套用到物件上;此外,如果屬性值一樣的話,那就以PSO的GUID比較小的會套用! 另外如果有分別的PSO設定到使用者帳戶與使用者所隸屬群組的話,則套用到使用者帳戶的才是結果PSO!
參考資訊連結: AD DS Fine-Grained Password and Account Lockout Policy Step-by-Step Guide http://technet.microsoft.com/en-us/library/cc770842.aspx
The Solution is to avoid unwanted events by uing AdtAdmin along with WQL Query as listed below
An ACS collector can use Windows Management Instrumentation (WMI) Query Language (WQL) queries as filters to limit the events that are stored in the ACS database.