Enable-AclInheritance

Enables ACL inheritance on an item.

Syntax

Enable-AclInheritance [-Path] <String> [-Preserve] [-WhatIf] [-Confirm] [<CommonParameters>]

Description

Items in the registry or file system will usually inherit ACLs from its parent. This inheritance can be disabled, either via Carbon's Protect-Acl function or using .NET's securei API. The Enable-AclInheritance function re-enables inheritance on containers where it has been disabled. By default, any explicit permissions on the item are removed. Use the -Preserve switch to keep any existing, explicit permissions on the item.

This function is paired with Disable-AclInheritance.

This function was added in Carbon 2.4.

Related Commands

Parameters

Name Type Description Required? Pipeline Input Default Value
Path String

The file system or registry path who should start inheriting ACLs from its parent.

true true (ByValue, ByPropertyName)
Preserve SwitchParameter

Keep the explicit access rules defined on the item.

false false False
WhatIf SwitchParameter false false
Confirm SwitchParameter false false
CommonParameters This cmdlet supports common parameters. For more information type
Get-Help about_CommonParameters.

EXAMPLE 1

Enable-AclInheritance -Path C:\Projects\Carbon

Re-enables ACL inheritance on C:\Projects\Carbon. ACLs on C:\Projects will be inherited to and affect C:\Projects\Carbon. Any explicit ACLs on C:\Projects\Carbon are removed.

EXAMPLE 2

Enable-AclInheritance -Path hklm:\Software\Carbon -Preserve

Re-enables ACL inheritance on hklm:\Software\Carbon. ACLs on hklm:\Software will be inherited to and affect hklm:\Software\Carbon. Any explicit ACLs on C:\Projects\Carbon are kept.