Skip to content

Commit 92aa5be

Browse files
authored
Update guidance about lockdown mode (#12696)
* Update guidance about lockdown mode * Feeback edits
1 parent aa54d0e commit 92aa5be

File tree

6 files changed

+74
-39
lines changed

6 files changed

+74
-39
lines changed

reference/7.4/Microsoft.PowerShell.Core/About/about_Language_Modes.md

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Explains language modes and their effect on PowerShell sessions.
33
Locale: en-US
4-
ms.date: 01/18/2026
4+
ms.date: 01/26/2026
55
no-loc: [FullLanguage, ConstrainedLanguage, RestrictedLanguage, NoLanguage]
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_language_modes?view=powershell-7.4&WT.mc_id=ps-gethelp
77
schema: 2.0.0
@@ -60,7 +60,7 @@ ConstrainedLanguage
6060
```
6161

6262
However, in sessions with `RestrictedLanguage` and `NoLanguage` modes, you
63-
can't use the [member-access operator][02] (`.`) to get property values.
63+
can't use the [member-access operator][03] (`.`) to get property values.
6464
Instead, the error message reveals the language mode.
6565

6666
When you access `$ExecutionContext.SessionState.LanguageMode` in a
@@ -150,7 +150,7 @@ running a defined set of commands and can't directly access APIs, the file
150150
system, or other system resources.
151151

152152
For more information, see [JEA Session configurations][01] and
153-
[New-PSSessionConfigurationFile][05].
153+
[New-PSSessionConfigurationFile][06].
154154

155155
## Language mode features and limitations
156156

@@ -223,6 +223,12 @@ The features of `ConstrainedLanguage` mode are as follows:
223223
- Users can get all properties of allowed types. Users can set the values of
224224
properties only on allowed types.
225225

226+
> [!IMPORTANT]
227+
> You must use `ConstrainedLanguage` mode in System Lockdown mode with App
228+
> Control for Business to ensure that `ConstrainedLanguage` mode can't be
229+
> bypassed. For more information about how PowerShell supports AppLocker and
230+
> App Control, see [Use App Control to secure PowerShell][02].
231+
226232
The following .NET types are permitted in `ConstrainedLanguage` mode. Users can
227233
get properties, invoke methods, and convert objects to these types.
228234

@@ -346,12 +352,13 @@ Beginning in PowerShell 7.2, the `New-Object` cmdlet is disabled in
346352

347353
## See also
348354

349-
- [about_Session_Configuration_Files][03]
350-
- [about_Session_Configurations][04]
355+
- [about_Session_Configuration_Files][04]
356+
- [about_Session_Configurations][05]
351357

352358
<!-- link references -->
353359
[01]: /powershell/scripting/learn/remoting/jea/session-configurations
354-
[02]: about_Member-Access_Enumeration.md
355-
[03]: about_Session_Configuration_Files.md
356-
[04]: about_Session_Configurations.md
357-
[05]: xref:Microsoft.PowerShell.Core.New-PSSessionConfigurationFile
360+
[02]: /powershell/scripting/security/app-control/application-control
361+
[03]: about_Member-Access_Enumeration.md
362+
[04]: about_Session_Configuration_Files.md
363+
[05]: about_Session_Configurations.md
364+
[06]: xref:Microsoft.PowerShell.Core.New-PSSessionConfigurationFile

reference/7.5/Microsoft.PowerShell.Core/About/about_Language_Modes.md

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Explains language modes and their effect on PowerShell sessions.
33
Locale: en-US
4-
ms.date: 01/18/2026
4+
ms.date: 01/26/2026
55
no-loc: [FullLanguage, ConstrainedLanguage, RestrictedLanguage, NoLanguage]
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_language_modes?view=powershell-7.5&WT.mc_id=ps-gethelp
77
schema: 2.0.0
@@ -60,7 +60,7 @@ ConstrainedLanguage
6060
```
6161

6262
However, in sessions with `RestrictedLanguage` and `NoLanguage` modes, you
63-
can't use the [member-access operator][02] (`.`) to get property values.
63+
can't use the [member-access operator][03] (`.`) to get property values.
6464
Instead, the error message reveals the language mode.
6565

6666
When you access `$ExecutionContext.SessionState.LanguageMode` in a
@@ -150,7 +150,7 @@ running a defined set of commands and can't directly access APIs, the file
150150
system, or other system resources.
151151

152152
For more information, see [JEA Session configurations][01] and
153-
[New-PSSessionConfigurationFile][05].
153+
[New-PSSessionConfigurationFile][06].
154154

155155
## Language mode features and limitations
156156

@@ -223,6 +223,12 @@ The features of `ConstrainedLanguage` mode are as follows:
223223
- Users can get all properties of allowed types. Users can set the values of
224224
properties only on allowed types.
225225

226+
> [!IMPORTANT]
227+
> You must use `ConstrainedLanguage` mode in System Lockdown mode with App
228+
> Control for Business to ensure that `ConstrainedLanguage` mode can't be
229+
> bypassed. For more information about how PowerShell supports AppLocker and
230+
> App Control, see [Use App Control to secure PowerShell][02].
231+
226232
The following .NET types are permitted in `ConstrainedLanguage` mode. Users can
227233
get properties, invoke methods, and convert objects to these types.
228234

@@ -346,12 +352,13 @@ Beginning in PowerShell 7.2, the `New-Object` cmdlet is disabled in
346352

347353
## See also
348354

349-
- [about_Session_Configuration_Files][03]
350-
- [about_Session_Configurations][04]
355+
- [about_Session_Configuration_Files][04]
356+
- [about_Session_Configurations][05]
351357

352358
<!-- link references -->
353359
[01]: /powershell/scripting/learn/remoting/jea/session-configurations
354-
[02]: about_Member-Access_Enumeration.md
355-
[03]: about_Session_Configuration_Files.md
356-
[04]: about_Session_Configurations.md
357-
[05]: xref:Microsoft.PowerShell.Core.New-PSSessionConfigurationFile
360+
[02]: /powershell/scripting/security/app-control/application-control
361+
[03]: about_Member-Access_Enumeration.md
362+
[04]: about_Session_Configuration_Files.md
363+
[05]: about_Session_Configurations.md
364+
[06]: xref:Microsoft.PowerShell.Core.New-PSSessionConfigurationFile

reference/7.6/Microsoft.PowerShell.Core/About/about_Language_Modes.md

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Explains language modes and their effect on PowerShell sessions.
33
Locale: en-US
4-
ms.date: 01/18/2026
4+
ms.date: 01/26/2026
55
no-loc: [FullLanguage, ConstrainedLanguage, RestrictedLanguage, NoLanguage]
66
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_language_modes?view=powershell-7.6&WT.mc_id=ps-gethelp
77
schema: 2.0.0
@@ -60,7 +60,7 @@ ConstrainedLanguage
6060
```
6161

6262
However, in sessions with `RestrictedLanguage` and `NoLanguage` modes, you
63-
can't use the [member-access operator][02] (`.`) to get property values.
63+
can't use the [member-access operator][03] (`.`) to get property values.
6464
Instead, the error message reveals the language mode.
6565

6666
When you access `$ExecutionContext.SessionState.LanguageMode` in a
@@ -150,7 +150,7 @@ running a defined set of commands and can't directly access APIs, the file
150150
system, or other system resources.
151151

152152
For more information, see [JEA Session configurations][01] and
153-
[New-PSSessionConfigurationFile][05].
153+
[New-PSSessionConfigurationFile][06].
154154

155155
## Language mode features and limitations
156156

@@ -223,6 +223,12 @@ The features of `ConstrainedLanguage` mode are as follows:
223223
- Users can get all properties of allowed types. Users can set the values of
224224
properties only on allowed types.
225225

226+
> [!IMPORTANT]
227+
> You must use `ConstrainedLanguage` mode in System Lockdown mode with App
228+
> Control for Business to ensure that `ConstrainedLanguage` mode can't be
229+
> bypassed. For more information about how PowerShell supports AppLocker and
230+
> App Control, see [Use App Control to secure PowerShell][02].
231+
226232
The following .NET types are permitted in `ConstrainedLanguage` mode. Users can
227233
get properties, invoke methods, and convert objects to these types.
228234

@@ -346,12 +352,13 @@ Beginning in PowerShell 7.2, the `New-Object` cmdlet is disabled in
346352

347353
## See also
348354

349-
- [about_Session_Configuration_Files][03]
350-
- [about_Session_Configurations][04]
355+
- [about_Session_Configuration_Files][04]
356+
- [about_Session_Configurations][05]
351357

352358
<!-- link references -->
353359
[01]: /powershell/scripting/learn/remoting/jea/session-configurations
354-
[02]: about_Member-Access_Enumeration.md
355-
[03]: about_Session_Configuration_Files.md
356-
[04]: about_Session_Configurations.md
357-
[05]: xref:Microsoft.PowerShell.Core.New-PSSessionConfigurationFile
360+
[02]: /powershell/scripting/security/app-control/application-control
361+
[03]: about_Member-Access_Enumeration.md
362+
[04]: about_Session_Configuration_Files.md
363+
[05]: about_Session_Configurations.md
364+
[06]: xref:Microsoft.PowerShell.Core.New-PSSessionConfigurationFile

reference/docs-conceptual/security/app-control/application-control.md

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
description: This article explains the features of Application Control that can be used to secure your PowerShell environment.
3-
ms.date: 12/09/2025
3+
ms.date: 01/26/2026
44
title: Use App Control to secure PowerShell
55
---
66
# Use App Control to secure PowerShell
@@ -26,11 +26,13 @@ following name format:
2626
- `$Env:TEMP/__PSScriptPolicyTest_<random-8dot3-name>.ps1`
2727
- `$Env:TEMP/__PSScriptPolicyTest_<random-8dot3-name>.psm1`
2828

29-
App Control for Business is the preferred application control system for Windows. App Control
30-
provides APIs that allow you to discover the policy configuration. App Control is designed as a
31-
security feature under the servicing criteria defined by the Microsoft Security Response Center
32-
(MSRC). For more information, see [Application Controls for Windows][04] and
33-
[App Control and AppLocker feature availability][02].
29+
App Control for Business is the preferred application control system for Windows. App Control puts
30+
the system into System Lockdown mode. System Lockdown mode is the feature that detects the policies
31+
and determines if a context needs to be initialized or changed to a specific language mode.
32+
33+
App Control is designed as a security feature under the servicing criteria defined by the Microsoft
34+
Security Response Center (MSRC). For more information, see [Application Controls for Windows][04]
35+
and [App Control and AppLocker feature availability][02].
3436

3537
> [!NOTE]
3638
> When [choosing between App Control or AppLocker][03], we recommend that you implement application

reference/docs-conceptual/security/remoting/jea/security-considerations.md

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description: >-
33
Since JEA allows these users to run administrative commands without having full administrator
44
access, you can then remove those users from highly privileged security groups.
5-
ms.date: 10/10/2023
5+
ms.date: 01/26/2026
66
title: JEA Security Considerations
77
---
88
# JEA Security Considerations
@@ -102,8 +102,16 @@ access to all mapped users. For example, a JEA session configured using the foll
102102
grants full access to `CONTOSO\JEA_Lev1` and `CONTOSO\JEA_Lev2`.
103103

104104
```powershell
105-
$roles = @{ 'CONTOSO\JEA_Lev1' = 'Lev1Role'; 'CONTOSO\JEA_Lev2' = 'Lev2Role' }
106-
New-PSSessionConfigurationFile -Path '.\jea.pssc' -SessionType RestrictedRemoteServer -RoleDefinitions $roles -RunAsVirtualAccount
105+
$newPSSessionConfigurationFileSplat = @{
106+
Path = '.\jea.pssc'
107+
SessionType = 'RestrictedRemoteServer'
108+
RoleDefinitions = @{
109+
'CONTOSO\JEA_Lev1' = 'Lev1Role'
110+
'CONTOSO\JEA_Lev2' = 'Lev2Role'
111+
}
112+
RunAsVirtualAccount = $true
113+
}
114+
New-PSSessionConfigurationFile @newPSSessionConfigurationFileSplat
107115
Register-PSSessionConfiguration -Path '.\jea.pssc' -Name 'MyJEAEndpoint'
108116
```
109117

@@ -187,7 +195,9 @@ configured session.
187195
### Don't allow commands that can create new runspaces.
188196

189197
> [!WARNING]
190-
> The `*-Job` cmdlets can create new runspaces without the restrictions.
198+
> The Windows Compatibility feature in PowerShell 7 creates a new runspace to host Windows
199+
> PowerShell. Don't allow any commands that would run via the Windows Compatibility feature. The
200+
> `*-Job` cmdlets can create new runspaces without the restrictions.
191201
192202
### Don't allow the `Trace-Command` cmdlet.
193203

reference/docs-conceptual/security/securing-restricted-sessions.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
description: This article explains how to secure a restricted PowerShell session that is used for secure remote access.
3-
ms.date: 10/10/2023
3+
ms.date: 01/26/2026
44
title: Securing a restricted PowerShell remoting session
55
---
66
# Securing a restricted PowerShell remoting session
@@ -39,7 +39,9 @@ restricted session implementation.
3939
### Don't allow commands that can create new runspaces
4040

4141
> [!WARNING]
42-
> The `*-Job` cmdlets can create new runspaces without the restrictions.
42+
> The Windows Compatibility feature in PowerShell 7 creates a new runspace to host Windows
43+
> PowerShell. Don't allow any commands that would run via the Windows Compatibility feature. The
44+
> `*-Job` cmdlets can create new runspaces without the restrictions.
4345
4446
### Don't allow the `Trace-Command` cmdlet.
4547

0 commit comments

Comments
 (0)