2022-10-14 18:19:13 +00:00
|
|
|
-- Unusually small programs (state-based)
|
|
|
|
--
|
|
|
|
-- references:
|
|
|
|
-- * https://cybersecurity.att.com/blogs/labs-research/shikitega-new-stealthy-malware-targeting-linux
|
|
|
|
--
|
|
|
|
-- tags: transient process state
|
2022-10-07 20:19:18 +00:00
|
|
|
SELECT
|
|
|
|
p.pid,
|
|
|
|
p.path,
|
|
|
|
p.cmdline,
|
|
|
|
file.size,
|
|
|
|
file.mode,
|
2022-10-25 15:39:51 +00:00
|
|
|
file.type,
|
2022-10-07 20:19:18 +00:00
|
|
|
p.cwd,
|
|
|
|
p.euid,
|
|
|
|
p.parent,
|
|
|
|
pp.path AS parent_path,
|
|
|
|
pp.name AS parent_name,
|
|
|
|
pp.cmdline AS parent_cmdline,
|
|
|
|
pp.euid AS parent_euid,
|
|
|
|
hash.sha256 AS parent_sha256
|
|
|
|
FROM
|
|
|
|
processes p
|
|
|
|
LEFT JOIN file ON p.path = file.path
|
|
|
|
LEFT JOIN processes pp ON p.parent = pp.pid
|
|
|
|
LEFT JOIN hash ON pp.path = hash.path
|
2022-10-12 01:53:36 +00:00
|
|
|
WHERE
|
|
|
|
file.size > 0
|
2022-10-07 20:19:18 +00:00
|
|
|
AND file.size < 10000
|
2022-10-25 15:39:51 +00:00
|
|
|
AND NOT file.path LIKE '/Users/%/.zsh/completion'
|
|
|
|
AND NOT file.path LIKE '/home/%/.zsh/completion'
|
2022-10-30 14:19:33 +00:00
|
|
|
AND NOT file.path LIKE '/home/%/.local/share/Steam/ubuntu%'
|
|
|
|
AND NOT file.path LIKE '/home/%/.local/share/Steam/steamapps/%'
|
2022-11-07 15:03:43 +00:00
|
|
|
AND NOT file.path = '/'
|