HackMyVM-Slackware

news2024/10/6 2:17:50


目录

信息收集

arp-scan

nmap

nikto

whatweb

WEB

web信息收集

gobuster

wfuzz

hydra

ssh连接

提权

系统信息收集

get root

信息收集

arp-scan
┌──(root㉿0x00)-[~/HackMyVM]
└─# arp-scan -l
Interface: eth0, type: EN10MB, MAC: 08:00:27:9d:6d:7b, IPv4: 192.168.9.150
Starting arp-scan 1.10.0 with 256 hosts (https://github.com/royhills/arp-scan)

192.168.9.160   08:00:27:42:9b:78       PCS Systemtechnik GmbH


1 packets received by filter, 0 packets dropped by kernel
Ending arp-scan 1.10.0: 256 hosts scanned in 2.073 seconds (123.49 hosts/sec). 8 responded


nmap
端口信息扫描

┌──(root㉿0x00)-[~/HackMyVM]
└─# nmap -p- 192.168.9.160 --min-rate 10000 -oA ports
Starting Nmap 7.94 ( https://nmap.org ) at 2024-04-28 12:49 CST
Stats: 0:00:03 elapsed; 0 hosts completed (1 up), 1 undergoing SYN Stealth Scan
SYN Stealth Scan Timing: About 35.39% done; ETC: 12:49 (0:00:05 remaining)
Nmap scan report for 192.168.9.160
Host is up (0.00052s latency).
Not shown: 65533 closed tcp ports (reset)
PORT  STATE SERVICE
1/tcp open  tcpmux
2/tcp open  compressnet
MAC Address: 08:00:27:42:9B:78 (Oracle VirtualBox virtual NIC)

Nmap done: 1 IP address (1 host up) scanned in 14.29 seconds

版本服务信息扫描

┌──(root㉿0x00)-[~/HackMyVM]
└─# nmap -sC -sV -O -p 1,2 192.168.9.160 --min-rate 10000      
Starting Nmap 7.94 ( https://nmap.org ) at 2024-04-28 12:50 CST
Nmap scan report for 192.168.9.160
Host is up (0.00051s latency).

PORT  STATE SERVICE VERSION
1/tcp open  ssh     OpenSSH 9.3 (protocol 2.0)
| ssh-hostkey: 
|   256 e2:66:60:79:bc:d1:33:2e:c1:25:fa:99:e5:89:1e:d3 (ECDSA)
|_  256 98:59:c3:a8:2b:89:56:77:eb:72:4a:05:90:21:cb:40 (ED25519)
2/tcp open  http    Apache httpd 2.4.58 ((Unix))
| http-methods: 
|_  Potentially risky methods: TRACE
|_http-title: Tribute to Slackware
|_http-server-header: Apache/2.4.58 (Unix)
MAC Address: 08:00:27:42:9B:78 (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

OS and Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
Nmap done: 1 IP address (1 host up) scanned in 12.85 seconds

端口好奇怪!1端口是ssh服务,2端口是http服务!


nikto
┌──(root㉿0x00)-[~/HackMyVM]
└─# nikto -h 192.168.9.160:2                             
- Nikto v2.5.0
---------------------------------------------------------------------------
+ Target IP:          192.168.9.160
+ Target Hostname:    192.168.9.160
+ Target Port:        2
+ Start Time:         2024-04-28 12:53:59 (GMT8)
---------------------------------------------------------------------------
+ Server: Apache/2.4.58 (Unix)
+ /: 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)
+ OPTIONS: Allowed HTTP Methods: POST, OPTIONS, HEAD, GET, TRACE .
+ /: HTTP TRACE method is active which suggests the host is vulnerable to XST. See: https://owasp.org/www-community/attacks/Cross_Site_Tracing
+ 8101 requests: 0 error(s) and 4 item(s) reported on remote host
+ End Time:           2024-04-28 12:54:18 (GMT8) (19 seconds)
---------------------------------------------------------------------------
+ 1 host(s) tested


      *********************************************************************
      Portions of the server's headers (Apache/2.4.58) are not in
      the Nikto 2.5.0 database or are newer than the known string. Would you like
      to submit this information (*no server specific data*) to CIRT.net
      for a Nikto update (or you may email to sullo@cirt.net) (y/n)? y

+ ERROR:  -> 
+ ERROR: Update failed, please notify sullo@cirt.net of the previous line.


whatweb
┌──(root㉿0x00)-[~/HackMyVM]
└─# whatweb -v http://192.168.9.160:2/                                           
WhatWeb report for http://192.168.9.160:2/
Status    : 200 OK
Title     : ,Tribute to Slackware
IP        : 192.168.9.160
Country   : RESERVED, ZZ

Summary   : Apache[2.4.58], HTTPServer[Unix][Apache/2.4.58 (Unix)]

Detected Plugins:
[ Apache ]
        The Apache HTTP Server Project is an effort to develop and 
        maintain an open-source HTTP server for modern operating 
        systems including UNIX and Windows NT. The goal of this 
        project is to provide a secure, efficient and extensible 
        server that provides HTTP services in sync with the current 
        HTTP standards. 

        Version      : 2.4.58 (from HTTP Server Header)
        Google Dorks: (3)
        Website     : http://httpd.apache.org/

[ HTTPServer ]
        HTTP server header string. This plugin also attempts to 
        identify the operating system from the server header. 

        OS           : Unix
        String       : Apache/2.4.58 (Unix) (from server string)

HTTP Headers:
        HTTP/1.1 200 OK
        Date: Sun, 28 Apr 2024 02:54:45 GMT
        Server: Apache/2.4.58 (Unix)
        Last-Modified: Sun, 10 Mar 2024 19:03:14 GMT
        ETag: "1d57-6135313b36080"
        Accept-Ranges: bytes
        Content-Length: 7511
        Connection: close
        Content-Type: text/html


WEB

web信息收集


gobuster
┌──(root㉿0x00)-[~/HackMyVM]
└─# gobuster dir -u http://192.168.9.160:2 -w /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt 
===============================================================
Gobuster v3.6
by OJ Reeves (@TheColonial) & Christian Mehlmauer (@firefart)
===============================================================
[+] Url:                     http://192.168.9.160:2
[+] Method:                  GET
[+] Threads:                 10
[+] Wordlist:                /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt
[+] Negative Status codes:   404
[+] User Agent:              gobuster/3.6
[+] Timeout:                 10s
===============================================================
Starting gobuster in directory enumeration mode
===============================================================
/getslack             (Status: 301) [Size: 240] [--> http://192.168.9.160:2/getslack/]
/robots.txt           (Status: 200) [Size: 21]
Progress: 220561 / 220562 (100.00%)
===============================================================
Finished
===============================================================

提示:在此处搜索

可能是需要我们fuzz一下,普通fuzz不行,我们必须加上robots.txt里面的参数!

wfuzz
┌──(root㉿0x00)-[~/HackMyVM]
└─# wfuzz -u http://192.168.9.160:2/getslack/FUZZ.7z.001 -w /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt -t 50 --hc 403,404
 /usr/lib/python3/dist-packages/wfuzz/__init__.py:34: UserWarning:Pycurl is not compiled against Openssl. Wfuzz might not work correctly when fuzzing SSL sites. Check Wfuzz's documentation for more information.
********************************************************
* Wfuzz 3.1.0 - The Web Fuzzer                         *
********************************************************

Target: http://192.168.9.160:2/getslack/FUZZ.7z.001
Total requests: 220561

=====================================================================
ID           Response   Lines    Word       Chars       Payload                                                                                                                                                                    
=====================================================================
                                                                                                                                                                     
000083709:   200        80 L     794 W      19474 Ch    "twitter"                                                                                                                                                                  

Total time: 100.4681
Processed Requests: 220561
Filtered Requests: 220547
Requests/sec.: 2195.332

找到了!访问url就会下载一个文件!

这个文件只是7z的一个分卷,我们需要找到所有的才行!

我一直下载到15就404了说明只有14个文件!

这个时候,我们就可以解压了!
┌──(root㉿0x00)-[~/HackMyVM/123]
└─# 7z x twitter.7z.001

7-Zip [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=C.UTF-8,Utf16=on,HugeFiles=on,64 bits,4 CPUs Intel(R) Core(TM) i9-14900HX (B0671),ASM,AES-NI)

Scanning the drive for archives:
1 file, 20480 bytes (20 KiB)

Extracting archive: twitter.7z.001
--         
Path = twitter.7z.001
Type = Split
Physical Size = 20480
Volumes = 14
Total Physical Size = 268100
----
Path = twitter.7z
Size = 268100
--
Path = twitter.7z
Type = 7z
Physical Size = 268100
Headers Size = 130
Method = LZMA2:384k
Solid = -
Blocks = 1

Everything is Ok

Size:       267951
Compressed: 268100

解压成功!记得解压001哈!

我们得到一个图片文件!我们查看一下是否存在隐写!

trYth1sPasS1993

这个应该就是密码!

try this pass1993

那么用户名呢??

查看图片发现这个人是Slackware的开发者!

那么猜测,用户名可能是:

Patrick
patrick
Volkerding
volkerding
Patrick_Volkerding
Patrick_volkerding
patrick_Volkerding
patrick_volkerding
Slackware
slackware
Slack
slack


hydra
┌──(root㉿0x00)-[~/HackMyVM]
└─# cat username      
Patrick
patrick
Volkerding
volkerding
Patrick_Volkerding
Patrick_volkerding
patrick_Volkerding
patrick_volkerding
Slackware
slackware
Slack
slack

哈哈哈,猜对了!

ssh连接
┌──(root㉿0x00)-[~/HackMyVM]
└─# ssh patrick@192.168.9.160 -p 1
(patrick@192.168.9.160) Password: 
Last login: Sun Apr 28 06:18:07 2024 from 192.168.9.150
Linux 5.15.145.
patrick@slackware:~$ id
uid=1000(patrick) gid=1000(patrick) groups=1000(patrick),1001(kretinga)
patrick@slackware:~$ 


提权

系统信息收集

这么多用户啊??

ls -alR .

patrick@slackware:/home/claor$ sudo -l

We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these three things:

    #1) Respect the privacy of others.
    #2) Think before you type.
    #3) With great power comes great responsibility.

For security reasons, the password you type will not be visible.

Password: 
Sorry, user patrick may not run sudo on slackware.
patrick@slackware:/home/claor$ 

patrick用户没有sudo权限!我们查看另外几个用户!

经过测试,我发现这kretinga、claor两个用户也没有sudo -l权限!

继续信息收集!
patrick@slackware:/home/claor$ find / -perm -u=s -type f 2>/dev/null
/bin/su
/bin/ping
/bin/mount
/bin/umount
/bin/ntfs-3g
/bin/fusermount
/usr/bin/at
/usr/bin/cu
/usr/bin/ksu
/usr/bin/rcp
/usr/bin/rsh
/usr/bin/uux
/usr/bin/chfn
/usr/bin/chsh
/usr/bin/newuidmap
/usr/bin/sudo
/usr/bin/uucp
/usr/bin/crontab
/usr/bin/chage
/usr/bin/afppasswd
/usr/bin/fusermount3
/usr/bin/fdmount
/usr/bin/expiry
/usr/bin/newgrp
/usr/bin/passwd
/usr/bin/gpasswd
/usr/bin/pkexec
/usr/bin/rlogin
/usr/bin/uuname
/usr/bin/uustat
/usr/bin/procmail
/usr/bin/newgidmap
/usr/lib/polkit-1/polkit-agent-helper-1
/usr/sbin/uuxqt
/usr/sbin/uucico
/usr/libexec/lxc/lxc-user-nic
/usr/libexec/dbus-daemon-launch-helper
/usr/libexec/ssh-keysign
/sbin/unix_chkpwd
/sbin/mount.nfs

找了一圈并没有发现可疑信息!

直到我看到了这个....

id=1000是当前用户,id=1001是下一个用户!

果然,我们需要一直重复这个动作!

一直重复这个动作,直到找到user.txt为止!

累死我了,一直找到第43个用户才找到user.txt!

rpj7@slackware:~$ cat user.txt 
HMV{Th1s1s1Us3rFlag}                                                           
                                                                               
                                                                    
                                                                          
                                                                         
                                                                 
                         
rpj7@slackware:~$ echo -n "HMV{Th1s1s1Us3rFlag}" | base64
SE1We1RoMXMxczFVczNyRmxhZ30=

rpj7@slackware:~$ cat user.txt | base64
SE1We1RoMXMxczFVczNyRmxhZ30JICAgICAJICAgICAgCSAJICAgCSAgICAgCSAgICAgICAJICAg
ICAgIAogICAgCSAgICAgIAkJICAgIAkgICAgICAgCQkJIAkgICAJICAgICAgIAogICAgICAgCSAJ
ICAgICAJICAgICAgIAkgICAgICAJICAgIAkgICAgICAJICAgICAJICAgIAoJICAgICAJICAgIAkg
CSAgICAJICAgICAJICAgICAgCSAgICAgICAJICAgCSAgCiAgICAgCSAgIAkgICAJICAgICAJICAg
ICAJICAgCSAJCSAgICAgIAkgCiAgICAgCSAgICAgICAJICAgICAgIAkgICAgCSAgICAgIAkgICAg
CSAgICAgCSAgCSAKCSAgICAgICAJICAgICAJIAo=


我发现这个user.txt并不是简单的text文件!我们下载到本地分析!


get root
我们使用stegsnow工具把隐藏内容提取出来!

┌──(root㉿0x00)-[~/HackMyVM]
└─# stegsnow user.txt 
+��/嚠�                                                                                                                                                                                                                                            
┌──(root㉿0x00)-[~/HackMyVM]
└─# stegsnow -C user.txt
To_Jest_Bardzo_Trudne_Haslo  

尝试登录root用户

patrick@slackware:~$ su root
Password: 
root@slackware:/home/patrick# 

root@slackware:~# ls
roo00oot.txt
root@slackware:~# cat roo00oot.txt 
There is no root flag here, but it is somewhere in the /home directory.

好家伙,都要结束了都不给我flag!自己找吧!
root@slackware:~# grep  -Pnir 'HMV' /home
/home/rpj7/user.txt:1:HMV{Th1s1s1Us3rFlag}                                                             
/home/0xh3rshel/.screenrc:19:# Here is a flag for root: HMV{SlackwareStillAlive}


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

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

相关文章

PDF高效编辑器,一键转换将PDF文件转换成HTML文件,开启文件处理新篇章!

文件格式的转换与处理已成为我们日常工作中不可或缺的一部分。为了满足广大用户对高效、便捷文件处理的需求,我们荣幸地推出了全新的PDF高效编辑器——PDF到HTML一键转换工具!这款工具将为您带来前所未有的文件处理体验,让您轻松驾驭文件格式…

vite+vue3配置less

在Vite项目中配置LESS,你需要安装相关的插件,并在Vite配置文件中进行配置。以下是步骤和示例代码: 安装LESS和LESS插件: npm install less --save-dev npm install less-loader --save-dev 在Vite配置文件中(通常是v…

本地生活服务平台有哪些?哪个靠谱?

随着多家互联网大厂的本地生活服务布局日益展开,不少人都看到了其中的巨大市场缺口和广阔前景,想要入驻本地生活服务平台,瓜分这块巨大的蛋糕。而在当下这个选择大于努力的时代,能否分到蛋糕以及分到多少蛋糕的关键,就…

【Java数据结构】深入解析ArrayList与顺序表

【Java数据结构】深入解析ArrayList与顺序表 1.前言~🥳🎉🎉🎉 2.ArrayList的介绍 3.使用ArrayList 3.1 ArrayList的构造方法 3.11 第一个构造方法 3.12第二个构造方法 3.13第三个构造方法 3.2ArrayList中的tostring方…

vue2[黑马笔记]

vue基础 是什么—javascript框架 构建用户界面的前端框架 1.构建用户界面用vue往html页面中填充数据 2.框架现成的解决方案,遵守框架的规范去实现自己的业务功能学习vue 就是学习vue框架中规定的用法vue的指令组件(对ul结构的复用)&#x…

STM32G431RBT6之LCD与LED配置

首先,配置时钟树,时钟树的配置在我的另外一篇博客里,这里不再赘述. LCD与LED具有共同的IO口,同时创建工程较好. 打开原理图,发现LED的IO口是PC8~PC15,还有一个容易看漏的PD2.LCD的IO口是PC0到PC15. 当然,看产品手册也可以知道,但是还是推荐大家看原理图. 打开cubumx,给PC0~PC…

openjudge_2.5基本算法之搜索_1998:寻找Nemo

题目 1998:寻找Nemo 总时间限制: 2000ms 内存限制: 65536kB 描述 Nemo 是个顽皮的小孩. 一天他一个人跑到深海里去玩. 可是他迷路了. 于是他向父亲 Marlin 发送了求救信号.通过查找地图 Marlin 发现那片海像一个有着墙和门的迷宫.所有的墙都是平行于 X 轴或 Y 轴的. 墙的厚度可…

linux开发板开机启动向日葵

硬件:orangepi 5 pro 操作系统:ubuntu 20.4 lts 安装向日葵 根据我的实测,arm架构的ubuntu系统只能安装向日葵提供的麒麟系统的那个版本,具体安装方式官网下载页面有 允许任意用户连接到 X11 使用root用户登录后打开终端输入一下…

中仕公考:这几类人不能考公务员

拥有以上五类行为的学生无法参加公务员考试,当然这些只是基本的不能报考公务员的类别,现在各地区还会根据自己的情况调整范围,具体要以各地的公告为主。

电脑的无用设置功能(建议关闭)

目录 1、传递优化 ​2、常规​ 3、电源 1、传递优化 2、常规3、电源

【Kylin】V10系统在VMware中分辨率太小,无法通过GUI修改分辨率的解决方法

【Kylin】V10系统在VMware中分辨率太小,无法通过GUI修改分辨率的解决方法 解决办法1.打开终端方法1:方法2 2.输入 xrandr 命令,查询分辨率支持的列表3.选择适合的分辨率 。 例如:xrandr -s 1440x900_60 问题如下图: 保…

重要文件夹怎么加密?文件夹加密软件哪个更好?

文件夹是电脑重要的数据管理工具,可以避免电脑数据混乱。而为了保护文件夹的数据安全,我们需要加密保护重要文件夹。那么,重要文件夹怎么加密呢?下面我们就来了解一下。 文件夹加密超级大师 说起文件夹加密,文件夹加密…

通义千问再开源!推出最大尺寸1100亿参数模型

4月28日消息,通义千问开源1100亿参数模型Qwen1.5-110B,成为全系列首个千亿级参数开源模型,并在多项基准测评中都创下可与Llama3-70B媲美的成绩。目前Qwen1.5系列已累计开源10款大模型,通义千问开源模型下载量超过700万。 通义千问…

【C#】.net core 6.0 MVC返回JsonResult显示API接口返回值不可被JSON反序列化

欢迎来到《小5讲堂》 这是《C#》系列文章,每篇文章将以博主理解的角度展开讲解。 温馨提示:博主能力有限,理解水平有限,若有不对之处望指正! 目录 背景API接口接口代码请求失败原因排查调通效果 常见返回类型相关文章 …

python文件 成绩分析

‘’文件score.txt中存储了学生的考试信息,内容如下 小明,98 小刚,90 小红,91 小王,98 小刘,80 请写代码,读取文件数据,并进行如下分析 最高分和最低分分别是多少?得最高分的学生有几个? 得最低分的学生有几个平均分是多少? ‘’’ def rea…

会声会影2024官方中文破解旗舰版下载安装免费激活教程

会声会影2024是一款功能强大的视频编辑软件,它凭借直观易用的界面、全面的编辑工具以及丰富的特效和转场效果,受到了广大视频编辑爱好者和专业人士的喜爱。以下是对会声会影2024的详细介绍: 会声会影最新一键安装包下载如下: htt…

【真实体验】使用崖山YMP 迁移 Oracle/MySQL 至YashanDB 23.2 验证测试【YashanDB迁移体验官】

一、前言 说一下我和崖山数据库的结缘,大概在去年吧,因为我经常在墨天轮写文章,看到崖山数据库推出了一崖山体验官的活动,我就报名参加了。第一次体验了崖山数据库,也测试了我司数据库到崖山数据库的兼容性&#xff0…

Git--分布式版本控制系统

目录 一、理解分布式版本控制系统二、远程仓库三、克隆远程仓库四、向远程仓库推送五、拉取远程仓库六、配置Git七、给命令配置别名八、创建标签九、操作标签 一、理解分布式版本控制系统 我们⽬前所说的所有内容(⼯作区,暂存区,版本库等等&a…

【强训笔记】day5

NO.1 思路&#xff1a;找到数量最小的字符&#xff0c;就可以知道you的数量&#xff0c;用o的数量减去you的数量再减去1就是oo的数量。 代码实现&#xff1a; #include<iostream>using namespace std;int main() {int q;cin >> q;int a, b, c;while (q--){cin &g…

2024年SCI新算法独家改进:多策略改进的鹦鹉优化算法!炫技作品!效果极佳!

很多小伙伴经常问我能不能做原创改进的优化算法&#xff0c;这不&#xff0c;今天就给大家发了一期。 经常找我做改进算法的小伙伴&#xff0c;都知道我的实力。每份原创改进算法的代码&#xff0c;都是我阅读了很多文献、实验了很久之后做出来并调试的&#xff0c;不是随随便便…