Lucene search

K
mskbMicrosoftKB2962486
HistoryMay 13, 2014 - 12:00 a.m.

MS14-025: Vulnerability in Group Policy Preferences could allow elevation of privilege: May 13, 2014

2014-05-1300:00:00
Microsoft
support.microsoft.com
4279

9 High

CVSS2

Access Vector

NETWORK

Access Complexity

LOW

Authentication

SINGLE

Confidentiality Impact

COMPLETE

Integrity Impact

COMPLETE

Availability Impact

COMPLETE

AV:N/AC:L/Au:S/C:C/I:C/A:C

<html><body><p>Resolves a vulnerability in Windows that could allow elevation of privilege if Active Directory Group Policy Preferences extensions are used to distribute passwords across the domain. This practice could allow an attacker to retrieve and decrypt the password that is stored together with Group Policy preferences.</p><h2>INTRODUCTION</h2><div>Microsoft has released security bulletin MS14-025. To learn more about this security bulletin:<br /><ul><li>Home users:<br /><div><a href=“https://www.microsoft.com/security/pc-security/updates.aspx” target=“self">https://www.microsoft.com/security/pc-security/updates.aspx</a></div><span>Skip the details</span>: Download the updates for your home computer or laptop from the Microsoft Update website now:<br /><div><a href=“https://update.microsoft.com/microsoftupdate/” target="self">https://update.microsoft.com/microsoftupdate/</a></div></li><li>IT professionals:<br /><div><a href=“https://technet.microsoft.com/security/bulletin/ms14-025” target="self">https://technet.microsoft.com/security/bulletin/MS14-025</a></div></li></ul><h3>How to obtain help and support for this security update<br /></h3>Help installing updates:<br /><a href=“https://support.microsoft.com/ph/6527” target="self">Support for Microsoft Update</a><br /><br />Security solutions for IT professionals:<br /><a href=“https://technet.microsoft.com/security/bb980617.aspx” target="self">TechNet Security Troubleshooting and Support</a><br /><br />Help protect your Windows-based computer Windows from viruses and malware:<br /><a href=“https://support.microsoft.com/contactus/cu_sc_virsec_master” target="self">Virus Solution and Security Center</a><br /><br />Local support according to your country:<br /><a href=“https://support.microsoft.com/common/international.aspx” target=“self">International Support</a><br /><br /></div><h2>More Information</h2><div><h3>Known issues and more information about this security update </h3>The following articles contain more information about this security update as it relates to individual product versions. The articles may contain known issue information. If this is the case, the known issue is listed under each article link. <ul><li><div><a href=“https://support.microsoft.com/en-us/help/2928120”>2928120 </a> <br /><br /><br /><br />MS14-025: Description of the security update for Windows Remote Server Administration Tools for systems that have update 2919355 installed: May 13, 2014<br /><br /></div></li><li><div><a href=“https://support.microsoft.com/en-us/help/2961899”>2961899 </a> <br /><br />MS14-025: Description of the security update for Windows Remote Server Administration Tools for systems that do not have update 2919355 installed: May 13, 2014<br /><br /></div></li></ul></div><h2>Group Policy Preferences</h2><div><h3>Overview<br /></h3>Some Group Policy Preferences can store a password. This functionality is being removed because the password was stored insecurely. This article describes the user interface changes and any available workarounds.<br /><br />The following Group Policy Preferences will no longer allow user names and passwords to be saved: <ul><li>Drive Maps </li><li>Local Users and Groups </li><li>Scheduled Tasks </li><li>Services </li><li>Data Sources </li></ul>This will affect the behavior of any existing Group Policy Objects (GPOs) in your environment that rely on passwords that are contained in these preferences. It will also prevent creating new Group Policy Preferences by using this functionality.<br /><br />For Drive Maps, Local Users and Groups, and Services, you may be able to achieve similar goals through other, more secure functionality in Windows.<br /><br />For Scheduled Tasks and Data Sources, you will be unable to achieve the same goals that were available through the nonsecure functionality of Group Policy Preferences passwords. </div><h2>Scenarios</h2><div>The following Group Policy Preferences are affected by this change. Each preference is covered briefly and then in more detail. Additionally, workarounds are provided that enable you to perform the same tasks. <div><table><tr><td><span>Affected preference </span></td><td><span>Applies to user<br /></span></td><td><span>Applies to computer<br /></span></td></tr><tr><td>Local user management</td><td>Yes</td><td>Yes</td></tr><tr><td>Mapped drives</td><td>Yes</td><td><div>No</div></td></tr><tr><td>Services</td><td><div>No</div></td><td>Yes</td></tr><tr><td>Scheduled tasks (up-level)</td><td>Yes</td><td>Yes</td></tr><tr><td>Scheduled tasks (down-level)</td><td>Yes</td><td>Yes</td></tr><tr><td>Immediate tasks (up-level)</td><td>Yes</td><td>Yes</td></tr><tr><td>Immediate tasks (down-level)</td><td>Yes</td><td>Yes</td></tr><tr><td>Data sources</td><td>Yes</td><td>Yes</td></tr></table></div><h3>Summary of changes </h3><ul><li>Password fields in all affected preferences are disabled. Administrators cannot create new preferences by using these password fields.</li><li>The username field is disabled in some preferences. </li><li>Existing preferences that contain a password cannot be updated. They can only be deleted or disabled, as appropriate for the specific preference.</li><li>The behavior for Delete and Disable actions have not changed for the preferences.</li><li>When an administrator opens any preference that contains the CPassword attribute, the administrator receives the following warning dialog box to inform him or her of the recent deprecation. Attempts to save changes to new or existing preferences that require the CPassword attribute will trigger the same dialog box. Only Delete and Disable actions will not trigger warning dialog boxes.</li></ul><br /><img alt=“CPassword Security Warning” src=“/Library/Images/2967511.png” title=“CPassword Security Warning” /><br /><br /><br /><br /><h3>Scenario 1: Local user management <br /></h3>The Local User Management preference is frequently used to create local administrators who have a known password on a computer. This feature is not secure because of the way that Group Policy Preferences stores passwords. Therefore, this functionality is no longer available. The following preferences are affected: <ul><li>Computer Configuration -> Control Panel Settings -> Local Users and Groups-> New-> Local User</li><li>User Configuration -> Control Panel Settings -> Local Users and Groups-> New-> Local User</li></ul><h4>Important changes </h4><span>Action: Create or Replace </span><ul><li>The <strong>User name</strong>, <strong>Password</strong>, and <strong>Confirm Password</strong> fields are disabled.</li><li>The warning dialog box appears when the administrator opens or tries to save any changes to an existing preference that contains a password.</li></ul><br /><br /><img alt=“Local User - Create or Replace” src=“/Library/Images/2967512.png” title=“Local User - Create or Replace” /><br /><br /><span>Action: Update </span><ul><li>The <strong>Password</strong> and <strong>Confirm Password</strong> fields are disabled.</li><li>The warning dialog box appears when the administrator opens or tries to save any changes to an existing preference that contains a password.</li></ul><br /><br /><img alt=“Local User - Update” src=“/Library/Images/2967513.png” title=“Local User - Update” /><br /><br /><span>Action: Delete </span><ul><li>No change in behavior</li></ul><h4>Workarounds<br /></h4>For those who previously relied on the Group Policy Preference for setting local administrator passwords, the following script is provided as a secure alternative to CPassword. Copy and save the contents to a new Windows PowerShell file, and then run the script as indicated in its .EXAMPLE section.<br /><br /><span>Microsoft provides programming examples for illustration only, without warranty either expressed or implied. This includes, but is not limited to, the implied warranties of merchantability or fitness for a particular purpose. This article assumes that you are familiar with the programming language that is being demonstrated and with the tools that are used to create and to debug procedures. Microsoft support engineers can help explain the functionality of a particular procedure. However, they will not modify these examples to provide added functionality or construct procedures to meet your specific requirements. </span><br /><br /><pre> <br />function Invoke-PasswordRoll<br />{<br /><#<br />.SYNOPSIS<br /><br />This script can be used to set the local account passwords on remote machines to random passwords. The username/password/server combination will be saved in a CSV file.<br />The account passwords stored in the CSV file can be encrypted using a password of the administrators choosing to ensure clear-text account passwords aren’t written to disk.<br />The encrypted passwords can be decrypted using another function in this file: ConvertTo-CleartextPassword<br /><br /><br />Function: Invoke-PasswordRoll<br />Author: Microsoft<br />Version: 1.0<br /><br />.DESCRIPTION<br /><br />This script can be used to set the local account passwords on remote machines to random passwords. The username/password/server combination will be saved in a CSV file.<br />The account passwords stored in the CSV file can be encrypted using a password of the administrators choosing to ensure clear-text account passwords aren’t written to disk.<br />The encrypted passwords can be decrypted using another function in this file: ConvertTo-CleartextPassword<br /><br />.PARAMETER ComputerName<br /><br />An array of computers to run the script against using PowerShell remoting.<br /><br />.PARAMETER LocalAccounts<br /><br />An array of local accounts whose password should be changed.<br /><br />.PARAMETER TsvFileName<br /><br />The file to output the username/password/server combinations to.<br /><br />.PARAMETER EncryptionKey<br /><br />A password to encrypt the TSV file with. Uses AES encryption. Only the passwords stored in the TSV file will be encrypted, the username and servername will be clear-text.<br /><br />.PARAMETER PasswordLength<br /><br />The length of the passwords which will be randomly generated for local accounts.<br /><br />.PARAMETER NoEncryption<br /><br />Do not encrypt the account passwords stored in the TSV file. This will result in clear-text passwords being written to disk.<br /><br />.EXAMPLE<br /><br />. .\Invoke-PasswordRoll.ps1 #Loads the functions in this script file<br />Invoke-PasswordRoll -ComputerName (Get-Content computerlist.txt) -LocalAccounts @(“administrator”,“CustomLocalAdmin”) -TsvFileName “LocalAdminCredentials.tsv” -EncryptionKey “Password1”<br /><br />Connects to all the computers stored in the file “computerlist.txt”. If the local account “administrator” and/or “CustomLocalAdmin” are present on the system, their password is changed<br />to a randomly generated password of length 20 (the default). The username/password/server combinations are stored in LocalAdminCredentials.tsv, and the account passwords are AES encrypted using the password “Password1”.<br /><br />.EXAMPLE<br /><br />. .\Invoke-PasswordRoll.ps1 #Loads the functions in this script file<br />Invoke-PasswordRoll -ComputerName (Get-Content computerlist.txt) -LocalAccounts @(“administrator”) -TsvFileName “LocalAdminCredentials.tsv” -NoEncryption -PasswordLength 40<br /><br />Connects to all the computers stored in the file “computerlist.txt”. If the local account “administrator” is present on the system, its password is changed to a random generated<br />password of length 40. The username/password/server combinations are stored in LocalAdminCredentials.tsv unencrypted.<br /><br />.NOTES<br />Requirements: <br />-PowerShellv2 or above must be installed<br />-PowerShell remoting must be enabled on all systems the script will be run against<br /><br />Script behavior:<br />-If a local account is present on the system, but not specified in the LocalAccounts parameter, the script will write a warning to the screen to alert you to the presence of this local account. The script will continue running when this happens.<br />-If a local account is specified in the LocalAccounts parameter, but the account does not exist on the computer, nothing will happen (an account will NOT be created).<br />-The function ConvertTo-CleartextPassword, contained in this file, can be used to decrypt passwords that are stored encrypted in the TSV file.<br />-If a server specified in ComputerName cannot be connected to, PowerShell will output an error message.<br />-Microsoft advises companies to regularly roll all local and domain account passwords.<br /><br />#><br /> [CmdletBinding(DefaultParameterSetName=“Encryption”)]<br /> Param(<br /> [Parameter(Mandatory=$true)]<br /> [String[]]<br /> $ComputerName,<br /><br /> [Parameter(Mandatory=$true)]<br /> [String[]]<br /> $LocalAccounts,<br /><br /> [Parameter(Mandatory=$true)]<br /> [String]<br /> $TsvFileName,<br /><br /> [Parameter(ParameterSetName=“Encryption”, Mandatory=$true)]<br /> [String]<br /> $EncryptionKey,<br /><br /> [Parameter()]<br /> [ValidateRange(20,120)]<br /> [Int]<br /> $PasswordLength = 20,<br /><br /> [Parameter(ParameterSetName=“NoEncryption”, Mandatory=$true)]<br /> [Switch]<br /> $NoEncryption<br /> )<br /><br /><br /> #Load any needed .net classes<br /> Add-Type -AssemblyName “System.Web” -ErrorAction Stop<br /><br /><br /> #This is the scriptblock that will be executed on every computer specified in ComputerName<br /> $RemoteRollScript = {<br /> Param(<br /> [Parameter(Mandatory=$true, Position=1)]<br /> [String[]]<br /> $Passwords,<br /><br /> [Parameter(Mandatory=$true, Position=2)]<br /> [String[]]<br /> $LocalAccounts,<br /><br /> #This is here so I can record what the server name that the script connected to was, sometimes the DNS records get messed up, it can be nice to have this.<br /> [Parameter(Mandatory=$true, Position=3)]<br /> [String]<br /> $TargettedServerName<br /> )<br /><br /> $LocalUsers = Get-WmiObject Win32_UserAccount -Filter “LocalAccount=true” | Foreach {$.Name}<br /><br /> #Check if the computer has any local user accounts whose passwords are not going to be rolled by this script<br /> foreach ($User in $LocalUsers)<br /> {<br /> if ($LocalAccounts -inotcontains $User)<br /> {<br /> Write-Warning “Server: ‘$($TargettedServerName)’ has a local account ‘$($User)’ whos password is NOT being changed by this script”<br /> }<br /> }<br /><br /> #For every local account specified that exists on this server, change the password<br /> $PasswordIndex = 0<br /> foreach ($LocalAdmin in $LocalAccounts)<br /> {<br /> $Password = $Passwords[$PasswordIndex]<br /><br /> if ($LocalUsers -icontains $LocalAdmin)<br /> {<br /> try<br /> {<br /> $objUser = [ADSI]“WinNT://localhost/$($LocalAdmin), user”<br /> $objUser.psbase.Invoke(“SetPassword”, $Password)<br /><br /> $Properties = @{<br /> TargettedServerName = $TargettedServerName<br /> Username = $LocalAdmin<br /> Password = $Password<br /> RealServerName = $env:computername<br /> }<br /><br /> $ReturnData = New-Object PSObject -Property $Properties<br /> Write-Output $ReturnData<br /> }<br /> catch<br /> {<br /> Write-Error “Error changing password for user:$($LocalAdmin) on server:$($TargettedServerName)”<br /> }<br /> }<br /><br /> $PasswordIndex++<br /> }<br /> }<br /><br /><br /> #Generate the password on the client running this script, not on the remote machine. System.Web.Security isn’t available in the .NET Client profile. Making this call<br /> # on the client running the script ensures only 1 computer needs the full .NET runtime installed (as opposed to every system having the password rolled).<br /> function Create-RandomPassword<br /> {<br /> Param(<br /> [Parameter(Mandatory=$true)]<br /> [ValidateRange(20,120)]<br /> [Int]<br /> $PasswordLength<br /> )<br /><br /> $Password = [System.Web.Security.Membership]::GeneratePassword($PasswordLength, $PasswordLength / 4)<br /><br /> #This should never fail, but I’m putting a sanity check here anyways<br /> if ($Password.Length -ne $PasswordLength)<br /> {<br /> throw new Exception(“Password returned by GeneratePassword is not the same length as required. Required length: $($PasswordLength). Generated length: $($Password.Length)”)<br /> }<br /><br /> return $Password<br /> }<br /><br /><br /> #Main functionality - Generate a password and remote in to machines to change the password of local accounts specified<br /> if ($PsCmdlet.ParameterSetName -ieq “Encryption”)<br /> {<br /> try<br /> {<br /> $Sha256 = new-object System.Security.Cryptography.SHA256CryptoServiceProvider<br /> $SecureStringKey = $Sha256.ComputeHash([System.Text.UnicodeEncoding]::Unicode.GetBytes($EncryptionKey))<br /> }<br /> catch<br /> {<br /> Write-Error “Error creating TSV encryption key” -ErrorAction Stop<br /> }<br /> }<br /><br /> foreach ($Computer in $ComputerName)<br /> {<br /> #Need to generate 1 password for each account that could be changed<br /> $Passwords = @()<br /> for ($i = 0; $i -lt $LocalAccounts.Length; $i++)<br /> {<br /> $Passwords += Create-RandomPassword -PasswordLength $PasswordLength<br /> }<br /><br /> Write-Output “Connecting to server ‘$($Computer)’ to roll specified local admin passwords”<br /> $Result = Invoke-Command -ScriptBlock $RemoteRollScript -ArgumentList @($Passwords, $LocalAccounts, $Computer) -ComputerName $Computer<br /> #If encryption is being used, encrypt the password with the user supplied key prior to writing to disk<br /> if ($Result -ne $null)<br /> {<br /> if ($PsCmdlet.ParameterSetName -ieq “NoEncryption”)<br /> {<br /> $Result | Select-Object Username,Password,TargettedServerName,RealServerName | Export-Csv -Append -Path $TsvFileName -NoTypeInformation<br /> }<br /> else<br /> {<br /> #Filters out $null entries returned<br /> $Result = $Result | Select-Object Username,Password,TargettedServerName,RealServerName<br /><br /> foreach ($Record in $Result)<br /> {<br /> $PasswordSecureString = ConvertTo-SecureString -AsPlainText -Force -String ($Record.Password)<br /> $Record | Add-Member -MemberType NoteProperty -Name EncryptedPassword -Value (ConvertFrom-SecureString -Key $SecureStringKey -SecureString $PasswordSecureString)<br /> $Record.PSObject.Properties.Remove(“Password”)<br /> $Record | Select-Object Username,EncryptedPassword,TargettedServerName,RealServerName | Export-Csv -Append -Path $TsvFileName -NoTypeInformation<br /> }<br /> }<br /> }<br /> }<br />}<br /><br /><br />function ConvertTo-CleartextPassword<br />{<br /><#<br />.SYNOPSIS<br />This function can be used to decrypt passwords that were stored encrypted by the function Invoke-PasswordRoll.<br /><br />Function: ConvertTo-CleartextPassword<br />Author: Microsoft<br />Version: 1.0<br /><br />.DESCRIPTION<br />This function can be used to decrypt passwords that were stored encrypted by the function Invoke-PasswordRoll.<br /><br /><br />.PARAMETER EncryptedPassword<br /><br />The encrypted password that was stored in a TSV file.<br /><br />.PARAMETER EncryptionKey<br /><br />The password used to do the encryption.<br /><br /><br />.EXAMPLE<br /><br />. .\Invoke-PasswordRoll.ps1 #Loads the functions in this script file<br />ConvertTo-CleartextPassword -EncryptionKey “Password1” -EncryptedPassword 76492d1116743f0423413b16050a5345MgB8AGcAZgBaAHUAaQBwADAAQgB2AGgAcABNADMASwBaAFoAQQBzADEAeABjAEEAPQA9AHwAZgBiAGYAMAA1ADYANgA2ADEANwBkADQAZgAwADMANABjAGUAZQAxAGIAMABiADkANgBiADkAMAA4ADcANwBhADMAYQA3AGYAOABkADcAMQA5ADQAMwBmAGYANQBhADEAYQBjADcANABkADIANgBhADUANwBlADgAMAAyADQANgA1ADIAOQA0AGMAZQA0ADEAMwAzADcANQAyADUANAAzADYAMAA1AGEANgAzADEAMQA5ADAAYwBmADQAZAA2AGQA”<br /><br />Decrypts the encrypted password which was stored in the TSV file.<br /><br />#><br /> Param(<br /> [Parameter(Mandatory=$true)]<br /> [String]<br /> $EncryptedPassword,<br /><br /> [Parameter(Mandatory=$true)]<br /> [String]<br /> $EncryptionKey<br /> )<br /><br /> $Sha256 = new-object System.Security.Cryptography.SHA256CryptoServiceProvider<br /> $SecureStringKey = $Sha256.ComputeHash([System.Text.UnicodeEncoding]::Unicode.GetBytes($EncryptionKey))<br /><br /> [SecureString]$SecureStringPassword = ConvertTo-SecureString -String $EncryptedPassword -Key $SecureStringKey<br /> Write-Output ([System.Runtime.InteropServices.Marshal]::PtrToStringAuto([System.Runtime.InteropServices.Marshal]::SecureStringToCoTaskMemUnicode($SecureStringPassword)))<br />}<br /> </pre>  Administrators can add local administrator accounts to computers by creating an Active Directory group and adding it to the local Administrators group through Group Policy Preferences -> Local Group. This action does not cache credentials. The dialog box resembles the following. This workaround does require a connection to Active Directory Domain Services when the user is logged on by using these credentials.<br /><br /><br /><img alt=“Local Group - workaround” src=“/Library/Images/2967514.png” title=“Local Group - workaround” /><br /><br /><br /><h3>Scenario 2: Mapped drives </h3>Administrators use drive maps to allocate network locations to users. The password protection feature is used to make sure of authorized access to the drive. The following preferences are affected: <ul><li>User Configuration -> Windows Settings -> Drive Maps -> New -> Mapped Drive</li></ul><h4>Important changes </h4><span>Action: Create, Update, or Replace </span><ul><li>The <strong>User name</strong>, <strong>Password</strong>, and <strong>Confirm password</strong> fields are disabled.</li></ul><br /><img alt=“Mapped Drive - Create/Update/Replace” src=“/Library/Images/2967515.png” title=“Mapped Drive - Create/Update/Replace” /><br /><br /><span>Action: Delete </span><ul><li>No change in behavior</li></ul><h4>Workarounds<br /></h4>Instead of using the password method for authentication, you can use Windows Explorer to manage share permissions and allocate rights to users. You can use Active Directory objects to control permissions to the folder. <br /><br /><br /><h3>Scenario 3: Services </h3>You can use the Services preference to change service properties in such a way that they run in a context other than their original security context. The following preferences are affected: <ul><li>Computer Configuration -> Control Panel Settings -> Services -> New -> Service </li></ul><h4>Important changes </h4><span>Startup: No Change, Automatic, or Manual </span><ul><li>The <strong>Password</strong> and <strong>Confirm password</strong> fields are disabled.</li><li>The administrator can use only built-in accounts.</li></ul><br /><img alt=“Service - Unchanged/Automatic/Manual” src=“/Library/Images/2967516.png” title=“Service - Unchanged/Automatic/Manual” /><br /><br /><span>Startup: Disable </span><ul><li>No change in behavior</li></ul><span>New dialog box</span><ul><li>Administrators who try to use non-built-in users for This account" receive the following warning:</li></ul><br /><img alt=“Warning against non-builtin users” src=“/Library/Images/2967517.png” title=“Warning against non-builtin users” /><br /><br /><br /><h4>Workarounds<br /><br /><br /></h4>Services can still run as a local system account. Service permissions can be altered as documented in the following article in the Microsoft Knowledge Base: <div><a href=“https://support.microsoft.com/en-us/help/256345”>256345 </a> How to Configure Group Policy settings to set security for system services <br /></div><span><br />Note</span> If the service that you want to configure is not present, you must configure the settings on a computer that has the service running. <br /><br /><br /><h3>Scenario 4: Scheduled and immediate tasks (up-level) </h3>These are used to run scheduled tasks in a specific security context. The ability to store credentials for scheduled tasks to run as an arbitrary user when that user is not logged on is no longer available. The following preferences are affected. (Be aware that on some platforms, “At least Windows 7” is replaced with “Windows Vista and later.”) <ul><li> Computer Configuration -> Control Panel Settings -> Scheduled Tasks -> New -> Scheduled Task (At least Windows 7)</li><li> Computer Configuration -> Control Panel Settings -> Scheduled Tasks -> New -> Immediate Task (At least Windows 7)</li><li> User Configuration -> Control Panel Settings -> Scheduled Tasks -> New -> Scheduled Task (At least Windows 7)</li><li> User Configuration -> Control Panel Settings -> Scheduled Tasks -> New -> Immediate Task (At least Windows 7)</li></ul><h4>Important changes </h4><span>Action: Create, Update, or Replace </span><ul><li>When you select the <strong>Run whether user is logged on or not</strong> option, a dialog box no longer prompts the administrator for credentials.</li><li>The <strong>Do not store password</strong> check box is disabled. By default, the box is also checked.</li></ul><br /><img alt=“New Scheduled or Immediate Task (Up-level)” src=“/Library/Images/2967518.png” title=“New Scheduled or Immediate Task (Up-level)” /><br /><br /><span>Action: Delete </span><br /><br />No change in behavior<br /><br /><h4>Workarounds<br /></h4>For the “Scheduled Task (at least Windows 7)” and “Immediate Task (at least Windows 7)” tasks, administrators can use specific user accounts when the given user is logged on. Or, they can only have access to local resources as that user. These tasks still can run in the context of the local service. <h3><br /><br />Scenario 5: Scheduled and immediate tasks (down-level) </h3>This is the down-level version of preferences used to run Scheduled Tasks in a specific security context. The ability to store credentials for scheduled tasks to run as an arbitrary user when that user is not logged on is no longer available. The following preferences are affected: <ul><li> Computer Configuration -> Control Panel Settings -> Scheduled Tasks -> New -> Scheduled Task</li><li> Computer Configuration -> Control Panel Settings -> Scheduled Tasks -> New -> Immediate Task (Windows XP)</li><li> User Configuration -> Control Panel Settings -> Scheduled Tasks -> New -> Scheduled Task</li><li> User Configuration -> Control Panel Settings -> Scheduled Tasks -> New -> Immediate Task (Windows XP)</li></ul><h4>Important changes </h4><span>Action: Create, Update, or Replace </span><ul><li>The <strong>Run as</strong> check box is disabled. Therefore, the <strong>User Name</strong>, <strong>Password</strong>, and <strong>Confirm Password</strong> fields are all disabled.</li></ul><br /><img alt=“New Task - Create/Update/Replace (down-level)” src=“/Library/Images/2967519.png” title=“New Task - Create/Update/Replace (down-level)” /><br /><br /><span>Action: Delete </span><br /><br /> No change in behavior<br /><br /><h4>Workarounds<br /></h4>For the “Scheduled Task” and “Immediate Task (Windows XP)” items, scheduled tasks run by using the permissions that are currently available to the local service. <br /><br /><br /><h3>Scenario 6: Data Sources </h3>The Data Sources preference is used to associate a data source with a computer or user. This feature no longer stores credentials to enable access to data sources that are protected by a password. The following preferences are affected: <ul><li>Computer Configuration -> Control Panel Settings -> Data Sources</li><li>User Configuration -> Control Panel Settings -> Data Sources</li></ul><h4>Important Changes<br /></h4><span>Action: Create, Update, or Replace </span><ul><li>The <strong>User Name</strong>, <strong>Password</strong>, and <strong>Confirm Password</strong> fields are disabled:</li></ul><span><br /><img alt=“Data Sources - Create/Update/Replace” src=“/Library/Images/2967520.png” title=“Data Sources - Create/Update/Replace” /><br /><br />Action: Delete </span><ul><li>No change in behavior</li></ul><h4>Workarounds<br /></h4>No workarounds are available. This preference no longer stores credentials to allow access to data sources that are protected by a password. <br /><br /><br /></div><h2>Deprecation of CPassword</h2><div><h3>Removing CPassword </h3>The Windows PowerShell script that is included in this Microsoft Knowledge Base article detects whether a domain contains any Group Policy Preferences that might use CPassword. If CPassword XML is detected in a given preference, it is displayed in this list. <br /><br /><br /><h4>Detecting CPassword preferences <br /></h4>This script must be run from a local directory on the domain controller that you want to clean. Copy and save the contents to a new Windows PowerShell file, determine your system drive, and then run the script as indicated in the following usage.<br /><br /><pre> <#<br />.SYNOPSIS<br />Group Policy objects in your domain can have preferences that store passwords for different tasks, such as the following:<br /> 1. Data Sources<br /> 2. Drive Maps<br /> 3. Local Users<br /> 4. Scheduled Tasks (both XP and up-level)<br /> 5. Services<br />These passwords are stored in SYSVOL as part of GP preferences and are not secure because of weak encryption (32-byte AES). <br />Therefore, we recommend that you not deploy such preferences in your domain environment and remove any such existing <br />preferences. This script is to help administrator find GP Preferences in their domain’s SYSVOL that contains passwords.<br /> <br />.DESCRIPTION<br />This script should be run on a DC or a client computer that is installed with RSAT to print all the preferences that contain <br />password with information such as GPO, Preference Name, GPEdit path under which this preference is defined.<br />After you have a list of affected preferences, these preferences can be removed by using the editor in the Group Policy Management Console.<br /> <br />.SYNTAX<br />Get-SettingsWithCPassword.ps1 [-Path <String>] <br />.EXAMPLE<br />Get-SettingsWithCPassword.ps1 -Path %WinDir%\SYSVOL\domain<br />Get-SettingsWithCPassword.ps1 -Path <GPO Backup Folder Path><br /> <br />.NOTES<br />If Group Policy PS module is not found the output will contain GPO GUIDs instead of GPO names. You can either run <br />this script on a domain controller or rerun the script on the client after you have installed RSAT and <br />enabled the Group Policy module.<br />Or, you can use GPO GUIDs to obtain GPO names by using the Get-GPO cmdlet.<br /> <br />.LINK<br />http://go.microsoft.com/fwlink/?LinkID=390507<br /> <br />#><br />#----------------------------------------------------------------------------------------------------------------<br /># Input parameters<br />#--------------------------------------------------------------------------------------------------------------<br />param(<br /> [string]$Path = $(throw “-Path is required.”) # Directory path where GPPs are located.<br /> )<br />#---------------------------------------------------------------------------------------------------------------<br />$isGPModuleAvailable = $false<br />$impactedPrefs = { “Groups.xml”, “ScheduledTasks.xml”,“Services.xml”, “DataSources.xml”, “Drives.xml” }<br />#----------------------------------------------------------------------------------------------------------------<br /># import Group olicy module if available<br />#----------------------------------------------------------------------------------------------------------------<br />if (-not (Get-Module -name “GroupPolicy”))<br />{<br /> if (Get-Module -ListAvailable | <br /> Where-Object { $.Name -ieq “GroupPolicy” })<br /> {<br /> $isGPModuleAvailable = $true<br /> Import-Module “GroupPolicy”<br /> }<br /> else<br /> {<br /> Write-Warning “Unable to import Group Policy module for PowerShell. Therefore, GPO guids will be reported. <br /> Run this script on DC to obtain the GPO names, or use the Get-GPO cmdlet (on DC) to obtain the GPO name from GPO guid.”<br /> }<br />}<br />else<br />{<br /> $isGPModuleAvailable = $true<br />}<br />Function Enum-SettingsWithCpassword ( [string]$sysvolLocation )<br />{<br /> # GPMC tree paths<br /> $commonPath = " -> Preferences -> Control Panel Settings -> "<br /> $driveMapPath = " -> Preferences -> Windows Settings -> "<br /> <br /> # Recursively obtain all the xml files within the SYVOL location<br /> $impactedXmls = Get-ChildItem $sysvolLocation -Recurse -Filter “*.xml” | Where-Object { $impactedPrefs -cmatch $.Name }<br /> <br /> <br /> # Each xml file contains multiple preferences. Iterate through each preference to check whether it<br /> # contains cpassword attribute and display it.<br /> foreach ( $file in $impactedXmls )<br /> {<br /> $fileFullPath = $file.FullName<br /> <br /> # Set GPP category. If file is located under Machine folder in SYSVOL<br /> # the setting is defined under computer configuration otherwise the <br /> # setting is a to user configuration <br /> if ( $fileFullPath.Contains(“Machine”) )<br /> {<br /> $category = “Computer Configuration”<br /> }<br /> elseif ( $fileFullPath.Contains(“User”) )<br /> {<br /> $category = “User Configuration”<br /> }<br /> else<br /> {<br /> $category = “Unknown”<br /> }<br /> # Obtain file content as XML<br /> try<br /> {<br /> [xml]$xmlFile = get-content $fileFullPath -ErrorAction Continue<br /> }<br /> catch [Exception]{<br /> Write-Host $.Exception.Message<br /> }<br /> if ($xmlFile -eq $null)<br /> {<br /> continue<br /> }<br /> switch ( $file.BaseName )<br /> {<br /> Groups <br /> { <br /> $gppWithCpassword = $xmlFile.SelectNodes(“Groups/User”) | where-Object { [String]::IsNullOrEmpty($.Properties.cpassword) -eq $false }<br /> $preferenceType = “Local Users”<br /> }<br /> ScheduledTasks<br /> {<br /> $gppWithCpassword = $xmlFile.SelectNodes(“ScheduledTasks/*”) | where-Object { [String]::IsNullOrEmpty($.Properties.cpassword) -eq $false }<br /> $preferenceType = “Scheduled Tasks”<br /> }<br /> DataSources<br /> {<br /> $gppWithCpassword = $xmlFile.SelectNodes(“DataSources/DataSource”) | where-Object { [String]::IsNullOrEmpty($.Properties.cpassword) -eq $false }<br /> $preferenceType = “Data sources”<br /> }<br /> Drives<br /> {<br /> $gppWithCpassword = $xmlFile.SelectNodes(“Drives/Drive”) | where-Object { [String]::IsNullOrEmpty($.Properties.cpassword) -eq $false }<br /> $preferenceType = “Drive Maps”<br /> }<br /> Services<br /> {<br /> $gppWithCpassword = $xmlFile.SelectNodes(“NTServices/NTService”) | where-Object { [String]::IsNullOrEmpty($.Properties.cpassword) -eq $false }<br /> $preferenceType = “Services”<br /> }<br /> default<br /> { # clear gppWithCpassword and preferenceType for next item.<br /> try<br /> {<br /> Clear-Variable -Name gppWithCpassword -ErrorAction SilentlyContinue<br /> Clear-Variable -Name preferenceType -ErrorAction SilentlyContinue<br /> }<br /> catch [Exception]{}<br /> }<br /> }<br /> if ($gppWithCpassword -ne $null)<br /> {<br /> # Build GPO name from GUID extracted from filePath <br /> $guidRegex = [regex]”{(.*)}“<br /> $match = $guidRegex.match($fileFullPath)<br /> if ($match.Success)<br /> {<br /> $gpoGuid = $match.groups[1].value<br /> $gpoName = $gpoGuid<br /> }<br /> else<br /> {<br /> $gpoName = “Unknown”<br /> }<br /> if($isGPModuleAvailable -eq $true)<br /> {<br /> try <br /> { <br /> $gpoInfo = Get-GPO -Guid $gpoGuid -ErrorAction Continue<br /> $gpoName = $gpoInfo.DisplayName<br /> }<br /> catch [Exception] {<br /> Write-Host $_.Exception.Message<br /> }<br /> }<br /> # display prefrences that contain cpassword<br /> foreach ( $gpp in $gppWithCpassword )<br /> {<br /> if ( $preferenceType -eq “Drive Maps” )<br /> {<br /> $prefLocation = $category + $driveMapPath + $preferenceType<br /> }<br /> else<br /> {<br /> $prefLocation = $category + $commonPath + $preferenceType<br /> }<br /> $obj = New-Object -typeName PSObject <br /> $obj | Add-Member –membertype NoteProperty –name GPOName –value ($gpoName) –passthru |<br /> Add-Member -MemberType NoteProperty -name Preference -value ($gpp.Name) -passthru |<br /> Add-Member -MemberType NoteProperty -name Path -value ($prefLocation)<br /> Write-Output $obj <br /> }<br /> } # end if $gppWithCpassword<br /> } # end foreach $file<br />} # end functions Enum-PoliciesWithCpassword<br />#-----------------------------------------------------------------------------------<br /># Check whether Path is valid. Enumerate all settings that contain cpassword. <br />#-----------------------------------------------------------------------------------<br />if (Test-Path $Path )<br />{<br /> Enum-SettingsWithCpassword $Path<br />}<br />else<br />{<br /> Write-Warning “No such directory: $Path”<br />} <br /> </pre><br /><br /><span>Example usage (assumes that the system drive is C) </span><br /><br /><pre>.\Get-SettingsWithCPassword.ps1 –path “C:\Windows\SYSVOL\domain” | Format-List </pre><br /><span>Note</span> Be aware that you can also target any backup GPO for the <strong>path</strong> instead of the domain<span>.</span><br /><br />The detection script generates a list that resembles the following:<br /><br /><img alt=“insert graphic” src=”/Library/Images/2967134.png" title=“insert graphic” /><br /><br />For longer lists, consider saving the output to a file: <br /><br /><pre>.\Get-SettingsWithCPassword.ps1 –path “C:\Windows\SYSVOL\domain” | ConvertTo-Html > gpps.html </pre><h4>Removing CPassword preferences </h4>In order to remove the preferences that contain CPassword data, we suggest that you use Group Policy Management Console (GPMC) on the domain controller or from a client that has Remote Server Administration Tools installed. You can remove any preference in five steps on these consoles. To do this, follow these steps: <ol><li>In GPMC, open the preference that contains CPassword data. </li><li>Change the action to <strong>Delete</strong> or <strong>Disable</strong>, as applicable to the preference.</li><li>Click <strong>OK</strong> to save your changes. </li><li>Wait for one or two Group Policy refresh cycles to allow changes to propagate to clients.</li><li>After changes are applied on all clients, delete the preference.</li><li>Repeat steps 1 through 5 as needed to clean your whole environment. When the detection script returns zero results, you are finished.</li></ol><div><div><div><span><span></span></span><span><span>File hash information<br /></span></span></div><div><span><div><div><table><tr><th>File name</th><th>SHA1 hash</th><th>SHA256 hash</th></tr><tr><td>Windows6.0-KB2928120-ia64.msu</td><td>B2A74305CB56191774BFCF9FCDEAA983B26DC9A6</td><td>DCE8C0F9CEB97DBF1F7B9BAF76458B3770EF01C0EDC581621BC8C3B2C7FD14E7</td></tr><tr><td>Windows6.0-KB2928120-x64.msu</td><td>386457497682A2FB80BC93346D85A9C1BC38FBF7</td><td>1AF67EB12614F37F4AC327E7B5767AFA085FE676F6E81F0CED95D20393A1D38D</td></tr><tr><td>Windows6.0-KB2928120-x86.msu</td><td>42FF283781CEC9CE34EBF459CA1EFE011D5132C3</td><td>016D7E9DBBC5E487E397BE0147B590CFBBB5E83795B997894870EC10171E16D4</td></tr><tr><td>Windows6.1-KB2928120-ia64.msu</td><td>5C2196832EC94B99AAF9B074D3938525B7219690</td><td>9958FA58134F55487521243AD9740BEE0AC210AC290D45C8322E424B3E5EBF16</td></tr><tr><td>Windows6.1-KB2928120-x64.msu</td><td>EA5332F4E289DC799611EAB8E3EE2E86B7880A4B</td><td>417A2BA34F8FD367556812197E2395ED40D8B394F9224CDCBE8AB3939795EC2A</td></tr><tr><td>Windows6.1-KB2928120-x86.msu</td><td>7B7B6EE24CD8BE1AB3479F9E1CF9C98982C8BAB1</td><td>603206D44815EF2DC262016ED13D6569BE13D06E2C6029FB22621027788B8095</td></tr><tr><td>Windows8-RT-KB2928120-x64.msu</td><td>E18FC05B4CCA0E195E62FF0AE534BA39511A8593</td><td>FCAED97BF1D61F60802D397350380FADED71AED64435D3E9EAA4C0468D80141E</td></tr><tr><td>Windows8-RT-KB2928120-x86.msu</td><td>A5DFB34F3B9EAD9FA78C67DFC7ACACFA2FBEAC0B</td><td>7F00A72D8A15EB2CA70F7146A8014E39A71CFF5E39596F379ACD883239DABD41</td></tr><tr><td>Windows8.1-KB2928120-x64.msu</td><td>A07FF14EED24F3241D508C50E869540915134BB4</td><td>6641B1A9C95A7E4F0D5A247B9F488887AC94550B7F1D7B1198D5BCBA92F7A753</td></tr><tr><td>Windows8.1-KB2928120-x86.msu</td><td>DE84667EC79CBA2006892452660EB99580D27306</td><td>468EE4FA3A22DDE61D85FD3A9D0583F504105DF2F8256539051BC0B1EB713E9C</td></tr><tr><td>Windows8.1-KB2961899-x64.msu</td><td>10BAE807DB158978BCD5D8A7862BC6B3EF20038B</td><td>EC26618E23D9278FC1F02CA1F13BB289E1C6C4E0C8DA5D22E1D9CDA0DA8AFF51</td></tr><tr><td>Windows8.1-KB2961899-x86.msu</td><td>230C64447CC6E4AB3AD7B4D4655B8D8CEFBFBE98</td><td>E3FAD567AB6CA616E42873D3623A777185BE061232B952938A8846A974FFA7AF</td></tr></table></div></div><br /></span></div></div></div></div></body></html>

9 High

CVSS2

Access Vector

NETWORK

Access Complexity

LOW

Authentication

SINGLE

Confidentiality Impact

COMPLETE

Integrity Impact

COMPLETE

Availability Impact

COMPLETE

AV:N/AC:L/Au:S/C:C/I:C/A:C