osquery-defense-kit/incident_response/logged_in_users.sql
2022-10-19 16:19:53 -04:00

16 lines
247 B
SQL

-- Retrieves the list of all the currently logged in users in the target system.
--
-- tags: postmortem
-- platform: posix
SELECT
liu.*,
p.name,
p.cmdline,
p.cwd,
p.root
FROM
logged_in_users liu,
processes p
WHERE
liu.pid = p.pid;