.. / Win32_Environment

Represents an environment or system environment setting on a Windows computer system


Functions:
Type:
Toolsets:

Manage

Set environment variable

New-CimInstance -ClassName Win32_Environment -Property @{Name="PATH";VariableValue="C:\hackertools; C:\Windows\System32;C:\Windows";UserName="<SYSTEM>"} -CimSession $s
Usecase
Change PATH environment variable for search order hijacking

Comments



Updated: 2023-07-01
Contributor: Arris Huijgen (bitsadmin)