{"id":152,"date":"2022-05-18T13:20:46","date_gmt":"2022-05-18T05:20:46","guid":{"rendered":"http:\/\/162.14.82.114\/?p=152"},"modified":"2022-06-17T23:06:09","modified_gmt":"2022-06-17T15:06:09","slug":"wsl-%e6%90%ad%e5%bb%ba-ubuntu18-04%e7%bb%88%e7%ab%afpwn%e7%8e%af%e5%a2%83","status":"publish","type":"post","link":"http:\/\/162.14.82.114\/index.php\/152\/05\/18\/2022\/","title":{"rendered":"wsl \u642d\u5efa ubuntu18.04\u7ec8\u7aefpwn\u73af\u5883"},"content":{"rendered":"<h1>\u9996\u5148--\u524d\u8a00<\/h1>\n<p>\u4e0b\u8f7d\u7ec8\u7aef\u9884\u89c8\u8f6f\u4ef6\uff0c\u989c\u503c\u9ad8\uff0c\u5728 Microsoft store\u91cc\u4e0b\u8f7d\u5c31\u884c\u4e86\uff0c\u6240\u5e78\u8f6f\u4ef6\u5927\u5c0f\u662f\u53ef\u4ee5\u63a5\u53d7\u8303\u56f4\uff0c\u56e0\u4e3a\u4f1a\u9ed8\u8ba4\u88c5\u5728 C \u76d8\u5185\uff0c\u6309\u7f51\u4e0a\u66f4\u6539\u4e0b\u4e00\u6b21\u8f6f\u4ef6\u5b89\u88c5\u5730\u70b9\u5728\u6211\u7684\u7535\u8111\u4e0a\u662f\u65e0\u6548\u7684\uff0c\u6240\u4ee5\u6211\u6ca1\u6709\u5728 Microsoft store \u4e0b\u8f7d\u5b50\u7cfb\u7edf\uff0c\u5fae\u8f6f\u63d0\u4f9b\u4e86\u624b\u52a8\u4e0b\u8f7d\u5b50\u7cfb\u7edf\u5305\u7684\u65b9\u6cd5\uff0c<a href=\"https:\/\/docs.microsoft.com\/zh-cn\/windows\/wsl\/install-manual\">\u65e7\u7248 WSL \u7684\u624b\u52a8\u5b89\u88c5\u6b65\u9aa4 | Microsoft Docs<\/a>\uff0c\u5728\u4e0a\u9762\u76f4\u63a5\u4e0b\u8f7d<code>.appx<\/code>\u6587\u4ef6\u5373\u53ef\uff0c\u4e0b\u8f7d\u5b8c\u4ee5\u540e\u653e\u5230\u81ea\u5df1\u60f3\u653e\u7684\u6587\u4ef6\u5939\uff0c\u7136\u540e\u4fee\u6539\u540e\u7f00\u540d\u4e3a<code>.zip<\/code>\uff0c\u89e3\u538b\u7f29\u4ee5\u540e\u70b9\u51fb\u5bf9\u5e94\u7684<code>ubuntu.exe<\/code>\u5373\u53ef\u3002<\/p>\n<blockquote>\n<p>\u8fd9\u91cc\u70b9\u4e00\u4e0b\u6700\u57fa\u672c\u7684\u62a5\u9519\uff1a\u6743\u9650\u4e0d\u8db3\uff1a<code>Permission denied<\/code>\uff0c\u4f7f\u7528<code>sudo<\/code>\u6216<code>chmod<\/code>\u8d4b\u4e88\u6743\u9650\u5373\u53ef<\/p>\n<\/blockquote>\n<h1>\u91cd\u590d\u914d\u7f6e\u6613\u9047\u5230\u7684\u95ee\u9898<\/h1>\n<p>\u4e24\u4e2a\u95ee\u9898\uff0c\u4e00\u6837\u7684\u89e3\u51b3\u65b9\u6cd5\uff01\uff01\uff01\uff01<\/p>\n<blockquote>\n<p>\u663e\u793axxxx\u62a5\u9519\uff0c\u7136\u540e\u8f93\u5165\u4e00\u4e2a\u952e\u9000\u51fa\u4e86\uff0c\u597d\u50cf\u6709\u5565\u9519\u8bef\u4ee3\u7801\uff0c\u4ee3\u7801\u662f\u4e00\u4e32\u5730\u5740\uff0c\u540e\u95e8\u662f\u51e0\u4e2a\u95ee\u53f7\u3002<\/p>\n<p>ubuntu.exe \u6253\u5f00\u95ea\u9000<\/p>\n<\/blockquote>\n<pre><code class=\"language-powershell\">\u5229\u7528wsl --list --verbose\u67e5\u770b\u5f53\u524d\u7535\u8111\u4e0a\u5b50\u7cfb\u7edf\u4fe1\u606f\n\u7136\u540e\u770b\u5230\u4e00\u4e2a\u6216\u591a\u4e2a running \u72b6\u6001\u7684 wsl\uff08\u8868\u793a\u914d\u7f6e\u597d\u4e86\uff09\n\u8fd0\u884cwsl --unregister Ubuntu-16.04\uff0c\u8fd9\u91cc\u66f4\u6539\u6210\u4e0a\u9762\u67e5\u5230\u7684\u76f8\u5e94\u7248\u672c\u7684 NAME \u5373\u53ef\uff0c\u5c06\u5176\u6ce8\u9500\uff0c\u7136\u540e\u518d\u8fd0\u884c Ubuntu16.04.exe \u8fdb\u884c\u5b89\u88c5\u5373\u53ef\n\u6210\u529f\u4e4b\u540e\u6253\u5f00\u7ec8\u7aef\u9884\u89c8\uff0c\u627e\u5230 ubuntu \u8fdb\u884c\u6ce8\u518c\u3002<\/code><\/pre>\n<p><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/pic-for-be.oss-cn-hangzhou.aliyuncs.com\/img\/202205181319447.png'><img class=\"lazyload lazyload-style-2\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" data-original=\"https:\/\/pic-for-be.oss-cn-hangzhou.aliyuncs.com\/img\/202205181319447.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"image-20220518021821596\" style=\"zoom:50%;\" \/><\/div><\/p>\n<h1>\u53c2\u8003\u5927\u4f6c\u535a\u5ba2\u8fdb\u884c\u914d\u7f6e<\/h1>\n<p>\u6211\u8fd9\u91cc\u4f7f\u7528\u7684\u662f\u770b\u96ea\u5927\u4f6c\u7684\u535a\u5ba2\uff0c\u5199\u7684\u975e\u5e38\u597d\uff0c\u57fa\u672c\u90fd\u53ef\u4ee5\u914d\u7f6e\u6210\u529f<a href=\"https:\/\/bbs.pediy.com\/thread-257558.htm\">[\u539f\u521b]CTF_Pwn\u73af\u5883\u642d\u5efa-Pwn-\u770b\u96ea\u8bba\u575b-\u5b89\u5168\u793e\u533a|\u5b89\u5168\u62db\u8058|bbs.pediy.com<\/a>\uff0c\u4f46\u6709\u70b9\u5c0f\u95ee\u9898\u4e0b\u9762\u4f1a\u8fdb\u884c\u8bf4\u660e\uff1a<\/p>\n<p>ubuntu18.04 \u7684\u57fa\u7840\u914d\u7f6e\uff1a<\/p>\n<blockquote>\n<p>python3\uff1a3.6.7<\/p>\n<p>vim<\/p>\n<p>git<\/p>\n<\/blockquote>\n<p>\u5b89\u88c5 python2\uff0c\u76f4\u63a5\u8f93\u5165python2\u5373\u53ef\uff0c\u7cfb\u7edf\u4f1a\u81ea\u52a8\u7ed9\u51fa\u4ee3\u7801\uff1a<\/p>\n<pre><code class=\"language-bash\">sudo apt install python-minimal<\/code><\/pre>\n<h2>\u8fd9\u91cc\u51fa\u73b0\u4e86\u4e00\u4e2a\u95ee\u9898\uff0c\u662f\u7531\u4e8eDNS\u672a\u914d\u7f6e\u4ee5\u53ca\u8f6f\u4ef6\u6e90\u914d\u7f6e\u5bfc\u81f4\u7684\u4e0b\u8f7d\u8fdb\u5ea6\u8d3c\u6162\u4ee5\u53ca\u6613\u51fa\u9519<\/h2>\n<p>\u9047\u5230\u542b\u6709\uff1aTemporary failure resolving 'archive.ubuntu.com \u4e4b\u7c7b\u7684<\/p>\n<pre><code class=\"language-bash\">#\u6253\u5f00\u914d\u7f6e\u6587\u4ef6\nsudo vim \/etc\/resolv.conf\n#\u6dfb\u52a0\u76f8\u5173\u89e3\u6790\nnameserver 114.114.114.114\nnameserver 8.8.8.8\n#\u5173\u6389\u91cd\u542f\u590d\u539f\uff0c\u4e0d\u5173\u6389\u4e0b\u6b21\u91cd\u542f\u53c8\u53d8\u6210\u9ed8\u8ba4\u4e86\uff0c\u5728\u8fd9\u4e0a\u9762\u5403\u4e86\u597d\u51e0\u6b21\u82e6\u5934\u4e86\nsudo vim \/etc\/wsl.conf:    #\u6253\u5f00\n[network]                  #\u6dfb\u52a0\ngenerateResolvConf = false\n#\u540e\u6765\u53d1\u73b0\u4e0a\u9762\u7684\u6ca1\u5565\u7528\uff0c\u627e\u5230\u4e86\u8fd9\u6837\u4e00\u6761\u56de\u7b54\n\u7f16\u8f91 \/etc\/systemd\/resolved.conf \u8fd9\u4e2a\u6587\u4ef6\uff0c\u628a DNS \u90a3\u4e00\u884c\u89e3\u5f00\u6ce8\u91ca\n#\u6211\u4e5f\u4e0d\u77e5\u9053\u4e0a\u9762\u6709\u6ca1\u6709\u7528\uff0c\u540e\u6765\u6211\u8fd8\u628a\u6587\u4ef6\u5168\u5220\u6389\u91cd\u65b0\u5efa\u7acb\u8d4b\u4e88777\u6743\u9650\u8bd5\u4e86\u4e00\u4e0b\u3002<\/code><\/pre>\n<p><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/pic-for-be.oss-cn-hangzhou.aliyuncs.com\/img\/202205181319448.png'><img class=\"lazyload lazyload-style-2\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" data-original=\"https:\/\/pic-for-be.oss-cn-hangzhou.aliyuncs.com\/img\/202205181319448.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"image-20220518042542058\" style=\"zoom:33%;\" \/><\/div><\/p>\n<p>ubuntu18.04 \u66f4\u6539\u8bbe\u7f6e\u955c\u50cf\u6e90<\/p>\n<pre><code class=\"language-bash\">#\u5148\u5907\u4efd\u539f\u6765\u7684\u6e90\nsudo cp \/etc\/apt\/sources.list \/etc\/apt\/sources.list.backup\n#\u7136\u540e\u4fee\u6539\u6e90\nsudo vim \/etc\/apt\/sources.list\n#\u6309d\u8fdb\u884c\u5220\u9664\uff0c\u518d\u7c98\u8d34\u4e0b\u5217\u6e90\u5730\u5740\uff1a\n    #\u963f\u91cc\u6e90\n    deb http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic main restricted universe multiverse\n    deb http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic-security main restricted universe multiverse\n    deb http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic-updates main restricted universe multiverse\n    deb http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic-proposed main restricted universe multiverse\n    deb http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic-backports main restricted universe multiverse\n    deb-src http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic main restricted universe multiverse\n    deb-src http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic-security main restricted universe multiverse\n    deb-src http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic-updates main restricted universe multiverse\n    deb-src http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic-proposed main restricted universe multiverse\n    deb-src http:\/\/mirrors.aliyun.com\/ubuntu\/ bionic-backports main restricted universe multiverse\n\n    #\u7f51\u6613\u6e90\n    deb http:\/\/mirrors.163.com\/ubuntu\/ bionic main restricted universe multiverse\n    deb http:\/\/mirrors.163.com\/ubuntu\/ bionic-security main restricted universe multiverse\n    deb http:\/\/mirrors.163.com\/ubuntu\/ bionic-updates main restricted universe multiverse\n    deb http:\/\/mirrors.163.com\/ubuntu\/ bionic-proposed main restricted universe multiverse\n    deb http:\/\/mirrors.163.com\/ubuntu\/ bionic-backports main restricted universe multiverse\n    deb-src http:\/\/mirrors.163.com\/ubuntu\/ bionic main restricted universe multiverse\n    deb-src http:\/\/mirrors.163.com\/ubuntu\/ bionic-security main restricted universe multiverse\n    deb-src http:\/\/mirrors.163.com\/ubuntu\/ bionic-updates main restricted universe multiverse\n    deb-src http:\/\/mirrors.163.com\/ubuntu\/ bionic-proposed main restricted universe multiverse\n    deb-src http:\/\/mirrors.163.com\/ubuntu\/ bionic-backports main restricted universe multiverse\n\n    #\u6e05\u534e\u6e90\n    deb https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic main restricted universe multiverse\n    deb-src https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic main restricted universe multiverse\n    deb https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic-updates main restricted universe multiverse\n    deb-src https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic-updates main restricted universe multiverse\n    deb https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic-backports main restricted universe multiverse\n    deb-src https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic-backports main restricted universe multiverse\n    deb https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic-security main restricted universe multiverse\n    deb-src https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic-security main restricted universe multiverse\n    deb https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic-proposed main restricted universe multiverse\n    deb-src https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\/ bionic-proposed main restricted universe multiverse\n\n    ##\u4e2d\u79d1\u5927\u6e90\n    deb https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic main restricted universe multiverse\n    deb-src https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic main restricted universe multiverse\n    deb https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic-updates main restricted universe multiverse\n    deb-src https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic-updates main restricted universe multiverse\n    deb https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic-backports main restricted universe multiverse\n    deb-src https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic-backports main restricted universe multiverse\n    deb https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic-security main restricted universe multiverse\n    deb-src https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic-security main restricted universe multiverse\n    deb https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic-proposed main restricted universe multiverse\n    deb-src https:\/\/mirrors.ustc.edu.cn\/ubuntu\/ bionic-proposed main restricted universe multiverse\n\n#\u66f4\u65b0\u4e00\u4e0b\nsudo apt-get update\nsudo apt-get upgrade<\/code><\/pre>\n<h3>\u5728\u66f4\u65b0\u7684\u65f6\u5019\u5bb9\u6613\u51fa\u73b0\u62a5\u9519<\/h3>\n<p>E: Could not get lock \/var\/lib\/dpkg\/lock-frontend - open (11: Resource temporarily unavailable)<br \/>\nE: Unable to acquire the dpkg frontend lock (\/var\/lib\/dpkg\/lock-frontend), is another process using it?<\/p>\n<p>\u76f4\u63a5\u5220\u6389\u5c31\u884c\u4e86<\/p>\n<pre><code class=\"language-bash\">sudo rm \/var\/lib\/dpkg\/lock-frontend<\/code><\/pre>\n<p>E: Could not get lock \/var\/lib\/dpkg\/lock - open (11: Resource temporarily unavailable)<br \/>\nE: Unable to lock the administration directory (\/var\/lib\/dpkg\/), is another process using it?<\/p>\n<p>\u518d\u5220<\/p>\n<pre><code class=\"language-bash\">sudo rm \/var\/lib\/dpkg\/lock<\/code><\/pre>\n<p>The following packages were automatically installed and are no longer required:<br \/>\nlibdumbnet1 libfreetype6<br \/>\nUse 'sudo apt autoremove' to remove them.<br \/>\nE: Could not get lock \/var\/cache\/apt\/archives\/lock - open (11: Resource temporarily unavailable)<br \/>\nE: Unable to lock directory \/var\/cache\/apt\/archives\/<\/p>\n<p>\u6309\u7167\u5b83\u7684\u63d0\u793a\u64cd\u4f5c    <\/p>\n<pre><code class=\"language-bash\">sudo apt autoremove<\/code><\/pre>\n<p>E: Could not get lock \/var\/cache\/apt\/archives\/lock - open (11: Resource temporarily unavailable)<br \/>\nE: Unable to lock directory \/var\/cache\/apt\/archives\/<\/p>\n<p>\u4e0d\u8981\u614c\uff0c\u80dc\u5229\u5c31\u5728\u524d\u65b9\uff0c\u7ee7\u7eed\u5220\u9664<\/p>\n<pre><code class=\"language-bash\">sudo rm \/var\/cache\/apt\/archives\/lock<\/code><\/pre>\n<p>\u7136\u540e\u5c31\u53ef\u4ee5\u6b63\u5e38\u8fdb\u884c\u66f4\u65b0\u4e86\uff0c5\u5206\u949f\u4f5c\u7528\u5c31\u53ef\u4ee5\u66f4\u65b0\u4fdd\u5b58\u5b8c\u6bd5\u4e86\uff0c\u518d\u8fdb\u884c\u57fa\u7840\u914d\u4ef6\u7684\u5b89\u88c5\u3002<\/p>\n<h2>\u5b89\u88c5pip<\/h2>\n<pre><code class=\"language-bash\">#\u66f4\u65b0\u8f6f\u4ef6\u5305\u5217\u8868\nsudo apt update\n#\u4e3apython2\u53ca\u5176\u4f9d\u8d56\u5b89\u88c5pip\nsudo apt install python-pip\n#\u67e5\u8be2\u7248\u672c\npip --version\n#\u4e3aPython 3\u5b89\u88c5pip\nsudo apt install python3-pip<\/code><\/pre>\n<h2>\u7ee7\u7eed\u5b89\u88c5 python<\/h2>\n<p>\u76f4\u63a5\u4f7f\u7528\u5b83\u7ed9\u51fa\u6765\u7684\u4e09\u4e2a\u547d\u4ee4<\/p>\n<pre><code class=\"language-bash\">sudo apt install python3\nsudo apt install python\nsudo apt install python-minimal<\/code><\/pre>\n<p>\u8fd9\u91cc\u5f88\u591a\u4eba\u7528\u4e0d\u4e60\u60ef python2\u7684\u8bdd\uff0c\u53ef\u4ee5\u8fdb\u4e00\u6b65\u914d\u7f6e\uff1a<\/p>\n<p><strong>\uff01\uff01\uff01\uff01\uff01\uff01\u6ce8\u610f\uff01\uff01\uff01\u5343\u4e07\u4e0d\u8981\u5c06\u7cfb\u7edf\u81ea\u5e26\u7684python3.6\u73af\u5883\u5378\u8f7d\uff0c\u5426\u5219\u5c06\u9762\u4e34\u5f88\u5927\u7684\u9690\u60a3\uff0c\u53ef\u80fd\u5f97\u50cf\u6211\u4e00\u6837\u91cd\u65b0\u88c5\u7cfb\u7edf\u3002\uff01\uff01\uff01\uff01\uff01\uff01<\/strong><\/p>\n<pre><code class=\"language-bash\">#\u6dfb\u52a0PPA(Personal Package Archive \u4e2a\u4eba\u5305\u6863\u6848)\nsudo add-apt-repository ppa:jonathonf\/python-3.8\n\n#\u68c0\u67e5apt-get\u66f4\u65b0\uff0c\u901a\u8fc7\u8f6f\u94fe\u547d\u4ee4\u5b89\u88c5Python3.8\nsudo apt-get update\nsudo apt-get install python3.8\n\n#\u66f4\u6362\u7cfb\u7edf\u9ed8\u8ba4\u7684\u8f6f\u94fe\u547d\u4ee4\nsudo update-alternatives --install \/usr\/bin\/python3 python3 \/usr\/bin\/python3.6 1\nsudo update-alternatives --install \/usr\/bin\/python3 python3 \/usr\/bin\/python3.8 2\n\n#Python\u7248\u672c\u7684\u5207\u6362\nsudo update-alternatives --config python3\n\n#\u5347\u7ea7\u597dPython\u7248\u672c\u540e\uff0c\u9700\u8981\u5347\u7ea7pip\u547d\u4ee4\u7248\u672c\uff0c\u5426\u5219\u5b89\u88c5\u65f6\u4e5f\u8fd8\u4f1a\u62a5\u9519\npython3 -m pip install --upgrade pip\n==&gt;Successfully installed pip-22.1<\/code><\/pre>\n<h3>\u63a5\u4e0b\u6765\u662f\u8bbe\u7f6epython\u8f6f\u94fe\u63a5<\/h3>\n<pre><code class=\"language-bash\">#\u67e5\u770b\u5f53\u524d\u7cfb\u7edf\u9ed8\u8ba4python\u7248\u672c\npython --version\n#\u67e5\u770bpython3\nwhereis python3\n#\u5220\u9664\u539f\u6709python2\u7684\u8f6f\u8fde\u63a5\nsudo rm \/usr\/bin\/python\n#\u65b0\u5efapython3\u7684\u8f6f\u8fde\u63a5\nsudo ln -s \/usr\/bin\/python3.8 \/usr\/bin\/python\n#\u91cd\u65b0\u67e5\u770b\u9ed8\u8ba4\u7684python\u7248\u672c\npython --version<\/code><\/pre>\n<h1>\u5b89\u88c5pwntools<\/h1>\n<p>\u535a\u5ba2\u4e0a\u662fpython2\u7248\u672c\u7684\uff0c\u6211\u4eec\u4f7f\u7528python3\uff0c\u76f4\u63a5\u4e0apwntools\u6587\u6863\u4e0a\u67e5\u770b\u4e0b\u4e0b\u8f7d\u65b9\u5f0f\uff1a<\/p>\n<pre><code class=\"language-bash\">apt-get update\napt-get install python3 python3-pip python3-dev git libssl-dev libffi-dev build-essential\npython3 -m pip install --upgrade pip\npython3 -m pip install --upgrade pwntools<\/code><\/pre>\n<h2>\u5728\u66f4\u65b0\u7684\u65f6\u5019\u53c8\u62a5\u9519\u4e86<\/h2>\n<blockquote>\n<p>Traceback (most recent call last):<br \/>\nFile &quot;\/usr\/lib\/cnf-update-db&quot;, line 8, in <module><br \/>\nfrom CommandNotFound.db.creator import DbCreator<br \/>\nFile &quot;\/usr\/lib\/python3\/dist-packages\/CommandNotFound\/db\/creator.py&quot;, line 11, in <module><br \/>\nimport apt_pkg<br \/>\nModuleNotFoundError: No module named 'apt_pkg'<br \/>\nReading package lists... Done<br \/>\nE: Problem executing scripts APT::Update::Post-Invoke-Success 'if \/usr\/bin\/test -w \/var\/lib\/command-not-found\/ -a -e \/usr\/lib\/cnf-update-db; then \/usr\/lib\/cnf-update-db &gt; \/dev\/null; fi'<br \/>\nE: Sub-process returned an error code<\/p>\n<\/blockquote>\n<p>\u89e3\u51b3\u65b9\u6cd5\uff1a<\/p>\n<pre><code class=\"language-bash\"># \u521b\u5efa\u4e00\u4e2a\u8f6f\u94fe\u63a5\ncd \/usr\/lib\/python3\/dist-packages\nsudo ln -s apt_pkg.cpython-36m-x86_64-linux-gnu.so apt_pkg.so<\/code><\/pre>\n<p>\u5207\u6362\u4e86\u56fd\u5185\u6e90\u7684\u8bdd\u901f\u5ea6\u4f1a\u975e\u5e38\u5feb\uff01\uff01<\/p>\n<h2>\u5b89\u88c5pwntools\u6700\u540e\u4e00\u6b65\u53c8\u62a5\u9519\u4e86<\/h2>\n<blockquote>\n<p>distutils.errors.DistutilsExecError: command 'x86_64-linux-gnu-gcc' failed with exit status 1<\/p>\n<\/blockquote>\n<p>\u5927\u6982\u662f\u56e0\u4e3a\u6a21\u5757\u5bf9\u7cfb\u7edf\u5e93\u7684\u4f9d\u8d56\u6709\u95ee\u9898\uff0c\u53ef\u4ee5\u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\u66f4\u65b0\uff1a<\/p>\n<pre><code class=\"language-bash\">sudo apt-get update\nsudo apt-get install libffi-dev g++ libssl-dev<\/code><\/pre>\n<p>\u7136\u540e\uff1a<\/p>\n<blockquote>\n<p>The following packages were automatically installed and are no longer required:<br \/>\nlibdumbnet1 libfreetype6<br \/>\nUse 'sudo apt autoremove' to remove them.<\/p>\n<\/blockquote>\n<pre><code class=\"language-bash\">sudo apt autoremove<\/code><\/pre>\n<p>\u7136\u800c\u5e76\u6ca1\u6709\u4ec0\u4e48\u7528\uff0c\u91cd\u65b0\u5b89\u88c5pwntools\u7684\u65f6\u5019\u8fd8\u662f\u62a5\u9519\u4e86\uff0c\u7f51\u4e0a\u8bf4\u662f\u4f9d\u8d56\u6ca1\u6709\u88c5\u5168\uff0c\u518d\u88c5\u4e00\u4e0b\u8bd5\u8bd5\uff1a<\/p>\n<pre><code class=\"language-bash\">sudo apt-get install build-essential python3-dev libssl-dev libffi-dev libxml2 libxml2-dev libxslt1-dev zlib1g-dev<\/code><\/pre>\n<p>\u7136\u540e\u8fdb\u884c\u5b89\u88c5\u5c31\u6210\u529f\u4e86\uff0c\u867d\u7136\u6709WARNING\uff0c\u4f46\u662f\u8fd9\u4e2a\u4e1c\u897f\u7ea6\u7b49\u4e8e\u6ca1\u9519\u3002<\/p>\n<h2>\u68c0\u9a8c\u662f\u5426\u5b89\u88c5\u6210\u529f<\/h2>\n<p>\u6253\u5f00 python\uff0c\u8f93\u5165<code>from pwn import *<\/code>\u770b\u770b\u662f\u5426\u6709\u62a5\u9519\u5373\u53ef\u3002<\/p>\n<h1>gdb<\/h1>\n<h2>gdb\u5b89\u88c5<\/h2>\n<p>\u76f4\u63a5\u8f93\u5165gdb\u770b\u770b\u6709\u6ca1\u6709\u5b89\u88c5\uff0c\u53d1\u73b0\u6ca1\u6709\u5e76\u7ed9\u51fa\u4e86\u5b89\u88c5\u547d\u4ee4<\/p>\n<pre><code class=\"language-bash\">sudo apt install gdb<\/code><\/pre>\n<p>\u518d\u6b21gdb\u8bd5\u8bd5\uff0c\u53d1\u73b0\u6210\u529f\uff01<\/p>\n<h2>peda\/pwngdb\/gef<\/h2>\n<p>\u8fd9\u662f\u5e38\u89c1\u7684gdb\u7684\u4e09\u4e2a\u63d2\u4ef6\uff0c\u914d\u5408gdb\u4f7f\u7528\u53ef\u4ee5\u63d0\u5347\u8c03\u8bd5\u6548\u7387\u3002<\/p>\n<h3>pwndbg<\/h3>\n<pre><code class=\"language-bash\">git clone https:\/\/github.com\/pwndbg\/pwndbg\ncd pwndbg\n.\/setup.sh<\/code><\/pre>\n<h3>peda<\/h3>\n<pre><code class=\"language-bash\">git clone https:\/\/github.com\/longld\/peda.git ~\/peda\necho &quot;source ~\/peda\/peda.py&quot; &gt;&gt; ~\/.gdbinit\necho &quot;DONE! debug your program with gdb and enjoy&quot;<\/code><\/pre>\n<h3>gef<\/h3>\n<pre><code class=\"language-bash\">\u65b9\u6cd5\u4e00\uff1a\nwget -q -O- https:\/\/github.com\/hugsy\/gef\/raw\/master\/gef.sh | sh\n\u65b9\u6cd5\u4e8c\uff1a\nwget -q -O ~\/.gdbinit-gef.py https:\/\/github.com\/hugsy\/gef\/raw\/master\/gef.py\necho source ~\/.gdbinit-gef.py &gt;&gt; ~\/.gdbinit\n\u5907\u7528\u65b9\u6cd5\uff1a\nwget -q -O &quot;$HOME\/.gdbinit-gef.py&quot; https:\/\/github.com\/hugsy\/gef\/raw\/master\/gef.py\ntest -f &quot;$HOME\/.gdbinit&quot; &amp;&amp; mv &quot;$HOME\/.gdbinit&quot; &quot;$HOME\/.gdbinit.old&quot;\necho &quot;source $HOME\/.gdbinit-gef.py&quot; &gt; &quot;$HOME\/.gdbinit&quot;<\/code><\/pre>\n<p>\u56e0\u4e3a\u5728\u540c\u4e00\u65f6\u523b\u53ea\u80fd\u4f7f\u7528\u4e00\u79cd\u63d2\u4ef6\uff0c\u800c\u4e14\u5728\u89e3\u51b3\u4e0d\u540c\u7c7b\u578b\u7684\u9898\u76ee\u65f6\u4f7f\u7528\u4e0d\u540c\u7684\u63d2\u4ef6\uff0c\u56e0\u6b64\u9700\u8981\u914d\u7f6e\u4e09\u79cd\u63d2\u4ef6\u7684\u5feb\u6377\u5207\u6362\u3002<a href=\"https:\/\/blog.csdn.net\/aptx4869_li\">aptx4869_li<\/a>\u5e08\u5085\u7ed9\u51fa\u4e86\u4e00\u6b3e GDB \u63a7\u5236\u63d2\u4ef6\uff0c\u5728\u8fd9\u4e4b\u524d\u6ce8\u91ca\u6389<code>.gdbinit<\/code>\u6587\u4ef6\uff1a<\/p>\n<pre><code class=\"language-bash\">vim ~\/.gdbinit\n#\u628a\u539f\u672c\u7684 source \u6ce8\u91ca\u6389\uff0c\u73b0\u5728\u7684\u72b6\u6001\u662f\u6ca1\u6709\u9009\u62e9\u63d2\u4ef6\u3002\n#\u52a0\u4e00\u4e2a\u53ef\u4ee5\u8bc6\u522b\u7684\u5b57\u7b26\u4e32\uff0c\u968f\u4fbf\u5565\u90fd\u884c\uff0c\u505a\u4e2a\u6807\u5fd7\u800c\u5df2\n# this place is controled by user&#039;s shell<\/code><\/pre>\n<p>\u4e0b\u9762\u5c31\u662f\u63a7\u5236\u811a\u672c\uff1a<\/p>\n<pre><code class=\"language-bash\">#!\/bin\/bash\nfunction Mode_change {\n    name=$1\n    gdbinitfile=~\/.gdbinit    #\u8fd9\u4e2a\u8def\u5f84\u6309\u7167\u4f60\u7684\u5b9e\u9645\u60c5\u51b5\u4fee\u6539\n    # gdbinitfile=\/root\/Desktop\/mode\n\n    peda=&quot;source ~\/peda\/peda.py&quot;   #\u8fd9\u4e2a\u8def\u5f84\u6309\u7167\u4f60\u7684\u5b9e\u9645\u60c5\u51b5\u4fee\u6539\n    gef=&quot;source ~\/.gdbinit-gef.py&quot;   #\u8fd9\u4e2a\u8def\u5f84\u6309\u7167\u4f60\u7684\u5b9e\u9645\u60c5\u51b5\u4fee\u6539\n    pwndbg=&quot;source ~\/pwndbg\/gdbinit.py&quot;   #\u8fd9\u4e2a\u8def\u5f84\u6309\u7167\u4f60\u7684\u5b9e\u9645\u60c5\u51b5\u4fee\u6539\n\n    sign=$(cat $gdbinitfile | grep -n &quot;#this place is controled by user&#039;s shell&quot;)     \n           #\u6b64\u5904\u4e0a\u9762\u7684\u67e5\u627e\u5185\u5bb9\u8981\u548c\u4f60\u81ea\u5df1\u7684\u4fdd\u6301\u4e00\u81f4\n\n    pattern=&quot;:#this place is controled by user&#039;s shell&quot;\n    number=${sign%$pattern}\n    location=$[number+2]\n\n    parameter_add=${location}i\n    parameter_del=${location}d\n\n    message=&quot;TEST&quot;\n\n    if [ $name -eq &quot;1&quot; ];then\n        sed -i &quot;$parameter_del&quot; $gdbinitfile\n        sed -i &quot;$parameter_add $peda&quot; $gdbinitfile\n        echo -e &quot;Please enjoy the peda!\\n&quot;\n    elif [ $name -eq &quot;2&quot; ];then\n        sed -i &quot;$parameter_del&quot; $gdbinitfile\n        sed -i &quot;$parameter_add $gef&quot; $gdbinitfile\n        echo -e &quot;Please enjoy the gef!\\n&quot;\n    elif [ $name -eq &quot;3&quot; ];then\n        sed -i &quot;$parameter_del&quot; $gdbinitfile\n        sed -i &quot;$parameter_add $pwndbg&quot; $gdbinitfile\n        echo -e &quot;Please enjoy the pwndbg!\\n&quot;\n    else\n        sed -i &quot;$parameter_del&quot; $gdbinitfile\n    echo -e &quot;Please enjoy pure gdb!&quot;\n    fi\n\n}\n\necho -e &quot;Please choose one mode of GDB?\\n1.peda    2.gef    3.pwndbg   4.pure_gdb&quot;\n\nread -p &quot;Input your choice:&quot; num\n\nif [ $num -eq &quot;1&quot; ];then\n    Mode_change $num\nelif [ $num -eq &quot;2&quot; ];then\n    Mode_change $num\nelif [ $num -eq &quot;3&quot; ];then\n    Mode_change $num\nelif [ $num -eq &quot;4&quot; ];then\n    Mode_change $num\nelse\n    echo -e &quot;Error!\\nPleasse input right number!&quot;\nfi\n\ngdb $1 $2 $3 $4 $5 $6 $7 $8 $9\n<\/code><\/pre>\n<p>\u8fd8\u6709\u5b89\u88c5\u65b9\u6cd5\uff1a<\/p>\n<pre><code class=\"language-bash\">echo $PATH\n# \u627e\u4e00\u4e2a\u7cfb\u7edf\u53d8\u91cf\u6307\u5411\u7684\u8def\u5f84\u5373\u53ef,\u6211\u8fd9\u91cc\u662f\/usr\/local\/sbin\ncd \/usr\/local\/sbin\n# \u5b89\u4e00\u4e2a\u6587\u4ef6\nsudo touch gdb.sh\n# \u8d4b\u4e88\u6743\u9650\nsudo chmod -R 777 gdb.sh\n# \u5c06\u811a\u672c\u653e\u8fdb\u53bb\u5373\u53ef\nvim gdb.sh\nctrl + v<\/code><\/pre>\n<h3>\u5982\u679c\u4e4b\u540e\u4f7f\u7528\u4e0d\u4e86\uff0c\u5c06.gdbinit\u7167\u4e0b\u5217\u8bbe\u8ba1<\/h3>\n<pre><code class=\"language-bash\">#.gdbinit\nset disassembly intel\n#this place is controled by user&#039;s shell\n#source ~\/peda\/peda.py\n#source \/home\/hack\/.gdbinit-gef.py\n#source ~\/pwndbg\/gdbinit.py<\/code><\/pre>\n<p>\u8981\u7528\u54ea\u4e2a\u5c31\u628a\u54ea\u4e2a\u524d\u9762\u7684\u6ce8\u91ca\u7b26\u53f7\u53bb\u6389\u5c31\u884c\u3002<\/p>\n<p>\u5f88\u795e\u5947\u7684\u4e8b\u60c5\uff0c\u6709\u5929\u665a\u4e0a\u53d1\u73b0\u4e0a\u9762\u7684\u811a\u672c\u4f7f\u7528\u4e0d\u4e86\u641e\u4e86\u4e24\u4e2a\u591a\u5c0f\u65f6\u90fd\u65e0\u6d4e\u4e8e\u4e8b\uff0c\u51c6\u5907\u653e\u5f03\u4e86\uff0c\u7136\u540e\u5c06<code>.gdbinit<\/code>\u7167\u4e0a\u9762\u6539\u5b8c\u4ee5\u540e\u7a81\u7136\u53c8\u53ef\u4ee5\u7528\u4e86\u3002\u3002\u3002<\/p>\n<pre><code class=\"language-bash\">hack@QC-20210627LTVJ:~$ gdb.sh\nPlease choose one mode of GDB?\n1.peda    2.gef    3.pwndbg\nInput your choice:1\nPlease enjoy the peda!\n\nGNU gdb (Ubuntu 8.1.1-0ubuntu1) 8.1.1\nCopyright (C) 2018 Free Software Foundation, Inc.\nLicense GPLv3+: GNU GPL version 3 or later &lt;http:\/\/gnu.org\/licenses\/gpl.html&gt;\nThis is free software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitted by law.  Type &quot;show copying&quot;\nand &quot;show warranty&quot; for details.\nThis GDB was configured as &quot;x86_64-linux-gnu&quot;.\nType &quot;show configuration&quot; for configuration details.\nFor bug reporting instructions, please see:\n&lt;http:\/\/www.gnu.org\/software\/gdb\/bugs\/&gt;.\nFind the GDB manual and other documentation resources online at:\n&lt;http:\/\/www.gnu.org\/software\/gdb\/documentation\/&gt;.\nFor help, type &quot;help&quot;.\nType &quot;apropos word&quot; to search for commands related to &quot;word&quot;.\ngdb-peda$\n[5]+  Stopped                 gdb.sh\nhack@QC-20210627LTVJ:~$ gdb.sh\nPlease choose one mode of GDB?\n1.peda    2.gef    3.pwndbg\nInput your choice:2\nPlease enjoy the gef!\n\nGNU gdb (Ubuntu 8.1.1-0ubuntu1) 8.1.1\nCopyright (C) 2018 Free Software Foundation, Inc.\nLicense GPLv3+: GNU GPL version 3 or later &lt;http:\/\/gnu.org\/licenses\/gpl.html&gt;\nThis is free software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitted by law.  Type &quot;show copying&quot;\nand &quot;show warranty&quot; for details.\nThis GDB was configured as &quot;x86_64-linux-gnu&quot;.\nType &quot;show configuration&quot; for configuration details.\nFor bug reporting instructions, please see:\n&lt;http:\/\/www.gnu.org\/software\/gdb\/bugs\/&gt;.\nFind the GDB manual and other documentation resources online at:\n&lt;http:\/\/www.gnu.org\/software\/gdb\/documentation\/&gt;.\nFor help, type &quot;help&quot;.\nType &quot;apropos word&quot; to search for commands related to &quot;word&quot;.\nGEF for linux ready, type `gef&#039; to start, `gef config&#039; to configure\n93 commands loaded for GDB 8.1.1 using Python engine 3.6\n[*] 3 commands could not be loaded, run `gef missing` to know why.\ngef\u27a4\n[6]+  Stopped                 gdb.sh\nhack@QC-20210627LTVJ:~$ gdb.sh\nPlease choose one mode of GDB?\n1.peda    2.gef    3.pwndbg\nInput your choice:3\nPlease enjoy the pwndbg!\n\nGNU gdb (Ubuntu 8.1.1-0ubuntu1) 8.1.1\nCopyright (C) 2018 Free Software Foundation, Inc.\nLicense GPLv3+: GNU GPL version 3 or later &lt;http:\/\/gnu.org\/licenses\/gpl.html&gt;\nThis is free software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitted by law.  Type &quot;show copying&quot;\nand &quot;show warranty&quot; for details.\nThis GDB was configured as &quot;x86_64-linux-gnu&quot;.\nType &quot;show configuration&quot; for configuration details.\nFor bug reporting instructions, please see:\n&lt;http:\/\/www.gnu.org\/software\/gdb\/bugs\/&gt;.\nFind the GDB manual and other documentation resources online at:\n&lt;http:\/\/www.gnu.org\/software\/gdb\/documentation\/&gt;.\nFor help, type &quot;help&quot;.\nType &quot;apropos word&quot; to search for commands related to &quot;word&quot;.\npwndbg: loaded 198 commands. Type pwndbg [filter] for a list.\npwndbg: created $rebase, $ida gdb functions (can be used with print\/break)\npwndbg&gt;\n[7]+  Stopped                 gdb.sh<\/code><\/pre>\n<h2>\u62a5\u9519<\/h2>\n<blockquote>\n<p>Cloning into 'pwndbg'...<br \/>\nfatal: unable to access '<a href=\"https:\/\/github.com\/pwndbg\/pwndbg\/\">https:\/\/github.com\/pwndbg\/pwndbg\/<\/a>': Could not resolve host: github.com<\/p>\n<\/blockquote>\n<p>\u5c31\u662f\u7f51\u7edc\u9519\u8bef\uff0c\u56fd\u5185\u5bf9github\u7684\u8bbf\u95ee\u592a\u6162\u4e86\uff0c\u79d1\u5b66\u4e0a\u7f51\u8fdb\u884c\u514b\u9686\u3002\u8fd9\u8fb9\u6211\u778e\u914d\u7f6e\u4e00\u6bb5\u65f6\u95f4\u540e\u9519\u8bef\uff0c\u770b\u5230\u7f51\u4e0a\u7684\u6587\u7ae0\u81ea\u68c0\u51fa\u6765\u4e86\uff1a<\/p>\n<blockquote>\n<p>1\u3001\u770b\u770b\u4f60\u7684git\u914d\u7f6e<br \/>\n<code>git config --global -l<\/code><\/p>\n<p>\u5982\u679c\u6709\uff0c\u5c06\u5176\u4ece<code>~\/.gitconfig<\/code>\u6587\u4ef6\u4e2d\u5220\u9664\uff0c\u7136\u540e\u91cd\u8bd5\u3002<\/p>\n<p>\u53d6\u6d88\u8bbe\u7f6e\u73af\u5883\u53d8\u91cf<br \/>\n<code>env|grep -i proxy<\/code><\/p>\n<\/blockquote>\n<p>\u9047\u5230\u4e0b\u9762\u62a5\u9519\u4e5f\u522b\u614c\uff0c\u662f\u7f51\u901f\u539f\u56e0\uff1a<\/p>\n<blockquote>\n<p>Cloning into 'ROPgadget'...<br \/>\nfatal: unable to access '<a href=\"https:\/\/github.com\/JonathanSalwan\/ROPgadget.git\/\">https:\/\/github.com\/JonathanSalwan\/ROPgadget.git\/<\/a>': gnutls_handshake() failed: The TLS connection was non-properly terminated.<\/p>\n<\/blockquote>\n<p>\u591a\u5c1d\u8bd5\u51e0\u904d\u5c31\u884c\u4e86\u3002<\/p>\n<h1>32\u4f4d\u7a0b\u5e8f\u652f\u6301<\/h1>\n<p>\u5fc5\u88c5\u7684\uff0c\u4e0d\u7136\u7b49\u4f60\u78b0\u5230<code>ELF.32bit<\/code>\u8fd0\u884c\u4e0d\u51fa\u6765\u7684\u65f6\u5019\u6709\u4f60\u50bb\u773c\u7684\uff1a<\/p>\n<pre><code class=\"language-bash\">apt-get install libc6-dev-i386<\/code><\/pre>\n<h1>arm\u7684pwn\u73af\u5883qemu<\/h1>\n<pre><code class=\"language-bash\">sudo apt-get install qemu\nsudo apt-get install qemu-system qemu-user-static binfmt-support<\/code><\/pre>\n<p>\u5b89\u88c5\u4f9d\u8d56\uff1a<\/p>\n<pre><code class=\"language-bash\">sudo apt-get install -y gcc-arm-linux-gnueabi\nsudo apt-get install qemu libncurses5-dev gcc-arm-linux-gnueabi build-essential gdb-arm-none-eabi synaptic gcc-aarch64-linux-gnu eclipse-cdt git<\/code><\/pre>\n<h1>LibcSearcher<\/h1>\n<p>\u6cc4\u9732libc\u5e93\u4e2d\u51fd\u6570\u7684\u504f\u79fb\u7684\u5e93\uff0c\u5efa\u8bae\u5b89\u88c5\uff0c\u53ef\u4ee5\u8282\u7701\u65f6\u95f4\uff0c\u63d0\u9ad8\u6548\u7387\u3002<\/p>\n<pre><code class=\"language-bash\">sudo pip install capstone\ngit clone https:\/\/github.com\/lieanu\/LibcSearcher.git\ncd LibcSearcher\npython setup.py develop<\/code><\/pre>\n<h1>ROPgadget\u548cone_gadget<\/h1>\n<p>ROPgadget\u662f\u7528\u6765\u627egadget\u7684\uff0cone_gadget\u7528\u6765\u5bfb\u627elibc\u5e93\u4e2d\u7684execve('\/bin\/sh', NULL, NULL)\u53ef\u4ee5\u4e00\u4e2agadget\u5c31\u53ef\u4ee5getshell\uff0c\u5efa\u8bae\u5b89\u88c5\u3002<\/p>\n<pre><code># \u5148\u5b89\u88c5Capstone,\u5b83\u662f\u4e00\u4e2a\u8f7b\u91cf\u7ea7\u7684\u591a\u5e73\u53f0\u67b6\u6784\u652f\u6301\u7684\u53cd\u6c47\u7f16\u67b6\u6784\u3002\nsudo apt-get install python-capstone\n\n#\u5b89\u88c5ROPgadget\ngit clone https:\/\/github.com\/JonathanSalwan\/ROPgadget.git\n\n#\u8fdb\u5165\ncd ROPgadget\n\n# \u4e0b\u8f7d\u597dROPgadget\u89e3\u538b\uff0c\u5e76\u8fdb\u5165\u6587\u4ef6\u5939\u4e2d\npython setup.py install\n\n#\u5b89\u88c5one_gadget\nsudo apt install ruby\ngem install one_gadget<\/code><\/pre>\n<p>\u6700\u540e\uff1a<\/p>\n<pre><code class=\"language-bash\">sudo apt-get update\nsudo apt-get upgrade<\/code><\/pre>\n<p>\u4ee5\u4e0a\u5c31\u662f<code>wsl\u4e0bubuntu18.04LTS\u7684pwn<\/code>\u73af\u5883\u914d\u7f6e\u7ec6\u8282\uff0c\u611f\u8c22\u89c2\u770b\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u9996\u5148&#8211;\u524d\u8a00 \u4e0b\u8f7d\u7ec8\u7aef\u9884\u89c8\u8f6f\u4ef6\uff0c\u989c\u503c\u9ad8\uff0c\u5728 Microsoft store\u91cc\u4e0b\u8f7d\u5c31\u884c\u4e86\uff0c\u6240\u5e78\u8f6f\u4ef6\u5927\u5c0f\u662f\u53ef\u4ee5\u63a5\u53d7 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":132,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-152","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-3"],"_links":{"self":[{"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/posts\/152","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/comments?post=152"}],"version-history":[{"count":6,"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/posts\/152\/revisions"}],"predecessor-version":[{"id":187,"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/posts\/152\/revisions\/187"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/media\/132"}],"wp:attachment":[{"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/media?parent=152"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/categories?post=152"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/162.14.82.114\/index.php\/wp-json\/wp\/v2\/tags?post=152"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}