WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager, possibly rendering your system unusable. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv. Use the --root-user-action option if you know what you are doing and want to suppress this warning.
以root身份使用pip3会报如上warning,由于不打算用python做大型项目,选择忽略.
简单检查一下
1 2 3 4 5 6 7 8 9
root@PainTech:/home/pwn# cyclic 100 aaaabaaacaaadaaaeaaafaaagaaahaaaiaaajaaakaaalaaamaaanaaaoaaapaaaqaaaraaasaaataaauaaavaaawaaaxaaayaaa root@PainTech:/home/pwn# checksec usage: pwn checksec [-h] [--file [elf ...]] [elf ...] root@PainTech:/home/pwn# python3 Python 3.10.12 (main, Jul 29 2024, 16:56:48) [GCC 11.4.0] on linux Type "help", "copyright", "credits" or "license"for more information. >>> from pwn import * >>> exit()
# 示范一下如何安装使用 $ git clone https://github.com/matrix1001/glibc-all-in-one.git $ pushd glibc-all-in-one $ python3 update_list [+] Common list has been save to "list" [+] Old-release list has been save to "old_list" $ cat list 2.23-0ubuntu11.3_amd64 2.23-0ubuntu11.3_i386 2.23-0ubuntu3_amd64 2.23-0ubuntu3_i386 2.27-3ubuntu1.5_amd64 2.27-3ubuntu1.5_i386 2.27-3ubuntu1.6_amd64 2.27-3ubuntu1.6_i386 2.27-3ubuntu1_amd64 2.27-3ubuntu1_i386 # i386是32位,amd64是64位 $ ./download 2.23-0ubuntu11.3_amd64 $ ls libs 2.23-0ubuntu11.3_amd64
$ git clone https://github.com/pwndbg/pwndbg $ pusd pwndbg $ ./setup.sh sudo: /etc/sudo.conf is world writable sudo: /etc/sudo.conf is world writable sudo: error in /etc/sudo.conf, line 0 while loading plugin "sudoers_policy" sudo: /usr/libexec/sudo/sudoers.so must be only be writable by owner sudo: fatal error, unable to load plugins sudo: /etc/sudo.conf is world writable sudo: /etc/sudo.conf is world writable sudo: error in /etc/sudo.conf, line 0 while loading plugin "sudoers_policy" sudo: /usr/libexec/sudo/sudoers.so must be only be writable by owner sudo: fatal error, unable to load plugins
这里报错是因为sh脚本中有sudo,需要修改一下脚本
(1)7-11行 和 155-159行,注释掉
(2)查找所有sudo,然后全部删除
init完成后提示
1
[*] Added 'source /home/pwn/pwndbg/gdbinit.py' to ~/.gdbinit so that Pwndbg will be loaded on every launch of GDB.