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

Removing detection rules from the lmd package #7901

Merged
merged 5 commits into from
Oct 12, 2023
Merged

Conversation

ajosh0504
Copy link
Contributor

What does this PR do?

This PR moves detection rules associated with Lateral Movement Detection (lmd) out of the integration package.

Checklist

  • I have reviewed tips for building integrations and this pull request is aligned with them.
  • I have verified that all data streams collect metrics or logs.
  • I have added an entry to my package's changelog.yml file.
  • I have verified that Kibana version constraints are current according to guidelines.

How to test this PR locally

  • Spin up a local Elasticsearch cluster
  • Install the Lateral Movement Detection assets
  • Verify that no detection rules with the Lateral Movement Detection tag show up on the Rules Management page under Security

Related Issues

Not linking since these are internal issues

Screenshots

  • Package updated to version 2.0.0
Screen Shot 2023-09-08 at 9 48 00 AM
  • Job IDs have been updated to reflect the changes in this PR
Screen Shot 2023-09-08 at 9 56 55 AM
  • No rules have been installed upon installing the package assets
Screen Shot 2023-09-08 at 9 58 33 AM

@elasticmachine
Copy link

elasticmachine commented Sep 20, 2023

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2023-10-05T18:47:12.215+0000

  • Duration: 15 min 46 sec

Test stats 🧪

Test Results
Failed 0
Passed 1
Skipped 0
Total 1

🤖 GitHub comments

Expand to view the GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

@@ -25,7 +25,7 @@ source:
script:
source: "if (doc['host.ip'].size()!=0){emit(doc['host.ip'][1]);} else{emit('None');}"
dest:
index: "ml-rdp-lmd-1.0.2"
index: "ml-rdp-lmd"
Copy link
Member

Choose a reason for hiding this comment

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

Is the expectation for subsequent higher versions (say in 3.0.0) that this version' destination index should be deleted? If the results from this transform might be helpful to keep in the future, we recommend appending the fleet transform version to the dest index's name, and adding aliases.

Reason I'm noting this when user upgrade to a higher version in the future, Fleet does not delete ml-rdp-lmd, so we will need to make sure teh dest.index of that future version is different.

Copy link
Contributor

Choose a reason for hiding this comment

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

I removed the version as this transform ingests all the data in a users' environment, so, the upgrade will not affect the data collection at all. Also, tested it locally by bumping the fleet version (2.1.0) and can confirm that the data remains unchanged, only the name of the underlying transform i.e., logs-lmd.pivot_transform-default-2.0.0 changes to logs-lmd.pivot_transform-default-2.1.0.

Copy link
Contributor

Choose a reason for hiding this comment

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

Any reason to believe that fleet will delete the dest.index? I haven't seen it while testing!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@qn895 @sodhikirti07 Did y'all reach a consensus on this? This PR is ready to merge pending y'all's 🟢 .

Copy link
Member

Choose a reason for hiding this comment

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

Sorry @sodhikirti07, I meant to clarify that Fleet will NOT delete the dest.index of the old version, so in case there's any incompatibility in the future. But if we have tested potential future upgrades and found that the current package works well then that's great. The rest LGTM 🎉

Copy link
Contributor

@sodhikirti07 sodhikirti07 left a comment

Choose a reason for hiding this comment

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

Approving as I've already tested dest.index name for upgrades. Thank you @qn895 for taking a look!

@qn895
Copy link
Member

qn895 commented Sep 27, 2023

Transform changes LGTM 🎉

@ajosh0504
Copy link
Contributor Author

Keeping this open until a new Detection Engine release goes out. Please do not merge.

@ajosh0504 ajosh0504 merged commit 68a65d5 into main Oct 12, 2023
4 checks passed
@elasticmachine
Copy link

Package lmd - 2.0.0 containing this change is available at https://epr.elastic.co/search?package=lmd

@andrewkroh andrewkroh added the Integration:lmd Lateral Movement Detection label Jul 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change Integration:lmd Lateral Movement Detection
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants