当前位置: 首页 > news >正文

[笔记] 关于CreateProcessWithLogonW函数创建进程

函数介绍

https://learn.microsoft.com/zh-cn/windows/win32/api/winbase/nf-winbase-createprocesswithlogonw

BOOL CreateProcessWithLogonW([in]                LPCWSTR               lpUsername,[in, optional]      LPCWSTR               lpDomain,[in]                LPCWSTR               lpPassword,[in]                DWORD                 dwLogonFlags,[in, optional]      LPCWSTR               lpApplicationName,[in, out, optional] LPWSTR                lpCommandLine,[in]                DWORD                 dwCreationFlags,[in, optional]      LPVOID                lpEnvironment,[in, optional]      LPCWSTR               lpCurrentDirectory,[in]                LPSTARTUPINFOW        lpStartupInfo,[out]               LPPROCESS_INFORMATION lpProcessInformation
);

几种使用方法

使用存在的账号信息创建进程

在这里插入图片描述

使用空网络账号信息创建进程

在这里插入图片描述
所以即使账号信息实际不存在也可以创建进程,只是无权访问网络资源

if (!CreateProcessWithLogonW(L"MalseclogonUser", L"MalseclogonDomain", L"MalseclogonPwd", LOGON_NETCREDENTIALS_ONLY, NULL, cmdline, 0, NULL, NULL, &startInfo, &procInfo)) {printf("CreateProcessWithLogonW() failed with error code %d \n", GetLastError());
} else {// the returned handles in procInfo are wrong and duped into the spoofed parent process, so we can't close handles or wait for process end.printf("Spoofed process %S created correctly as child of PID %d using CreateProcessWithLogonW()!", cmdline, pid);
}
http://www.lryc.cn/news/465325.html

相关文章:

  • Ubuntu的Qt编译环境配置
  • 12 django管理系统 - 注册与登录 - 登录
  • 2020年计算机网络408真题解析
  • 速盾:cdn高防服务器防火墙的特性是什么?
  • 小程序分包和预加载
  • 【MATLAB 串口调试+虚拟串口测试】
  • mac 安装最新版nginx
  • 极氪汽车困局:营销频繁车、产品力不足
  • Icecream 与 Python 日志库及性能分析整合指南
  • 请解读下面的程序:pat =re.compile(r‘\d+‘)res = pat.search(‘www.ddd996.com‘)res.group()
  • Fibonacci任意一位的值得算法
  • gbn,sr和tcp的区别
  • FastGPT本地开发 之 通过Navicat管理MongoDB、PostgreSQL数据库
  • hardhat部署智能合约
  • 界面控件DevExtreme中文教程 - 如何与Amazon S3和Azure Blob存储集成?
  • 【ERROR】ubuntu source: not found
  • 聚焦IOC容器刷新环节postProcessBeanFactory(BeanFactory后置处理)专项
  • 配置nginx服务通过ip访问多网站
  • 银河麒麟V10设置QT开发程序开机自启动
  • RabbitMQ高级特性详解
  • 提升泛化能力的前沿方法:多任务学习在机器学习中的应用与实践
  • 【小白学机器学习16】 概率论的世界观2
  • 洛谷 P9868 [NOIP2023] 词典
  • 跨浏览器免费书签管理系统
  • 导出Excel的常用方法:从前端到后端的全面指南
  • uni-app中添加自定义相机(微信小程序+app)
  • Android中的SSL/TLS加密及其作用
  • 东芝TLP176AM光耦合器:提升设计性能的关键元件
  • MySQL数据库:基础介绍下载与安装
  • 原理代码解读:基于DiT结构视频生成模型的ControlNet