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

Update to ECS 8.0 #28620

Merged
merged 32 commits into from
Nov 4, 2021
Merged

Update to ECS 8.0 #28620

merged 32 commits into from
Nov 4, 2021

Conversation

adriansr
Copy link
Contributor

@adriansr adriansr commented Oct 25, 2021

What does this PR do?

Updates the ECS field definitions to the current master (8.0-dev).

Why is it important?

To use the latest version of ECS.

Breaking changes

  • Remove log.original (@adriansr)
  • Remove process.ppid (@adriansr)
  • Remove host.user.* field reuse (@adriansr)
  • Don't lowercase http.request.method (@adriansr)
    - [ ] Remove deprecation notice from http.request.method (@marc-gr)
    - [ ] Migrate log.origin.file.line field type from integer to long (@marc-gr)
  • Remove Go code generator (@marc-gr)

Added

- [ ] Function as a Service fields (Beta) (@marc-gr)

Improvements

- [ ] Wildcard type field migration stage 3 (GA)
- [ ] match_only_text field type migration stage 3 (GA)
- [ ] Threat indicator fields stage 3 (GA) (@marc-gr) * Changes to TI fields are on hold, as Beats don't use the threat.* fields from ECS.

Note to reviewers

All liblogparser.js files include the same changes (same file):

37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/cylance/protect/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/zscaler/zia/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/tomcat/log/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/squid/log/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/microsoft/dhcp/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/f5/bigipafm/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/f5/bigipapm/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/proofpoint/emailsecurity/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/barracuda/spamfirewall/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/barracuda/waf/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/netscout/sightline/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/bluecoat/director/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/cisco/nexus/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/cisco/meraki/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/sonicwall/firewall/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/radware/defensepro/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/snort/log/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/infoblox/nios/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/juniper/netscreen/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/juniper/junos/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/sophos/utm/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/imperva/securesphere/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/fortinet/fortimail/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/fortinet/fortimanager/config/liblogparser.js
37fb671452818e5ef3d6f03810fd904cdacb9d8b  ./module/fortinet/clientendpoint/config/liblogparser.js

@adriansr adriansr added enhancement in progress Pull request is currently in progress. Team:Integrations Label for the Integrations team Team:Security-External Integrations 8.0-candidate labels Oct 25, 2021
@botelastic botelastic bot added needs_team Indicates that the issue/PR needs a Team:* label and removed needs_team Indicates that the issue/PR needs a Team:* label labels Oct 25, 2021
@mergify mergify bot added the backport-skip Skip notification from the automated backport with mergify label Oct 25, 2021
@elastic elastic deleted a comment from mergify bot Oct 25, 2021
@elasticmachine
Copy link
Collaborator

elasticmachine commented Oct 25, 2021

💚 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: 2021-11-03T22:45:24.771+0000

  • Duration: 232 min 23 sec

  • Commit: 98254b9

Test stats 🧪

Test Results
Failed 0
Passed 53596
Skipped 5242
Total 58838

💚 Flaky test report

Tests succeeded.

🤖 GitHub comments

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

  • /test : Re-trigger the build.

  • /package : Generate the packages and run the E2E tests.

  • /beats-tester : Run the installation tests with beats-tester.

@adriansr
Copy link
Contributor Author

/test

@adriansr adriansr marked this pull request as ready for review October 29, 2021 15:58
@adriansr adriansr requested review from a team as code owners October 29, 2021 15:58
@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations (Team:Integrations)

@elasticmachine
Copy link
Collaborator

Pinging @elastic/security-external-integrations (Team:Security-External Integrations)

@adriansr adriansr added review and removed in progress Pull request is currently in progress. labels Oct 29, 2021
@adriansr adriansr changed the title [Draft] Update ECS field definitions to 8.0 Update to ECS 8.0 Oct 29, 2021
@mergify
Copy link
Contributor

mergify bot commented Nov 1, 2021

This pull request is now in conflicts. Could you fix it? 🙏
To fixup this pull request, you can check out it locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

git fetch upstream
git checkout -b ecs_8.0 upstream/ecs_8.0
git merge upstream/master
git push upstream ecs_8.0

Copy link
Member

@P1llus P1llus left a comment

Choose a reason for hiding this comment

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

Nothing standing out from my point. Checked that each beat has the updated versions applied, checked that the ingest pipelines included in the commit is updated properly, and the expected output looks good.
Did not pull it down to check if there was any more files that should have been added. If we feel that is required I can do that as well.

Just some small comments from my side, then LGTM.

Comment on lines -5869 to -5870
--------------------------------------------------------------------------------
Dependency : github.com/elastic/ecs
Copy link
Member

Choose a reason for hiding this comment

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

Is this part totally removed now, or is it just github that messes it up?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, it's removed because it's not available anymore in the ECS repo. We could have left the dependency pointing to v1.12 but eventually they could diverge, forcing us to fork anyway.

@@ -62,7 +62,6 @@ require (
github.com/dustin/go-humanize v1.0.0
github.com/eapache/go-resiliency v1.2.0
github.com/eclipse/paho.mqtt.golang v1.3.5
github.com/elastic/ecs v1.12.0
Copy link
Member

Choose a reason for hiding this comment

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

Are we completely removing it as a dependency? From my understanding I think we are, just making sure.

@mergify
Copy link
Contributor

mergify bot commented Nov 2, 2021

This pull request is now in conflicts. Could you fix it? 🙏
To fixup this pull request, you can check out it locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

git fetch upstream
git checkout -b ecs_8.0 upstream/ecs_8.0
git merge upstream/master
git push upstream ecs_8.0

@adriansr adriansr merged commit dde7a1f into elastic:master Nov 4, 2021
@adriansr adriansr added backport-v8.0.0 Automated backport with mergify and removed backport-skip Skip notification from the automated backport with mergify labels Nov 4, 2021
@adriansr
Copy link
Contributor Author

adriansr commented Nov 4, 2021

@Mergifyio refresh

mergify bot pushed a commit that referenced this pull request Nov 4, 2021
Updates the ECS field definitions to the current master (8.0-dev).

- add_process_metadata processor: Replace usage of deprecated `process.ppid` field with `process.parent.pid`.
- add_docker_metadata processor: Replace usage of deprecated `process.ppid` field with `process.parent.pid`.
- Auditbeat: Replace usage of deprecated `process.ppid` field with `process.parent.pid`.
- Auditbeat system/process metricset: Replace usage of deprecated `process.ppid` field with `process.parent.pid`.
- Filebeat all modules: Replace usages of deprecated ECS fields `process.ppid` and `log.original` with `process.parent.pid` and `event.original`.
- Filebeat: Replace usages of `host.user.*` fields with `user.*` in `cisco`, `microsoft` and `oracle` modules.
- Packetbeat http: The field `http.request.method` will maintain its original case.

Co-authored-by: Marc Guasch <marc-gr@users.noreply.github.com>
(cherry picked from commit dde7a1f)

# Conflicts:
#	x-pack/filebeat/module/cisco/ios/test/cisco-ios-syslog.log-expected.json
#	x-pack/filebeat/module/iptables/log/test/geo.log-expected.json
#	x-pack/filebeat/module/panw/panos/test/global_protect.log-expected.json
#	x-pack/filebeat/module/panw/panos/test/hipmatch.log-expected.json
#	x-pack/filebeat/module/panw/panos/test/pan_inc_other.log-expected.json
#	x-pack/filebeat/module/panw/panos/test/pan_inc_threat.log-expected.json
#	x-pack/filebeat/module/panw/panos/test/pan_inc_traffic.log-expected.json
#	x-pack/filebeat/module/panw/panos/test/pan_inc_traffic_ietf.log-expected.json
#	x-pack/filebeat/module/panw/panos/test/traffic.log-expected.json
#	x-pack/filebeat/module/sonicwall/firewall/test/general.log-expected.json
#	x-pack/filebeat/module/sophos/utm/test/generated.log-expected.json
#	x-pack/filebeat/module/squid/log/test/access1.log-expected.json
@mergify
Copy link
Contributor

mergify bot commented Nov 4, 2021

refresh

✅ Pull request refreshed

adriansr added a commit that referenced this pull request Nov 5, 2021
Updates the ECS field definitions to the current master (8.0-dev).

- add_process_metadata processor: Replace usage of deprecated `process.ppid` field with `process.parent.pid`.
- add_docker_metadata processor: Replace usage of deprecated `process.ppid` field with `process.parent.pid`.
- Auditbeat: Replace usage of deprecated `process.ppid` field with `process.parent.pid`.
- Auditbeat system/process metricset: Replace usage of deprecated `process.ppid` field with `process.parent.pid`.
- Filebeat all modules: Replace usages of deprecated ECS fields `process.ppid` and `log.original` with `process.parent.pid` and `event.original`.
- Filebeat: Replace usages of `host.user.*` fields with `user.*` in `cisco`, `microsoft` and `oracle` modules.
- Packetbeat http: The field `http.request.method` will maintain its original case.

(cherry picked from commit dde7a1f)

Co-authored-by: Marc Guasch <marc-gr@users.noreply.github.com>
Co-authored-by: Adrian Serrano <adrisr83@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
8.0-candidate backport-v8.0.0 Automated backport with mergify enhancement review Team:Integrations Label for the Integrations team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants