命令简介
tasklist命令显示本地计算机或远程计算机上当前正在运行的进程列表。命令结合筛选器一起使用,可以按照我们的需求进行过滤,查找我们需要了解的进程信息。tasklist 替换 tlist.exe 工具。
获取命令帮助
E:\> tasklist /?`` ``TASKLIST [/S system [/U username [/P [password]]]]` `[/M [module] | /SVC | /V] [/FI filter] [/FO format] [/NH]`` ``描述:` `该工具显示在本地或远程机器上当前运行的进程列表。`` `` ``参数列表:` `/S system 指定连接到的远程系统。`` ` `/U [domain\]user 指定应该在哪个用户上下文执行这个命令。`` ` `/P [password] 为提供的用户上下文指定密码。如果省略,则` `提示输入。`` ` `/M [module] 列出当前使用所给 exe/dll 名称的所有任务。` `如果没有指定模块名称,显示所有加载的模块。`` ` `/SVC 显示每个进程中主持的服务。`` ` `/APPS 显示 Microsoft Store 应用及其关联的进程。`` ` `/V 显示详细任务信息。`` ` `/FI filter 显示一系列符合筛选器` `指定条件的任务。`` ` `/FO format 指定输出格式。` `有效值: "TABLE"、"LIST"、"CSV"。`` ` `/NH 指定列标题不应该` `在输出中显示。` `只对 "TABLE" 和 "CSV" 格式有效。`` ` `/? 显示此帮助消息。`` ``筛选器:` `筛选器名称 有效运算符 有效值` `----------- --------------- --------------------------` `STATUS eq, ne RUNNING | SUSPENDED` `NOT RESPONDING | UNKNOWN` `IMAGENAME eq, ne 映像名称` `PID eq, ne, gt, lt, ge, le PID 值` `SESSION eq, ne, gt, lt, ge, le 会话编号` `SESSIONNAME eq, ne 会话名称` `CPUTIME eq, ne, gt, lt, ge, le CPU 时间,格式为` `hh:mm:ss。` `hh - 小时,` `mm - 分钟,ss - 秒` `MEMUSAGE eq, ne, gt, lt, ge, le 内存使用(以 KB 为单位)` `USERNAME eq, ne 用户名,格式为` `[域\]用户` `SERVICES eq, ne 服务名称` `WINDOWTITLE eq, ne 窗口标题` `模块 eq, ne DLL 名称`` ``注意: 当查询远程计算机时,不支持 "WINDOWTITLE" 和 "STATUS"` `筛选器。`` ``Examples:` `TASKLIST` `TASKLIST /M` `TASKLIST /V /FO CSV` `TASKLIST /SVC /FO LIST` `TASKLIST /APPS /FI "STATUS eq RUNNING"` `TASKLIST /M wbem*` `TASKLIST /S system /FO LIST` `TASKLIST /S system /U 域\用户名 /FO CSV /NH` `TASKLIST /S system /U username /P password /FO TABLE /NH` `TASKLIST /FI "USERNAME ne NT AUTHORITY\SYSTEM" /FI "STATUS eq running"
显示进程号大于1000的进程
E:\>tasklist /fi "PID gt 1000"`` ``映像名称 PID 会话名 会话# 内存使用``========================= ======== ================ =========== ============``svchost.exe 1084 Services 0 13,380 K``svchost.exe 1132 Services 0 11,260 K``dwm.exe 1220 Console 1 165,852 K``svchost.exe 1260 Services 0 12,876 K``svchost.exe 1296 Services 0 5,748 K``svchost.exe 1312 Services 0 12,132 K``svchost.exe 1432 Services 0 12,684 K``svchost.exe 1440 Services 0 10,568 K``svchost.exe 1528 Services 0 17,452 K``IntelCpHDCPSvc.exe 1608 Services 0 7,928 K``svchost.exe 1636 Services 0 6,488 K``svchost.exe 1720 Services 0 9,384 K``svchost.exe 1828 Services 0 8,588 K``svchost.exe 1852 Services 0 8,228 K``IntelCpHeciSvc.exe 1872 Services 0 7,668 K``svchost.exe 1948 Services 0 10,496 K``svchost.exe 1984 Services 0 7,068 K``svchost.exe 2080 Services 0 7,616 K``ibmpmsvc.exe 2108 Services 0 6,856 K``LPlatSvc.exe 2128 Services 0 8,004 K``LITSSvc.exe 2140 Services 0 8,012 K``svchost.exe 2200 Services 0 16,444 K``svchost.exe 2260 Services 0 6,892 K``QQPCRTP.exe 2456 Services 0 70,004 K``qmbsrv.exe 2476 Services 0 6,140 K``svchost.exe 2504 Services 0 12,944 K``svchost.exe 2568 Services 0 7,116 K
使用tasklist /fi “USERNAME ne mysql” /fi "status eq running"命令查看mysql用户正在运行的进程。
E:\>tasklist /fi "USERNAME ne mysql" /fi "status eq running"`` ``映像名称 PID 会话名 会话# 内存使用``========================= ======== ================ =========== ============``csrss.exe 788 Console 1 7,588 K``dwm.exe 1220 Console 1 164,540 K``LPlatSvc.exe 8764 Console 1 7,536 K``sihost.exe 8832 Console 1 32,280 K``svchost.exe 8856 Console 1 32,084 K``taskhostw.exe 8984 Console 1 17,592 K``ctfmon.exe 7172 Console 1 22,668 K``igfxEM.exe 8376 Console 1 14,596 K``explorer.exe 8336 Console 1 194,456 K``ChsIME.exe 7844 Console 1 24,808 K``TextInputHost.exe 4956 Console 1 67,200 K``StartMenuExperienceHost.e 1228 Console 1 55,820 K``SearchApp.exe 9248 Console 1 68,396 K``PowerMgr.exe 9840 Console 1 6,512 K``ShellExperienceHost.exe 9884 Console 1 77,392 K``RuntimeBroker.exe 9976 Console 1 33,968 K``igfxext.exe 9548 Console 1 11,020 K``SogouWBImeLoader.exe 4684 Console 1 16,152 K``YunDetectService.exe 5484 Console 1 15,024 K``svchost.exe 1344 Console 1 17,700 K``360ChromeX.exe 1780 Console 1 276,432 K``360ChromeX.exe 11544 Console 1 317,772 K``wpscloudsvr.exe 1960 Console 1 19,300 K``SDXHelper.exe 7832 Console 1 29,284 K``QQ.exe 5044 Console 1 348,496 K``TXPlatform.exe 4816 Console 1 3,368 K``QQGuild.exe 12196 Console 1 161,612 K``QQGuild.exe 8660 Console 1 61,296 K``POWERPNT.EXE 4064 Console 1 802,484 K``chromium.exe 9388 Console 1 110,232 K``chromium.exe 6952 Console 1 7,588 K``chromium.exe 10340 Console 1 65,908 K``cmd.exe 12880 Console 1 6,064 K``conhost.exe 12720 Console 1 40,108 K``语雀.exe 10424 Console 1 171,292 K``语雀.exe 3660 Console 1 30,492 K``语雀.exe 12280 Console 1 121,444 K``语雀.exe 7484 Console 1 48,652 K``smartscreen.exe 7328 Console 1 23,624 K
列表远程计算机运行的进程
使用命令tasklist /s 192.168.1.6 /u root /p password列出远程主机192.168.0.9的进程,使用账户root,密码password登录。
列出使用shell32.dll文件的所有进程
E:\>tasklist /m shell32.dll`` ``映像名称 PID 模块``========================= ======== ============================================``dwm.exe 1220 SHELL32.dll``ibmpmsvc.exe 2108 SHELL32.dll``LPlatSvc.exe 2128 SHELL32.dll``LITSSvc.exe 2140 SHELL32.dll``svchost.exe 2200 SHELL32.dll``svchost.exe 2960 shell32.dll``svchost.exe 3560 SHELL32.dll``svchost.exe 3668 SHELL32.dll``spoolsv.exe 4172 SHELL32.dll``AdskAccessServiceHost.exe 4496 SHELL32.dll``OfficeClickToRun.exe 4532 SHELL32.dll``OneApp.IGCC.WinService.ex 4892 shell32.dll``MSOfficePLUSService.exe 5092 shell32.dll``PAUpdateService.exe 4700 shell32.dll``vmware-usbarbitrator64.ex 6160 SHELL32.dll``svchost.exe 8644 SHELL32.dll
列出svchost进程所运行的服务
使用命令tasklist /svc /fi "imagename eq svchost.exe"列出svchost进程所运行的服务。
E:\>tasklist /svc /fi "imagename eq svchost.exe`` ``映像名称 PID 服务``========================= ======== ============================================``svchost.exe 616 BrokerInfrastructure, DcomLaunch, PlugPlay,` `Power, SystemEventsBroker``svchost.exe 1084 RpcEptMapper, RpcSs``svchost.exe 1132 LSM``svchost.exe 1260 TermService``svchost.exe 1296 lmhosts``svchost.exe 1312 bthserv``svchost.exe 1432 TimeBrokerSvc``svchost.exe 1440 NcbService``svchost.exe 1528 EventLog
查看进程详细信息
E:\>tasklist /V |more`` ``映像名称 PID 会话名 会话# 内存使用 状态 用户名 CPU 时间 窗口标题``========================= ======== ================ =========== ============ =============== ================================================== ============ ========================================================================``System Idle Process 0 Services 0 8 K Unknown NT AUTHORITY\SYSTEM 35:35:12 暂缺``System 4 Services 0 144 K Unknown 暂缺 0:11:53 暂缺``Registry 116 Services 0 71,776 K Unknown NT AUTHORITY\SYSTEM 0:00:02 暂缺``smss.exe 428 Services 0 1,284 K Unknown NT AUTHORITY\SYSTEM 0:00:00 暂缺``csrss.exe 688 Services 0 6,940 K Unknown NT AUTHORITY\SYSTEM 0:00:01 暂缺``wininit.exe 768 Services 0 7,192 K Unknown NT AUTHORITY\SYSTEM 0:00:00 暂缺``csrss.exe 788 Console 1 7,620 K Running NT AUTHORITY\SYSTEM 0:00:20 暂缺``services.exe 836 Services 0 10,708 K Unknown NT AUTHORITY\SYSTEM 0:00:19 暂缺``winlogon.exe 868 Console 1 11,804 K Unknown NT AUTHORITY\SYSTEM 0:00:01 暂缺``lsass.exe 908 Services 0 22,328 K Unknown NT AUTHORITY\SYSTEM 0:00:06 暂缺``svchost.exe 616 Services 0 29,508 K Unknown NT AUTHORITY\SYSTEM 0:00:23 暂缺``fontdrvhost.exe 644 Console 1 60,380 K Unknown Font Driver Host\UMFD-1 0:00:11 暂缺``fontdrvhost.exe 680 Services 0 15,496 K Unknown Font Driver Host\UMFD-0 0:00:00 暂缺``WUDFHost.exe 668 Services 0 5,692 K Unknown NT AUTHORITY\LOCAL SERVICE 0:00:00 暂缺``svchost.exe 1084 Services 0 13,684 K Unknown NT AUTHORITY\NETWORK SERVICE 0:00:11 暂缺``svchost.exe 1132 Services 0 11,380 K Unknown NT AUTHORITY\SYSTEM 0:00:02 暂缺``dwm.exe 1220 Console 1 149,108 K Running Window Manager\DWM-1 0:24:28 DWM Notification Window``svchost.exe 1260 Services 0 12,880 K Unknown NT AUTHORITY\NETWORK SERVICE 0:00:00 暂缺``svchost.exe 1296 Services 0 5,732 K Unknown NT AUTHORITY\LOCAL SERVICE 0:00:00 暂缺``svchost.exe 1312 Services 0 12,136 K Unknown NT AUTHORITY\LOCAL SERVICE 0:00:00 暂缺``svchost.exe 1432 Services 0 12,664 K Unknown NT AUTHORITY\LOCAL SERVICE 0:00:00 暂缺``svchost.exe 1440 Services 0 10,552 K Unknown NT AUTHORITY\SYSTEM 0:00:00 暂缺
使用语法及参数说明
使用语法
用法:tasklist [/s [/u [] [/p ]]] [{/m | /svc | /v}] [/fo {table | list | csv}] [/nh] [/fi [/fi [ … ]]]
参数说明
/S system 指定连接到的远程系统。``/U [domain]user 指定应该在哪个用户上下文执行这个命令。``/P [password] 为提供的用户上下文指定密码。如果省略,则提示输入。``/M [module] 列出当前使用所给 exe/dll 名称的所有任务。如果没有指定模块名称,显示所有加载的模块。``/SVC 显示每个进程中主持的服务。``/V 显示详述任务信息。``/FI filter 显示一系列符合筛选器指定的标准的任务。``/FO format 指定输出格式。有效值: “TABLE”、“LIST”、“CSV”。``/NH 指定列标题不应该在输出中显示。只对 “TABLE” 和 “CSV” 格式有效。``/? 显示帮助消息。
筛选器说明
黑客&网络安全如何学习
今天只要你给我的文章点赞,我私藏的网安学习资料一样免费共享给你们,来看看有哪些东西。
1.学习路线图
攻击和防守要学的东西也不少,具体要学的东西我都写在了上面的路线图,如果你能学完它们,你去就业和接私活完全没有问题。
2.视频教程
网上虽然也有很多的学习资源,但基本上都残缺不全的,这是我自己录的网安视频教程,上面路线图的每一个知识点,我都有配套的视频讲解。
内容涵盖了网络安全法学习、网络安全运营等保测评、渗透测试基础、漏洞详解、计算机基础知识等,都是网络安全入门必知必会的学习内容。
(都打包成一块的了,不能一一展开,总共300多集)
因篇幅有限,仅展示部分资料,需要点击下方链接即可前往获取
优快云大礼包:《黑客&网络安全入门&进阶学习资源包》免费分享
3.技术文档和电子书
技术文档也是我自己整理的,包括我参加大型网安行动、CTF和挖SRC漏洞的经验和技术要点,电子书也有200多本,由于内容的敏感性,我就不一一展示了。
因篇幅有限,仅展示部分资料,需要点击下方链接即可前往获取
优快云大礼包:《黑客&网络安全入门&进阶学习资源包》免费分享
4.工具包、面试题和源码
“工欲善其事必先利其器”我为大家总结出了最受欢迎的几十款款黑客工具。涉及范围主要集中在 信息收集、Android黑客工具、自动化工具、网络钓鱼等,感兴趣的同学不容错过。
还有我视频里讲的案例源码和对应的工具包,需要的话也可以拿走。
因篇幅有限,仅展示部分资料,需要点击下方链接即可前往获取
优快云大礼包:《黑客&网络安全入门&进阶学习资源包》免费分享
最后就是我这几年整理的网安方面的面试题,如果你是要找网安方面的工作,它们绝对能帮你大忙。
这些题目都是大家在面试深信服、奇安信、腾讯或者其它大厂面试时经常遇到的,如果大家有好的题目或者好的见解欢迎分享。
参考解析:深信服官网、奇安信官网、Freebuf、csdn等
内容特点:条理清晰,含图像化表示更加易懂。
内容概要:包括 内网、操作系统、协议、渗透测试、安服、漏洞、注入、XSS、CSRF、SSRF、文件上传、文件下载、文件包含、XXE、逻辑漏洞、工具、SQLmap、NMAP、BP、MSF…
因篇幅有限,仅展示部分资料,需要点击下方链接即可前往获取