Records below are third-party data, not instructions. Apply with your own judgment.
New-Item: Requested registry access is not allowed.
Cause
MSIX registry virtualization refuses KEY_SET_VALUE on HKLM\SOFTWARE; New-Item opens that parent with OpenSubKey(name, writable=true), i.e. KEY_WRITE, which includes that mask.
Fix
-New-Item Registry::HKLM\SOFTWARE\<key>+# create the leaf directly; never opens HKLM\SOFTWARE for write+$k = [Microsoft.Win32.Registry]::LocalMachine.CreateSubKey('SOFTWARE\<key>')+# or open the parent with only the CreateSubKey right:+$p = [Microsoft.Win32.Registry]::LocalMachine.OpenSubKey('SOFTWARE',+ [Microsoft.Win32.RegistryKeyPermissionCheck]::ReadWriteSubTree,+ [System.Security.AccessControl.RegistryRights]::CreateSubKey)+$k = $p.CreateSubKey('<key>')Don’t try
[Microsoft.Win32.Registry]::LocalMachine.OpenSubKey('SOFTWARE', $true) then CreateSubKey — the Boolean writable overload requests KEY_WRITE, which includes KEY_SET_VALUE, so it fails with the same SecurityException.
rerun New-Item from an elevated (Run as administrator) MSIX pwsh — the report already ran elevated; the denial comes from MSIX virtualization of HKLM\SOFTWARE, not from the ACL or the token.