告警內容
確認下列資訊:
事件分析完成前:
查看目前網路連線
sudo lsof -iTCP -n -P
或
netstat -anv
查詢目標 IP 是否仍有連線
sudo lsof -i @103.194.186.118
確認:
例如:
COMMAND PID USER Google 1234 user
或
xmrig 5678 user
查看 CPU 使用率
top -o cpu
或
ps aux | sort -nrk 3 | head
重點檢查:
常見挖礦程式名稱:
xmrig cpuminer minerd xmrig-proxy monero miner
搜尋挖礦程式
sudo find / -iname "*xmrig*" 2>/dev/null sudo find / -iname "*miner*" 2>/dev/null sudo find / -iname "*monero*" 2>/dev/null
查看程序執行路徑
ps aux | grep -i xmrig lsof -p <PID>
確認檔案位置是否位於:
/Users/<帳號>/Downloads /Users/<帳號>/Library /tmp /private/var
LaunchAgents
ls -al ~/Library/LaunchAgents/ ls -al /Library/LaunchAgents/
LaunchDaemons
ls -al /Library/LaunchDaemons/
列出系統服務
launchctl list
檢查是否存在:
com.update.helper com.apple.updater com.chrome.helper
等模仿合法程式名稱的項目。
最近七天下載檔案
find ~/Downloads -mtime -7
最近七天安裝程式
find /Applications -mtime -7
注意是否出現:
部分挖礦告警可能由瀏覽器腳本產生。
檢查:
Unified Log
log show --last 24h | grep 103.194.186.118
或
log show --last 24h | grep -i network
確認事件發生前後:
於終端機執行:
ps aux > ps.txt lsof -nP > lsof.txt launchctl list > launchctl.txt top -l 1 > top.txt system_profiler SPSoftwareDataType > system.txt
收集:
提供資安人員進一步分析。
符合以下情況之一:
處理方式:
符合下列特徵:
處理方式: