DCOM安全使用批处理文件 [英] DCOM Security using a batch file

查看:495
本文介绍了DCOM安全使用批处理文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有任何方法来改变使用批处理文件的COM安全的访问权限?
我需要写新值编辑限制...和编辑默认......在这两个访问权限和启动和激活权限使用批处理脚本。
我使用Windows XP机器带有Service Pack 2和3。

Are there any methods to change the Access Permissions for COM Security using a batch file? I need to write new values to "Edit Limits..." and "Edit Default..." in both "Access Permissions" and "Launch and Activation Permissions" using a batch script. I'm using Windows XP machines with Service Pack 2 and 3.

感谢您。

推荐答案

我最近有必要建立一个批处理脚本授予默认的本地激活权限,这样我可以运行在Windows Azure上的进程外的COM组件。经过反复研究,我使用了一种叫做工具 RegFromApp (下载链接页面的底部附近)看到在Windows注册表中所作的更改,当我授予的Windows Server 2008 R2的虚拟机在上述权限。下面是我用来确定如何更改对注册表的步骤...

I recently had the need to create a batch script to grant default Local Activation permissions so that I could run an out-of-process COM component on Windows Azure. After much research, I used a tool called RegFromApp (download link is near bottom of page) to see what changes were made in the Windows Registry when I granted the aforementioned permissions on a Windows Server 2008 R2 VM. Here are the steps I used to determine what changes to make to the registry...


  1. 进入 DCOMCNFG 在命令提示符下启动组件
    服务

  2. 推出 RegFromApp 程序

  3. 在RegFromApp,选择 MMC.EXE 工艺,并点击确定以检查什么样的变化会令注册表

  4. 早在组件服务,扩大 组件服务在左侧面板项目

  5. 扩展 计算机在左侧面板项目

  6. 右键单击 我的电脑在左侧面板项目,并选择属性
    从弹出菜单中

  7. COM安全标签

  8. 启动和激活权限框中,单击 编辑默认
    按钮

  9. 单击的 添加按钮

  10. 进入 IIS_IUSRS 的空盒子,单击检查名称按钮和
    单击确定按钮

  11. 选中 允许 本地激活并单击确定按钮

  12. 单击的 应用按钮和确定按钮

  13. 早在RegFromApp程序,单击 另存为从文件菜单中保存的注册表
     变化 SetDCOMPermission.reg 文件

  1. Entered dcomcnfg in the Command Prompt to launch Component Services
  2. Launched RegFromApp program
  3. In RegFromApp, selected the mmc.exe process and clicked OK to inspect what changes it would make to registry
  4. Back in Component Services, expanded Component Services item in left panel
  5. Expanded Computers item in left panel
  6. Right-clicked My Computer item in left panel and selected Properties from popup menu
  7. Selected COM Security tab
  8. In Launch and Activation Permissions box, clicked Edit Default button
  9. Clicked Add button
  10. Entered IIS_IUSRS in empty box, clicked Check Names button and clicked OK button
  11. Ticked Allow for Local Activation and clicked OK button
  12. Clicked Apply button then OK button
  13. Back in RegFromApp program, clicked Save As from the File menu to save registry changes as SetDCOMPermission.reg file

已经记录在一个.reg文件(注册表更改,即在 DefaultLaunchPermission 值在 [HKEY_LOCAL_MACHINE \\ SOFTWARE \\微软\\ OLE修改] 的键),我写了下面批处理脚本来注册我的COM组件,并通过运行我的.reg文件应用更改注册表...

Having recorded the registry changes in a .reg file (i.e. the DefaultLaunchPermission value was modified in the [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\OLE] key), I wrote the following batch script to register my COM component and apply the changes to the registry by running my .reg file...

chcp 1252>NUL
OleAutomationFeasibilityModel.exe /regserver
regedit.exe /s SetDCOMPermission.reg
exit /b 0

我敢肯定,你可以使用类似的技术来记录你想在一个.reg文件来实现,并运行一个批处理脚本文件有什么必要的注册表更改。

I'm sure you could use a similar technique to record the necessary registry changes for what you're trying to achieve in a .reg file and run this file from a batch script.

希望帮助!

这篇关于DCOM安全使用批处理文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆