2015年4月22日 星期三

Bash CVE-2014-7169 弱點修復

Bash CVE-2014-7169  弱點修復

hychen39@gmail.com

緣由

架設主機被攻擊, 被當成跳板去功擊別人, IP 因此而被封鎖.
主機弱點在於 Bash 的漏洞(Bash CVE-2014-7169)。

測試

要測試此漏洞是否存在, 在 console 下輸入

env x='() { :;}; echo XD' bash -c "echo This is a test code"

若出現:

bash: warning: x: ignoring function definition attempt bash: error importing function definition for `x' This is a test code 表示系統漏洞仍存在[1]

修復

將 Bash 更新到 4.3.11(1) 此漏洞問題便解決了。

sudo apt-get update 
sudo apt-get upgrade

防火牆 [2]

別忘了設定你的防火牆. 使用以下指令看看防火牆管制的 port

ufw status 

另外, 使用以下指令現在開放的 listen port 有那些:

ufw show listening

Rootkit 的偵測及移除

參考: Ubuntu 安裝與使用 Rootkit 掃描程式 在 ubuntu 中安裝 chkrookit rkhunter 這兩支掃瞄程式.

參考資料

[1] 如何重新編譯 GNU Bash 解決 CVE-2014-7169 安全漏洞
[2] Ubuntu 用 ufw 指令快速啟用和設定防火牆
[3] Ubuntu 安裝與使用 Rootkit 掃描程式.
[4] How to install and use Rkhunter on a Linux server for rootkit, local exploits, malware and backdoors scanning

沒有留言: