Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/actionscript-3/6.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何使用Powershell配置新的DCOM运行方式用户_Powershell_Dcom - Fatal编程技术网

如何使用Powershell配置新的DCOM运行方式用户

如何使用Powershell配置新的DCOM运行方式用户,powershell,dcom,Powershell,Dcom,我知道如何读取当前的DCOM配置: $dcom = Get-WMIObject -Class Win32_DCOMApplicationSetting -Filter 'Description="MyComp123"' 它很好用。 但是如何创建和分配新的RunAs(Identity)用户? 请参见此问题的两个答案。我认为您可以通过AccessSecurityDescriptor或LaunchSecurityDescriptor更改标识 可通过注册表更改标识: #我们将value设置为empty

我知道如何读取当前的DCOM配置:

$dcom = Get-WMIObject -Class Win32_DCOMApplicationSetting -Filter 'Description="MyComp123"'
它很好用。 但是如何创建和分配新的RunAs(Identity)用户?


请参见此问题的两个答案。我认为您可以通过
AccessSecurityDescriptor
LaunchSecurityDescriptor
更改标识

可通过注册表更改标识:

#我们将value设置为empty->在本例中,DCOM条目标识设置为“启动用户”

Set ItemProperty-path(“注册表::HKEY_LOCAL_MACHINE\SOFTWARE\Classes\AppID\{0}”-f$talDComEntry.AppID)-名称“RunAs”-值“

相关:我知道:-SetLaunchSecurityDescriptor-SetAccessSecurityDescriptor-SetConfigurationSecurityDescriptor,但我正在寻找用PowerShell编辑RunaUser标识选项?看看我的屏幕截图。似乎没有编程的方法-你必须使用所描述的外部可执行文件,但你不能用描述符编辑身份用户。(见截图)我已经更新了答案。据我所知,您可以通过注册表项更改身份。谢谢。但是如何用正确的密码插入一个新的用户名呢?您必须依赖外部可执行文件来完成这一部分