Category Archives: HowTo

How To Compare the Permissions of Two AD Objects

This feature is available in NetTools v1.30.11 beta and above

The permissions for a object in AD are stored in the ntSecurityDescriptor attribute, these permissions are used to control who can access the object.  When troubleshooting access issues, it is sometimes useful to be able to compare the permissions that are assigned to two different objects.  With v1.30.11 above there is now simple method to compare the permissions between two different objects.

The context menu in NetTools now provides two additional menu items to allow permissions of objects to be compared:

  • Select left SD to compare
  • Compare to 'left object' SD
Compare Menu Items

To compare the permissions or security descriptors (SD), select the first object and select the Select left SD to compare option, this will set the object as the left items.  Then find the second object you want to compare against, and then select the Compare to 'left name' SD option and the compare Permissions dialog box will be displayed.

Compare Permissions

Compare two user objects

The easiest method to compare two user objects is use the quick search option to find the first user, enter the user name in the quick search box and press enter, in this case we are searching for greynolds.

Quick Search

From the Search results, right click on the greynolds object and select the Select left SD to compare

Compare Left

If we search for the second user object, and then right click on the second user and select the Compare to 'Gary Reynolds' SD menu item and the Compare Permissions dialog will be displayed.

Compare SD Item

The comparison between the two objects will be displayed.

Compare Permissions Result

Click on the column header with a '*' to select options to filter the displayed ACEs.

Compare Permissions Options

Compare Other Objects

To compare objects other than users, use one of NetTools options to find the object you are looking for, i.e. LDAP Browser, LDAP Search, ACL Browser, GPO Explorer, etc.  all these options have the same context menus to allow to you to compare permissions against any other object.

See Comparing AD Permissions for more information

How To Import an AD Permissions Report Filter

The AD Permissions Reporter option provides the ability to export and import filters, this post provide details on how to import a filter.

This is a sample of a filter text

[Find Deny Permissions Assigned to a user]
Count=1
Options=18437
Rule1_Enabled=1
Rule1_Options=1280
Rule1_SDControl=0
Rule1_SDNotControl=0
Rule1_SDNullAcl=0
Rule1_Prompt=1
Rule1_Token=1
Rule1_Scope=12
Rule1_NotScope=0
Rule1_ACEType=2626
Rule1_ACEFlags=0
Rule1_ACENotFlags=0
Rule1_Perms=0
Rule1_NotPerms=0
Rule1_MatchRules=546

Here are the steps required to import the filter.

  1. Click on the Select button
  2. Click on the Import button
  3. Paste the filter into the dialog
  4. Click Add button
AD Permissions Reporter - Import Filter

Once the filter is imported the list will be updated, now select the new filter from the list.

AD Permission Reporter - Select Filter

How To Test GPOs as GPOTool.exe is no longer available

This feature is available in NetTools v1.30.10 beta and above

Previously included in the Windows 2003 Resource Kit there was simple tool called GPOTool.exe, which checked the status of the GPOs in a domain, this would check the consistency of the details between the AD and Sysvol and highlight a number of common problems.  As Windows 2003 Resource kit is no longer available for download from Microsoft, and this functionality hasn't been incorporated into any of the existing tools, there is no easy way to confirm the status of the GPOs in a domain.

Under the GPO Explorer in NetTools there is a test option that performs a similar suite of tests that were performed by GPOTool.exe.  There are two methods to test the status of the GPOs, either at the individually GPO level or at the domain level to test all GPOs.

The test covers the following items:

  • AD Replication
  • Sysvol Replication
  • Mismatching of AD and Sysvol versions
  • Compare object counts for both AD and Sysvol
  • Sysvol gpt.ini exists
  • Trustees that have apply GPO rights have permissions in Sysvol

Test an Individual GPO

When selecting a GPO in the GPO Explorer an tab called Testing is shown with the details of the policy, which allows you to test the selected GPO.  By default, the test will be run against all Domain Controllers in the domain, however, you are able to select which domain controllers will be be included in the test.  This allows you to deselect domain controllers that might be at the end of a slow link or are offline temporarily.   The server selection is on the test all GPO screen, see below.

GPO Testing Results - Individual

Test All or multiple GPOs at once

This option is found by select the root of the domain in the left hand pane, the Testing tab displays the domain controllers and GPOs in the domain.  The lists can be used to select which servers and GPOs will be included in the test .  The test provides to those who have used GPOTool.exe before, with a touch nostalgia, as the output is pretty must the same as GPOTool.exe.

GPO Testing Results

If an issue is found with the policies, the details of the policies on all domain controllers is displayed, or if Display Policy Details options is selected.

Failed Results

How To Display the RootDSE of an AD Domain Controller

In this post we will look at how to display the RootDSE of a domain controller using NetTools.

RootDSE is the root of the directory tree on a directory server. The rootDSE provides information about the directory server, and the details of the features and options that the server supports.

With NetTools it is a simple task to display the RootDSE, In NetTools if you navigate to the LDAP Search option.

To retrieve the RootDSE entry the name of the domain controller in the server field, ensure that the Base DN field is blank and then click on the Show Attributes for DN button.

Display RootDSE

This RootDSE will be displayed as shown below.

Attributes - RootDSE

How To Find Assigned Permissions in AD (v1.30.8+)

In this post we will look at how to find where a user or group have been assigned permissions in the AD, this is based on NetTools v1.30.8 or later.  For details using NetTools v1.30.7 or earlier see this post.

For this task we will use the Find Assigned Trustee option in NetTools, which will allow us to search the entire domain or a specific OU structure and report on any permissions that are assigned to the specified user or group.  As this will search every object in the AD, it's best to run this on a server or workstation that is on the same network segment as the Domain Controller, or on the Domain Controller itself.

First we need to find the user or group we are interested in, in the Quick Search box enter the name of the user or group and click the search button.  In this case we are searching for the user called greynolds.

Quick Search

The results of the search will be displayed in the User Search option, right click on the correct user or group from the list, and select Use With -> AD Permissions Reporter from the context menu.

Find Permissions

NetTools will switch to the Find Trustee Assignment option and start searching for selected user or group in AD.  Depending on the size of your AD this might take a while as it will read the permissions of every object in the domain context.  Once the search is complete all the objects that user or group have been assigned direct permissions will be displayed.

Find User's Permissions

By clicking on one of the objects listed in the left results pane you can view the permissions that have been assigned to the user or group.

It's also worth completing a search of the Configuration partition in case permissions have been assigned there as well.  This can be done by changing the Context field to Configuration NC and pressing Go.

How To Restore deleted AD objects

This feature is supported in NetTools v1.30.9 beta and above

With the introduction of Windows 2008 R2, a new feature called Active Directory Recycle Bin was introduced.  This feature allow you to restore objects that have been deleted by mistake or maliciously, without the need to do a restoration from backup and the AD authoritative restore.  For new forest installs of Windows 2008R2 and above, this feature is enabled by default, for forests were the domain controller have been upgrade, the feature has to be manually enabled.  To enable the Active Directory Recycle Bin see this page which has the details.

The only method that was originally provided to recovery delete object was through LDP, which requires multiple steps and configuration changes to be able to restore an object.

NetTools provides a simple method to restore single or multiple objects in a single operation.  This feature is incorporated in the LDAP Browser option.

To be able to restore a delete object you must meet the following prerequisites:

  • The recycle bin feature must be enabled
  • The recycle bin feature must have been enabled before the objects were deleted
  • Be a member of Domain Admins or equivalent

When an object is deleted it's moved to the Deleted Objects container, in the partition that the object existed.  This also means that objects that have been deleted from the Configuration, DomainDNSZones, and ForestDNSZones can be restored using NetTools.  When browsing the partitions with LDAP Browser the deleted object will be displayed in CN=Deleted Objects,<partiton dn>.

Deleted Objects Container

Objects that are listed in the Deleted Objects container can be restored by select the objects and right clicking and selecting Restore Objects from the context menu.

Context Menu - Restore Objects

The context menu option will open the Object Restore dialog, shown below.  When the dialog opens it will perform a number of validation checks of the selected objects, to ensure that the common issues are detected before the restore is attempted.

The Validation consists of the following checks:

  • If the object has been tombstoned
  • If the target parent container still exists
  • if the target parent container is deleted
  • If a new object with the same name has been created in the target parent

The objects that pass the validation will show a status of Good, for objects that fail these checks, the reason will be displayed in the status column and can't be restored. See Troubleshooting section for details on how to try and resolve these issues.

Object Restore - Validation

Once the validation is complete the results are shown at the bottom of the list of objects, and then the Restore button will be enabled.  By clicking the restore button, only the objects that are valid will be restored.

Object Restore - Restored

The context menu provides the standard option to review the restored objects.

Restoring A Deleted OU

If an OU has been deleted which contains multiple objects and child OUs, these can also be restored, however, the OU structure must be restored first, then followed by the object in the OU.  The simplest method to find objects that have been deleted from the same the OU, is to change the column displayed to include the LastKnownParent and WhenChanged

Change Columns

For this example, here are the details of the OU Structure that has been deleted.  Sorry about the names, it was an OU that was already created!

Deleted OU Structure

These are the steps needed to restore the OU structure

  • Restore the Parent OU
  • Restore any sub level OUs
  • Restore the child objects

Restore Parent OU

First you will need to restore the top level OU called Test5, sort the columns by the LastKnownParent column to make it easier to find the parent OU for Test5, in this case the root.

Object Restore - Parent OU

Restore the sub level OU

With the Parent OU restored it's now easier to find which objects were in the OU structure, as the LastKnownParent has now been updated, next restore any sub level OUs, in our example sub-OU has been restored.

Object Restore - sub level OU

Restore child Objects

Once the OU structure has been restored, we are ready to restore the objects from the OU structure, one things that we need to be conscious of, some objects may have been deleted previously and we don't want to restore these objects, using the WhenChanged column to help identify the objects we want to restore.

Object Restore - OUs Restored

Troubleshooting

This section provide somes some extra details of the possible error messages that can happen during the validation.

Object has tombstoned

The object was been delete grater than msDS-deletedObjectLifetime period and now the object has been tombstoned. The object has the IsRecycled attribute set to true.  Which means most of the attributes of the object have been removed and the object only exists to ensure replication is consistent between the domain controllers and the object can't be restored.

Parent Object is deleted

You are trying to restore an object to a parent object, but the parent object is currently deleted, restore the parent object first, then try restoring the child object.

Parent Object not found

Something has changed from selecting the object and running the validation, close the Object Restore dialog and try again.

Parent details not found

Failed to read the LastKnownParent attribute, confirm the attribute is set and try again.

Another object already exists

Since the object was deleted, another object with the same name has been created in the parent OU, either move or rename the new object so you can restore the deleted object.

Failed to get DN details

Failed to read the LastKnownParent or msDS-LastKnownRDN attributes, confirm these attributes are set and try again.

How To Display which Fine Grain Password Policy is applied

In this post we look at how to display which Fine Grain Password Policy (FGPP) is being applied to a user.

Fine Grain Password Policies were introducted in Windows 2008, and provide the ability to define different password policies that can be assigned to users or members of a group.  The assigned FGPP will take precedence over the default domain policy, and can be used to provide a different settings depending on your requirements, this could be used to have a more strict password policy for admin accounts.

The FGPP configuration is stored in a Password Security Object or PSO and multiple PSO can be created with different settings.  These are stored in the Password Settings Container under the default name context i.e CN=Password Settings Container,CN=System,DC=w2k12,DC=local.

A user can be assigned multiple FGPP, but only one will be active and used to control the user password requirements.  The msDS-PSOApplied attribute is used to list all the PSO that are assigned directly to user or group objects.  The msDS-ResultantPSO attribute is used to show which FGPP is being applied to the user.

NetTools is able to display the FGPP polices and which FGPP is allocated to a user. (Version 1.30.7 and above required)

If we search for a user using the Quick Search field on the toolbar.

Quick Search

From the search results if we double click on the user's account and open the AD properties dialog, the Logon tab, shows which Fine Grain Policy is being applied and the Fine Grain Password tab shows the settings of that policy.

AD Properties - Logon
AD Properties - FGPP

How To Find Assigned Permissions in AD (pre v1.30.8)

In this post we will look at how to find where a user or group have been assigned permissions in the AD this is based on NetTools pre v1.30.8.  For details using NetTools v1.30.8 or later see this post.

For this task we will use the Find Assigned Trustee option in NetTools, which will allow us to search the entire domain or a specific OU structure and report on any permissions that are assigned to the specified user or group.  As this will search every object in the AD, it's best to run this on a server or workstation that is on the same network segment as the Domain Controller, or on the Domain Controller itself.

First we need to find the user or group we are interested in, in the Quick Search box enter the name of the user or group and click the search button.  In this case we are searching for the user called greynolds.

Quick Search

The results of the search will be displayed in the User Search option, right click on the correct user or group from the list, and select Use With -> Find Trustee from the context menu.

Select Find Trustee menu option

NetTools will switch to the Find Trustee Assignment option and start searching for selected user or group in AD.  Depending on the size of your AD this might take a while as it will read the permissions of every object in the domain context.  Once the search is complete all the objects that user or group have been assigned direct permissions will be displayed.

Find Trustee Assignments

By clicking on one of the objects listed in the left results pane you can view the permissions that have been assigned to the user or group.

It's also worth completing a search of the Configuration partition in case permissions have been assigned there as well.  This can be done by changing the Context field to Configuration NC and pressing Go.

How To Display the Meta Data of an AD object

In this post we look at how to use NetTools to display the replication meta data of an AD object.

Displaying the replication meta data of an AD object is a core capability, and it is available as a context menu item throughout NetTools.  See Basics and Meta Data Dialog for more details.

In this post we will look at the two most common scenario, searching and browsing for objects that you want to view the replication meta data.

Searching Method

The search option is best for common AD objects such as users, groups, computers, etc, that are in the default domain context, If you want to view the meta data information for an object that is in the schema, configuration, DNS, or AD LDS (ADAM) partitions, use the Browse Method below.

To search for an object we can use the quick search field on the toolbar at the top of NetTools.  In the field enter the name of the object you are want to find and click the search button.

In this case we are search for the computer object for w2k19.  The Search screen will be displayed with the results of the search.

Search Results

If you right click on the required item and select the Meta Data menu items, the Meta Data dialog will be displayed.

Meta Data Menu
Meta Data Dialog

For more details on the Search option see User Search

Browsing Method

The advantage of using the browse method, is it allows you to display the meta data for objects that are not in default domain context and wouldn't be found by the search method.  You can browser the required name context, configuration, schema and DNS, or AD LDS (ADAM) partitions.  To use the browse method you need to select the LDAP Browser option under LDAP in the left hand option selection pane.

LDAP Browser

Selecting the required partition from the drop down list in the DN field.

Select partition

You can select one of the root of the partition from the drop down list, or enter the required DN in the field, then click Go.  The view will be populated and you can browse the partition to find your object. You can right click the object in the navigate tree or the list view and select the Meta Data menu item to display the Meta Data of the selected object.

LDPA Browser - Meta Data Menu

This will show the replication Meta Data dialog.

Meta Data Dialog

For more details on the LDAP Browser option see LDAP Browser

How To Troubleshot which GPOs have been applied

Sometime is not immediately obvious where to start when troubleshooting GPO delivery issues.  NetTools provides a number of features that will let confirm the GPO configuration and then verify which GPOs have been applied to the computer and user by reading the results directly from the machine.

To start troubleshooting we need to find the computer in the Active Directory and confirm which GPO will be applied to the machines.  In the quick search box enter the name of the computer that you want to troubleshoot.

Quick Search

In this case we are searching for the W2k19 which is a domain controller, click on the search button.

Search Results

The search results will show all objects that match the search name.  Now if we right click on the required item and select Use With->GPO Allocation from the context menu.

GPO Allocation Menu

The view will change to the GPO Explorer and automatically navigate to the OU that contains the computer object.  It will also display which GPOs have been assigned to the OU.  In this view you can confirm which policies have the links enabled and any WMI filters that have been applied.

GPOs Applied

By clicking a policy the details of the policy are displayed in a split screen, so you can review the settings or configuration without leaving the OU view.  While here check the version numbers of policy on the general tab, if the version number is zero, the policy will not apply as the policy engine will think its empty.

General
Scope
Settings
Security

The Inherited Policies tab will show which policies have been inherited down the OU structure and the order in which the policies will be applied. This view also supports the split view capability.  Confirm that the policy you are troubleshooting is listed.

Now if we select the Content tab the list of object that are in the OU are displayed. If there is more than 2000 objects in the OU, you will need to adjust the max entries field to display more.

Find your machine in the list and click on the machines and select GPO Results from the context menu.

GPO Results

This will open a separate window and display what policies have been applied to the machine.  The icons indicate if the policy was successfully applied to the machine or not.  Policies that were successfully applied will have a green indicator, while policies that failed to be applied will have a red indicator.  If you expand the policy item in the list the details why the policy failed to apply will be displayed, items that red indicator that is the reason why the policy was not applied.

For the GPO Results to be displayed the machine must be on and connected to the network.

GPO Results

Once the GPO Result window is populated, using the Quick Search field on the main form, you can now search for the user and repeat the steps to see the GPO Allocation for the user object.  You can to expand the users policies tree in the GPO Results window to see which policies were applied to the user.

For more details on the information displayed in the GPO Results window see the GPO Viewer page