簡體   English   中英

如何通過 powershell ISE 腳本編輯安全選項(在本地安全策略中)?

[英]How would I edit Security Options ( In Local Security Policy ) through a powershell ISE script?

我到處尋找可以滿足我需求的腳本。 我真的不在乎它是復雜的還是簡單的。 我只需要它來編輯安全選項中的多個設置。 我在 Windows 10。如果有人能提供幫助,將不勝感激。

使用普通的注冊表 cmdlet,因為這是它們所在的位置,但要知道有模塊可以提供幫助。

Find-Module -Name '*Policy*' | Format-List

具體來說

Find-Module -Name '*PolicyFileEditor*' | Format-List

看看他們在做什么並使用它或嘗試根據需要進行調整。

也可以看看:

管理來自 PowerShell 和所需 State 配置的本地組策略對象

Get-PolicyFileEntry [-Path] <string> [-Key] <string> [-ValueName] <string> [<CommonParameters>]
Get-PolicyFileEntry [-Path] <string> -All [<CommonParameters>]
Set-PolicyFileEntry [-Path] <string> [-Key] <string> [-ValueName] <string> [-Data] <Object> [-Type <RegistryValueKind>] [-NoGptIniUpdate] [-WhatIf] [-Confirm] [<CommonParameters>]
Remove-PolicyFileEntry [-Path] <string> [-Key] <string> [-ValueName] <string> [-NoGptIniUpdate] [-WhatIf] [-Confirm] [<CommonParameters>]
Update-GptIniVersion [-Path] <string> [-PolicyType] <string[]> [-WhatIf] [-Confirm] [<CommonParameters>]

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM