Jon*_*onB 5 vps hacking apache-2.2
我运行来托管一些基本网站的 ubuntu VPS 似乎已被 apache 黑客攻击以进行比特币挖掘。
在我的 apache error.log 中,我看到以下内容。
[Sun Dec 15 06:27:58 2013] [notice] Apache/2.2.22 (Ubuntu) PHP/5.3.10-1ubuntu3.9 with
Suhosin-Patch configured -- resuming normal operations
[Sun Dec 15 06:27:58 2013] [info] Server built: Jul 12 2013 13:38:21
[Sun Dec 15 06:27:58 2013] [debug] prefork.c(1023): AcceptMutex: sysvsem (default: sysvsem
[Sun Dec 15 09:14:16 2013] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 8 children, there are 0 idle, and 18 total children
curl: try 'curl --help' or 'curl --manual' for more information
./tmp.sh: 1: ./tmp.sh: ^M: not found
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
^M 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0^M100 165k 100 165k 0 0 402k 0 --:--:-- --:--:-- --:--:-- 460k
./tmp.sh: 2: ./tmp.sh: ^M: not found
./tmp.sh: 3: ./tmp.sh: ^M: not found
./tmp.sh: 4: ./tmp.sh: ^M: not found
./tmp.sh: 5: ./tmp.sh: ^M: not found
./tmp.sh: 6: ./tmp.sh: ^M: not found
[2013-12-15 10:06:35] Starting Stratum on stratum+tcp://mine.pool-x.eu
[2013-12-15 10:06:35] 1 miner threads started, using 'scrypt' algorithm.
[2013-12-15 10:06:36] Stratum detected new block
[2013-12-15 10:11:05] Stratum detected new block
[2013-12-15 10:12:46] Stratum detected new block
[2013-12-15 10:13:15] Stratum detected new block
Run Code Online (Sandbox Code Playgroud)
计划是重建我的 VPS,但首先我想确切地了解这是如何发生的,而且我会走到一些死胡同。以下是我注意到/尝试过的一些事情:
我可以重新启动我的 VPS 并且挖矿似乎直到几个小时后才重新开始。这是 CRON 的工作吗?(好像每天早上10点左右重启)。
似乎不是 wordpress 漏洞
我已经设置了 lastcomm 并且对于 www-data 用户,我看到以下内容 - 这显然是正在发生的攻击。我怎样才能获得更多关于正在发生和正在运行的信息?
$sudo lastcomm www-data
apache2 和 httpd 进程有什么区别?
我现在已经注意到以下访问日志条目,但从来没有与挖矿开始备份的时间一致:
177.10.216.85 - - [15/Dec/2013:14:19:01 +0000]“POST /cgi-bin/php4?%2D%64+%61%6C%6C%6F%77%5F%75%72 %6C%5F%69%6E%63%6C%75%64%65%3D%6F%6E+%2D%64+%73%61%66%65%5F%6D%6F%64%65%3D% 6F%66%66+%2D%64+%73%75%68%6F%73%69%6E%2E%73%69%6D%75%6C$
我还针对该进程运行了 pwdx,它只是返回以下内容
4529:/
而 MySQL 进程返回以下内容。
2298:/var/lib/mysql
更新:
我不认为这是 plesk 漏洞,因为 apache 返回 404(正确?!)我现在很确定这只是一个隐藏的 CRON 工作或其他东西。甚至可能是一个隐藏的过程。他们最初是如何进来的,我真的不确定!
46.137.41.30 - - [26/Dec/2013:13:25:26 +0000] "POST /cgi-bin/php4?%2D%64+%61%6C%6C%6F%77%5F%75%72%6C%5F%69%6E%63%6C%75%64%65%3D%6F%6E+%2D%64+%73%61%66%65%5F%6D%6F%64%65%3D%6F%66%66+%2D%64+%73%75%68%6F%73%69%6E%2E%73%69%6D%75%6C%61%74%69%6F%6E%3D%6F%6E+%2D%64+%64%69%73%61%62%6C%65%5F%66%75%6E%63%74%69%6F%6E%73%3D%22%22+%2D%64+%6F%70%65%6E%5F%62%61%73%65%64%69%72%3D%6E%6F%6E%65+%2D%64+%61%75%74%6F%5F%70%72%65%70%65%6E%64%5F%66%69%6C%65%3D%70%68%70%3A%2F%2F%69%6E%70%75%74+%2D%64+%63%67%69%2E%66%6F%72%63%65%5F%72%65%64%69%72%65%63%74%3D%30+%2D%64+%63%67%69%2E%72%65%64%69%72%65%63%74%5F%73%74%61%74%75%73%5F%65%6E%76%3D%30+%2D%6E HTTP/1.1" 404 493 "-" "Mozilla/5.0 (iPad; CPU OS 6_0 like Mac OS X) AppleWebKit/536.26(KHTML, like Gecko) Version/6.0 Mobile/10A5355d Safari/8536.25"
Run Code Online (Sandbox Code Playgroud)
您是否尝试过解码访问日志中的奇怪字符串?
粘贴此字符串:
%2D%64+%61%6C%6C%6F%77%5F%75%72%6C%5F%69%6E%63%6C%75%64%65%3D%6F%6E+%2D%64+ %73%61%66%65%5F%6D%6F%64%65%3D%6F%66%66+%2D%64+%73%75%68%6F%73%69%6E%2E%73 %69%6D%75%6C$
在这个网站中:
http://www.url-encode-decode.com
对解码的 ascii 文本进行快速谷歌搜索表明这是一个被利用的 Plesk 漏洞。
归档时间: |
|
查看次数: |
3486 次 |
最近记录: |