提权函数之RtlAdjustPrivilege()使用说明
时间:2021-08-27 04:16:49
下面是函数定义:
NTSTATUS RtlAdjustPrivilege
(
ULONG Privilege,
BOOLEAN Enable,
BOOLEAN CurrentThread,
PBOOLEAN Enabled
)
参数的含义:
Privilege [In] Privilege index to change.
// 所需要的权限名称,可以到MSDN查找关于Process Token & Privilege内容可以查到
Enable [In] If TRUE, then enable the privilege otherwise disable.
// 如果为True 就是打开相应权限,如果为False 则是关闭相应权限
CurrentThread [In] If TRUE, then enable in calling thread, otherwise process.
// 如果为True 则仅提升当前线程权限,否则提升整个进程的权限
Enabled [Out] Whether privilege was previously enabled or disabled.
// 输出原来相应权限的状态(打开 | 关闭)
用法很简单:
#define SE_DEBUG_PRIVILEGE 0x14 //DEBUG 权限
int s;
RtlAdjustPrivilege(SE_DEBUG_PRIVILEGE,true,false,&s);
标签:RtlAdjustPrivilege,提权
![](/images/zang.png)
![](/images/jiucuo.png)
猜你喜欢
Java基础之位运算知识总结
2022-09-10 17:48:43
![](https://img.aspxhome.com/file/2023/3/66043_0s.png)
Android编程之ListView和EditText发布帖子隐藏软键盘功能详解
2023-11-06 23:09:55
Yml转properties文件工具类YmlUtils的详细过程(不用引任何插件和依赖)
2021-08-18 03:55:00
![](https://img.aspxhome.com/file/2023/4/77084_0s.png)
Java构造代码块,静态代码块原理与用法实例分析
2023-11-03 09:03:45
![](https://img.aspxhome.com/file/2023/7/58707_0s.png)
springboot+mybatis-plus 两种方式打印sql语句的方法
2022-12-29 13:41:11
![](https://img.aspxhome.com/file/2023/9/64379_0s.jpg)
C#中的IEnumerable接口深入研究
2022-04-06 11:13:42
![](https://img.aspxhome.com/file/2023/7/94567_0s.jpg)
C# 生成随机数的代码
2021-06-16 06:05:43
Java数组传递及可变参数操作实例详解
2023-08-26 21:21:59
![](https://img.aspxhome.com/file/2023/0/77160_0s.png)
命令行编译java文件方式
2023-01-18 18:35:47
![](https://img.aspxhome.com/file/2023/2/60252_0s.png)
c#使用filesystemwatcher实时监控文件目录的添加和删除
2021-12-04 18:01:57
java使用集合实现通讯录功能
2023-01-30 21:27:15
一步步教你把SpringBoot项目打包成Docker镜像
2022-01-10 12:21:02
![](https://img.aspxhome.com/file/2023/9/85439_0s.png)
Java多线程模拟银行系统存钱问题详解
2023-11-28 22:13:32
![](https://img.aspxhome.com/file/2023/4/60254_0s.jpg)
Java IO之流的分类详解
2022-08-14 02:18:41
![](https://img.aspxhome.com/file/2023/1/82331_0s.png)
解决mybatis plus 驼峰式命名规则问题
2022-09-29 11:24:34
![](https://img.aspxhome.com/file/2023/2/62712_0s.png)
Java面向对象程序设计:类的定义,静态变量,成员变量,构造函数,封装与私有,this概念与用法详解
2022-07-12 03:35:14
![](https://img.aspxhome.com/file/2023/5/61885_0s.png)
Java多线程编程小实例模拟停车场系统
2022-07-07 06:36:29
Java之 TreeSet的详细使用说明
2021-08-22 14:52:22
![](https://img.aspxhome.com/file/2023/8/77078_0s.jpg)
spring+srpingmvc+hibernate实现动态ztree生成树状图效果
2022-07-21 21:41:59
详解Dagger2在Android开发中的新用法
2021-08-23 22:39:40