在 Backtrack 5 下对 Red Hat Enterprise Linux 5.4 的一次渗透测试

简介:
理论联系实际才是最好的学习方法,我们在知道如何渗透攻击的同时,有人要开始尝试进行模拟真是的攻击。

渗透时,我们在发现某台机器开放了某些端口后,你能够不加思索的联想到如何利用相关的服务漏洞来展开攻击。

每次的攻击是否成功取决于目标主机的操作系统。安装的服务包(ServicePack)版本以及语言类型,同时还依赖于是否成功的绕过了数据执行保护(DEP:DataExecutionPrevention)。DEP是为了防御缓冲区溢出而设计的。它将程序堆栈渲染为只读,防止shellcode被恶意放置在堆栈去并执行,但是我们可以通过一些复杂的堆栈操作来绕过DEP防护。

攻击渗透的本质就是充分识别目标系统中存在的安全弱点,并针对弱点找到相应的攻击,取得系统的访问权限。

1.针对操作系统的渗透
在前面的实验中已经说明了,不知道的可以去查看。

2.针对安装的服务包进行渗透


使用nmap对目标机器额进行检测,对端口及使用的服务的版本号扫描

140054995.png

140102370.png

打开BT5自带的metasploit(msfconsole)进行渗透

在msfconsole里面搜索与vsftpd相关的漏洞模块,刚好发现了一个vsftpd2.3.4的漏洞模块,我们使用它

140109463.png

设置RHOST为目标主机的IP地址,然后直接执行溢出,我们会获得一个linux的shell

140117655.png

在shell内进行查询和各种操作

140125203.png

在shell内添加一个uid=0的账户进行提权,这样我们就对目标机器拥有了完全的控制权,在不知道root的密码时一样可以操作任何的动作!

140128168.png

140131898.png

如果对方开了22端口,那么我们就可以直接使用ssh登录linux。

在对于发现安装的服务包的漏洞后,我们需要及时的对漏洞打上补丁,或者下载使用新的版本,避免因为没有及时补上漏洞而使主机失陷!

END!!!




     本文转自Tar0 51CTO博客,原文链接:http://blog.51cto.com/tar0cissp/1286343,如需转载请自行联系原作者





相关文章
|
7月前
|
SQL 安全 Linux
Metasploit Pro 4.22.8-20251014 (Linux, Windows) - 专业渗透测试框架
Metasploit Pro 4.22.8-20251014 (Linux, Windows) - 专业渗透测试框架
401 1
Metasploit Pro 4.22.8-20251014 (Linux, Windows) - 专业渗透测试框架
|
7月前
|
Linux 网络安全 iOS开发
Metasploit Framework 6.4.95 (macOS, Linux, Windows) - 开源渗透测试框架
Metasploit Framework 6.4.95 (macOS, Linux, Windows) - 开源渗透测试框架
828 1
Metasploit Framework 6.4.95 (macOS, Linux, Windows) - 开源渗透测试框架
|
8月前
|
SQL Linux 调度
Timeplus Enterprise 3.0 (Linux, macOS) - 流处理平台
Timeplus Enterprise 3.0 (Linux, macOS) - 流处理平台
181 2
Timeplus Enterprise 3.0 (Linux, macOS) - 流处理平台
|
8月前
|
数据管理 Linux iOS开发
Splunk Enterprise 9.4.5 (macOS, Linux, Windows) - 机器数据管理和分析
Splunk Enterprise 9.4.5 (macOS, Linux, Windows) - 机器数据管理和分析
288 0
|
8月前
|
安全 Linux 网络安全
Metasploit Pro 4.22.8-2025091701 (Linux, Windows) - 专业渗透测试框架
Metasploit Pro 4.22.8-2025091701 (Linux, Windows) - 专业渗透测试框架
486 2
Metasploit Pro 4.22.8-2025091701 (Linux, Windows) - 专业渗透测试框架
|
8月前
|
Linux 网络安全 iOS开发
Metasploit Framework 6.4.90 (macOS, Linux, Windows) - 开源渗透测试框架
Metasploit Framework 6.4.90 (macOS, Linux, Windows) - 开源渗透测试框架
549 1
Metasploit Framework 6.4.90 (macOS, Linux, Windows) - 开源渗透测试框架
|
8月前
|
存储 安全 Linux
Kali Linux 2025.3 发布 (Vagrant & Nexmon) - 领先的渗透测试发行版
Kali Linux 2025.3 发布 (Vagrant & Nexmon) - 领先的渗透测试发行版
837 0
|
8月前
|
安全 Linux 网络安全
Metasploit Framework 6.4.88 (macOS, Linux, Windows) - 开源渗透测试框架
Metasploit Framework 6.4.88 (macOS, Linux, Windows) - 开源渗透测试框架
667 0
|
人工智能 安全 Linux
Red Hat Enterprise Linux 10 正式版发布 - 红帽企业 Linux (RHEL)
Red Hat Enterprise Linux 10 正式版发布 - 红帽企业 Linux (RHEL)
1535 0
Red Hat Enterprise Linux 10 正式版发布 - 红帽企业 Linux (RHEL)
|
安全 Linux 数据安全/隐私保护
Red Hat Enterprise Linux 9.6 (x86_64, aarch64) - 红帽企业 Linux (RHEL)
Red Hat Enterprise Linux 9.6 (x86_64, aarch64) - 红帽企业 Linux (RHEL)
1386 36
Red Hat Enterprise Linux 9.6 (x86_64, aarch64) - 红帽企业 Linux (RHEL)