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

adding lkm rule #1478

Merged
merged 1 commit into from
Nov 6, 2020
Merged

Conversation

josehelps
Copy link
Contributor

@josehelps josehelps commented Nov 6, 2020

What type of PR is this?

/kind rule-create

Any specific area of the project related to this PR?

/area rules

What this PR does / why we need it:

This PR adds a new falco rule that looks for when insmod is called as part of a execve event. Injecting LKM modules on (post build) running production instances should be rare and is a common way for rootkits that employ kernel hooking to obfuscate themselves.

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

This is a rehashed of PR#1389 just cleaned up DCO as well as #1401

Does this PR introduce a user-facing change?:

Yes new rule in falco_rules.yml

rule(Linux Kernel Module injection detected): adds a new rule that detects when an LKM module is injected using `insmod` from a container (typically used by rootkits looking to obfuscate their behavior via kernel hooking). 

Signed-off-by: divious1 <josehelps@gmail.com>
@josehelps
Copy link
Contributor Author

/assign @Kaizhe

Copy link
Member

@leodido leodido left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 💯

@poiana
Copy link
Contributor

poiana commented Nov 6, 2020

LGTM label has been added.

Git tree hash: 2ee506df05207f99812923945e2e4fdde04cda42

@poiana poiana added the approved label Nov 6, 2020
Copy link
Member

@leogr leogr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM too!
Thank you!

/hold

just wait for @Kaizhe

@poiana
Copy link
Contributor

poiana commented Nov 6, 2020

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: fntlnz, leodido, leogr

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@fntlnz
Copy link
Contributor

fntlnz commented Nov 6, 2020

/milestone 0.27.0

@poiana poiana added this to the 0.27.0 milestone Nov 6, 2020
@leodido
Copy link
Member

leodido commented Nov 6, 2020

I think @d1vious changed everything as requested (also by @Kaizhe).

Thus, let this PR go in! 🎈

/hold cancel

@fntlnz
Copy link
Contributor

fntlnz commented Nov 6, 2020

Great job @d1vious ! Works like a charm

10:52:27.343581308: Warning Linux Kernel Module injection using insmod detected (user=root user_loginuid=1000 parent_process=sudo module=evilmodule.ko)

@poiana poiana merged commit cea9c6a into falcosecurity:master Nov 6, 2020
@josehelps
Copy link
Contributor Author

@fntlnz @leodido thank you for being patient with me and the help in slack! As a huge fan the project, I now know its creators are awesome great humans 😊. Will contribute more rules as the opportunity arises!

@fntlnz
Copy link
Contributor

fntlnz commented Nov 6, 2020

You're welcome @d1vious - Thanks for your help!

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

Successfully merging this pull request may close these issues.

6 participants