Skip to content

[Enhancement] Add ".caseless" fields to process events#9850

Closed
w0rk3r wants to merge 7 commits intomainfrom
fr-process_name-lowercase
Closed

[Enhancement] Add ".caseless" fields to process events#9850
w0rk3r wants to merge 7 commits intomainfrom
fr-process_name-lowercase

Conversation

@w0rk3r
Copy link
Copy Markdown
Contributor

@w0rk3r w0rk3r commented May 13, 2024

Proposed commit message

This PR adds .caseless fields for the process name and executable to improve compatibility with our Elastic Defend integration. This enables us to handle language limitations in KQL more effectively.

I'm also specifying the .text field as it was being removed from the markdown file otherwise.

Elastic Defend Mapping:

image

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

Build the integration, ingest sysmon or windows security logs.

Related issues

Screenshots

image
image

@w0rk3r w0rk3r added enhancement New feature or request Integration:windows Windows Integration:system System labels May 13, 2024
@w0rk3r w0rk3r self-assigned this May 13, 2024
@w0rk3r w0rk3r requested review from a team as code owners May 13, 2024 16:51
@elasticmachine
Copy link
Copy Markdown

elasticmachine commented May 13, 2024

🚀 Benchmarks report

Package system 👍(1) 💚(0) 💔(2)

Expand to view
Data stream Previous EPS New EPS Diff (%) Result
auth 2680.97 2105.26 -575.71 (-21.47%) 💔
syslog 23255.81 9345.79 -13910.02 (-59.81%) 💔

Package windows 👍(3) 💚(4) 💔(1)

Expand to view
Data stream Previous EPS New EPS Diff (%) Result
powershell 1795.33 1436.78 -358.55 (-19.97%) 💔

To see the full report comment with /test benchmark fullreport

@ishleenk17
Copy link
Copy Markdown
Member

ishleenk17 commented May 16, 2024

@w0rk3r : Can we please get the CI green here ?

@w0rk3r w0rk3r requested review from andrewkroh and ishleenk17 May 16, 2024 14:14
@elastic-sonarqube
Copy link
Copy Markdown

Quality Gate passed Quality Gate passed

Issues
0 New issues
0 Fixed issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarQube

Copy link
Copy Markdown
Member

@andrewkroh andrewkroh left a comment

Choose a reason for hiding this comment

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

This introduces a new field into an ECS controlled namespace that is not defined in ECS. We need to commit this to the schema first so that it becomes standardized. This will allow us to use a uniform definition everywhere and it's easily importable.

# fields.yml
- name: process.executable
  external: ecs

This additional multi-field will end up in the Elasticsearch ecs@mappings template meaning that all users of data streams can have a consistent mapping for these fields (even if they aren't using an integration).

Probably one reason that we have incompatibility with detection rules (#9234) is that the rule(s) are using fields which have not been defined in ECS. So if we can align ECS then any future integrations will just work.


I also think we should debate alternative naming. My initial reaction was that calling this "lowercase" would be more clear because it conveys the fact that the value is being converted to lowercase.

@botelastic
Copy link
Copy Markdown

botelastic bot commented Jun 21, 2024

Hi! We just realized that we haven't looked into this PR in a while. We're sorry! We're labeling this issue as Stale to make it hit our filters and make sure we get back to it as soon as possible. In the meantime, it'd be extremely helpful if you could take a look at it as well and confirm its relevance. A simple comment with a nice emoji will be enough :+1. Thank you for your contribution!

@botelastic botelastic bot added the Stalled label Jun 21, 2024
@w0rk3r w0rk3r requested a review from andrewkroh July 10, 2024 13:35
@botelastic botelastic bot removed the Stalled label Jul 10, 2024
@elasticmachine
Copy link
Copy Markdown

💚 Build Succeeded

History

cc @w0rk3r

@elastic-sonarqube
Copy link
Copy Markdown

Quality Gate failed Quality Gate failed

Failed conditions
75.0% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube

@w0rk3r
Copy link
Copy Markdown
Contributor Author

w0rk3r commented Jul 10, 2024

@andrewkroh @efd6, should I close this PR? From what I understand, changes made in elastic/ecs#2341 will auto-add these fields. Is that right?

@andrewkroh
Copy link
Copy Markdown
Member

andrewkroh commented Jul 11, 2024

The change to ECS won't make it into the ecs@mappings component template that's part of ES until probably 8.16.0.

So if you don't want to wait we can proceed with this now that the fields are agreed to in the schema.

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

Labels

enhancement New feature or request Integration:system System Integration:windows Windows

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Enhancement] Field adjusts to better compatibility with Detection Rules Add process.name.caseless to logs-system.* mapping

5 participants