Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

logging root authorized_keys file manipulation #152

Open
borross opened this issue Aug 15, 2024 · 1 comment
Open

logging root authorized_keys file manipulation #152

borross opened this issue Aug 15, 2024 · 1 comment

Comments

@borross
Copy link

borross commented Aug 15, 2024

for correct logging add pls under the section ## root ssh key tampering such value
-w /root/.ssh/authorized_keys -p wa -k rootkey

Commands for check:

ssh-keygen -t rsa -f test_key
cat test_key.pub >> /root/.ssh/authorized_keys

Log sample:

type=PATH msg=audit(1723720092.480:12186438): item=0 name="/root/.ssh/authorized_keys" nametype=UNKNOWN cap_fp=0 cap_fi=0 cap_fe=0 cap_fver=0 cap_frootid=0
@Pierre-Gronau-ndaal
Copy link
Contributor

what about:

-a always,exit -F arch=b32 -F dir=/root/.ssh/authorized_keys -F perm=wa -F key=rootkey
-a always,exit -F arch=b64 -F dir=/root/.ssh/authorized_keys -F perm=wa -F key=rootkey

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants