找回密码
 加入
搜索
查看: 2249|回复: 5

注册表修改权限

  [复制链接]
发表于 2010-1-23 00:23:42 | 显示全部楼层 |阅读模式
怎样修改HKEY_CLASSES_ROOT\CLSID权限?
试了很多外部程序都无法实现
发表于 2010-1-23 00:29:36 | 显示全部楼层
这个键值没什么权限限制吧。。

有些键值是有权限限制的,可以用外置程序修改,譬如setacl,命令行的,很小,可以打包到AU3
发表于 2010-1-23 03:08:09 | 显示全部楼层
参见pusofalse大侠关于修改权限的极贴

http://www.autoitx.com/forum.php ... &extra=page%3D1
发表于 2010-1-23 12:41:52 | 显示全部楼层
之前经过一段时间的测试 用setacl 修改  
目前还不知道   下面这个的注册表怎么设置  Au3 本地安全管理|审核UDF LocalSecurityAuthority
http://www.autoitx.com/forum.php ... &extra=page%3D1
发表于 2010-1-23 12:44:25 | 显示全部楼层
刚刚又看了一下
 
; #### Registry key security functions ####
; =========================================================
; _RegCloseKey ( internal used only )        ; 关闭注册表键句柄, 内部使用
; _RegGetKeySecurity                ; 返回注册表键安全
; _RegGetKeySecurityDacl                ; 返回...............访问权限
; _RegGetKeySecurityOwner                ; ......................所有者
; _RegGetKeySecuritySacl                ; 注册表键系统访问列表(SACL)
; _RegOpenKeyEx ( internal used only )        ; 打开注册表键句柄 (内部使用)
; _RegSetKeySecurity                ; 设置注册表键安全
; _RegSetKeySecurityDacl                ; ......................DACL
; _RegSetKeySecurityOwner                ; ......................所有者
; =========================================================
发表于 2010-1-23 15:56:06 | 显示全部楼层
本帖最后由 pusofalse 于 2010-1-23 15:57 编辑
#include <LocalSecurityAuthority.au3>

$hRegKey = 0x80000000 ; 0x80000000 = HKEY_CLASSES_ROOT

Local $aDacl[3][4] = [["BUILTIN\Administrators", 0xF003F, $SET_ACCESS, 3], _
                ["NT AUTHORITY\System", 0xF003F, $SET_ACCESS, 3], _
                ["CREATOR OWNER", 0xF003F, $SET_ACCESS, 3]]
; 只允许Administrators、System、Creator Owner三个用户的全部访问请求,其他用户的任意访问请求都将被拒绝。
; 0xF003F - 所有访问,0x20019 - 读取操作。
; 3 - 权限继承到子键。
; SET_ACCESS - 访问类型为“允许”,DENY_ACCESS拒绝。
$fResult = _RegSetKeySecurityDacl($hRegKey, "CLSID", $aDacl)
Msgbox(0, $fResult, @error)
您需要登录后才可以回帖 登录 | 加入

本版积分规则

QQ|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度

GMT+8, 2024-9-22 14:42 , Processed in 0.073553 second(s), 22 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表