netcat源代码分析,doexec.c中的句柄
来源:互联网 发布:fifa online3数据库15 编辑:程序博客网 时间:2024/04/30 08:56
Result = CreatePipe(&Session->ReadPipeHandle, &ShellStdoutPipe,
&SecurityAttributes, 0);
if (!Result) {
holler("Failed to create shell stdout pipe, error = %s",
itoa(GetLastError(), smbuff, 10), NULL, NULL, NULL, NULL, NULL);
goto Failure;
}
fprintf (stderr," Session->ReadPipeHandle = %x\n",Session->ReadPipeHandle);
fprintf (stderr," ShellStdoutPipe = %x\n",ShellStdoutPipe);
Result = CreatePipe(&ShellStdinPipe, &Session->WritePipeHandle,
&SecurityAttributes, 0);
if (!Result) {
holler("Failed to create shell stdin pipe, error = %s",
itoa(GetLastError(), smbuff, 10), NULL, NULL, NULL, NULL, NULL);
goto Failure;
}
fprintf (stderr," Session->WritePipeHandle = %x\n",Session->WritePipeHandle);
fprintf (stderr," ShellStdinPipe = %x\n",ShellStdinPipe);
Session->ReadPipeHandle = 738
ShellStdoutPipe = 734Session->WritePipeHandle = 72c
ShellStdinPipe = 730
上面是调试的结果,下面的是创建的两个管道,4个句柄,其中netcat.exe用到了2个句柄
cmd.exe用到了两个句柄。
ShellStdoutPipe(stdout) ---> Session->ReadPipeHandle ReadFile() --> net
cmd.exe netcat.exe
ShellStdinPipe (stdin ) <--- Session->WritePipeHandle WriteFile() <-- net
- netcat源代码分析,doexec.c中的句柄
- netcat源代码分析(4)doexec.c文件中的SessionWriteShellThreadFn ()函数
- netcat源代码分析,doexec ()函数和readwrite ()函数的关系
- netcat源代码分析,dolisten()函数中的whoisit
- 知识收藏---netcat源代码分析
- netcat源代码分析,gethostpoop()函数
- netcat源代码分析,doconnect()函数的作用
- NetCat代码分析
- NetCat代码分析
- 分析netcat程序代码
- 分析netcat程序代码
- netcat源代码分析,udp模式(1)服务端如何得到客户端的ip地址和端口号?
- pjsip中的源代码分析
- qsort.c源代码分析
- Gcc源代码分析,rtl.c源代码分析
- Linux内核源代码中的C语言代码(Linux内核源代码情景分析读书笔记连载)
- 枚举指定进程内核对象句柄的C源代码
- Netcat 命令--网络工具中的瑞士军刀
- HTML学习笔记(七)HTML 文本格式化
- 应聘技巧回答
- 面向消息的中间件
- 河南省蓝桥杯 微生物增殖
- 如何在win32非控制台应用程序中使用iostream输出信息?
- netcat源代码分析,doexec.c中的句柄
- 黑客教程
- MySQL中,主键与普通索引的区别是什么
- 经典SQL语句大全(三)
- 数据存储
- GPS定位+谷歌地图应用的防盗定位设计
- 贪心算法(活动安排)
- 友善之臂视频监控方案源码学习(3) - 守护进程
- hdu 1372