endpoint(opens in a new tab or window)
process where host.os.type == "linux" and event.type == "start" and
event.action in ("exec", "exec_event", "start", "ProcessRollup2") and
process.name in ("cat", "grep", "less", "more", "strings", "awk", "find", "xargs") and
process.args like (
"/etc/security/*", "/etc/pam.d/*", "/etc/login.defs", "/lib/security/*", "/lib64/security/*",
"/usr/lib/security/*", "/usr/lib64/security/*", "/usr/lib/x86_64-linux-gnu/security/*",
"/home/*/.aws/credentials", "/home/*/.aws/config", "/home/*/.config/gcloud/*credentials.json",
"/home/*/.config/gcloud/configurations/config_default", "/home/*/.azure/accessTokens.json",
"/home/*/.azure/azureProfile.json"
) and
not process.parent.name in ("wazuh-modulesd", "lynis")
Install detection rules in Elastic Security
Detect Security File Access via Common Utilities in the Elastic Security detection engine by installing this rule into your Elastic Stack.
To setup this rule, check out the installation guide for Prebuilt Security Detection Rules(opens in a new tab or window).