-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Filebeat: osquery module #5971
Merged
Merged
Filebeat: osquery module #5971
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
//// | ||
This file is generated! See scripts/docs_collector.py | ||
//// | ||
|
||
[[filebeat-module-osquery]] | ||
:modulename: osquery | ||
|
||
== Osquery module | ||
|
||
The +{modulename}+ module collects and decodes the result logs written by | ||
https://osquery.readthedocs.io/en/latest/introduction/using-osqueryd/[osqueryd] | ||
in the JSON format. To set up osqueryd follow the osquery installation | ||
instructions for your operating system and configure the `filesystem` logging | ||
driver (the default). Make sure UTC timestamps are enabled. | ||
|
||
include::../include/what-happens.asciidoc[] | ||
|
||
|
||
[float] | ||
=== Compatibility | ||
|
||
The +{modulename}+ module was tested with logs from osquery version 2.10.2. | ||
Since the results are written in the JSON format, it is likely that this module | ||
works with any version of osquery. | ||
|
||
This module is available on Linux, macOS, and Windows. | ||
|
||
[float] | ||
=== Example dashboard | ||
|
||
This module comes with a sample dashboard for visualizing the data collected by | ||
the "compliance" pack. To collect this data, enable the `id-compliance` pack in | ||
the osquery configuration file. | ||
|
||
[role="screenshot"] | ||
image::./images/kibana-osquery-compatibility.png[] | ||
|
||
include::../include/configuring-intro.asciidoc[] | ||
|
||
The following example shows how to set paths in the +modules.d/{modulename}.yml+ | ||
file to override the default paths for the syslog and authorization logs: | ||
|
||
["source","yaml",subs="attributes"] | ||
----- | ||
- module: osquery | ||
result: | ||
enabled: true | ||
var.paths: ["/path/to/osqueryd.results.log*"] | ||
----- | ||
|
||
|
||
To specify the same settings at the command line, you use: | ||
|
||
["source","sh",subs="attributes"] | ||
----- | ||
./{beatname_lc} --modules {modulename} -M "osquery.result.var.paths=[/path/to/osqueryd.results.log*]" | ||
----- | ||
|
||
include::../include/config-option-intro.asciidoc[] | ||
|
||
[float] | ||
==== `result` fileset settings | ||
|
||
include::../include/var-paths.asciidoc[] | ||
|
||
*`var.use_namespace`*:: | ||
|
||
If true, all fields exported by this module are prefixed with `osquery.result`. | ||
Set to false to copy the fields in the root of the document. If enabled, this | ||
setting also disables the renaming of some fields (e.g. `hostIdentifier` to | ||
`host_identifier`). Note that if you set this to false, the sample dashboards | ||
coming with this module won't work correctly. The default is true. | ||
|
||
|
||
[float] | ||
=== Fields | ||
|
||
For a description of each field in the module, see the | ||
<<exported-fields-osquery,exported fields>> section. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
- module: osquery | ||
result: | ||
enabled: true | ||
|
||
# Set custom paths for the log files. If left empty, | ||
# Filebeat will choose the paths depending on your OS. | ||
#var.paths: | ||
|
||
# If true, all fields created by this module are prefixed with | ||
# `osquery.result`. Set to false to copy the fields in the root | ||
# of the document. The default is true. | ||
#var.use_namespace: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
- module: osquery | ||
result: | ||
enabled: true | ||
|
||
# Set custom paths for the log files. If left empty, | ||
# Filebeat will choose the paths depending on your OS. | ||
#var.paths: | ||
|
||
# If true, all fields created by this module are prefixed with | ||
# `osquery.result`. Set to false to copy the fields in the root | ||
# of the document. The default is true. | ||
#var.use_namespace: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
:modulename: osquery | ||
|
||
== Osquery module | ||
|
||
The +{modulename}+ module collects and decodes the result logs written by | ||
https://osquery.readthedocs.io/en/latest/introduction/using-osqueryd/[osqueryd] | ||
in the JSON format. To set up osqueryd follow the osquery installation | ||
instructions for your operating system and configure the `filesystem` logging | ||
driver (the default). Make sure UTC timestamps are enabled. | ||
|
||
include::../include/what-happens.asciidoc[] | ||
|
||
|
||
[float] | ||
=== Compatibility | ||
|
||
The +{modulename}+ module was tested with logs from osquery version 2.10.2. | ||
Since the results are written in the JSON format, it is likely that this module | ||
works with any version of osquery. | ||
|
||
This module is available on Linux, macOS, and Windows. | ||
|
||
[float] | ||
=== Example dashboard | ||
|
||
This module comes with a sample dashboard for visualizing the data collected by | ||
the "compliance" pack. To collect this data, enable the `id-compliance` pack in | ||
the osquery configuration file. | ||
|
||
[role="screenshot"] | ||
image::./images/kibana-osquery-compatibility.png[] | ||
|
||
include::../include/configuring-intro.asciidoc[] | ||
|
||
The following example shows how to set paths in the +modules.d/{modulename}.yml+ | ||
file to override the default paths for the syslog and authorization logs: | ||
|
||
["source","yaml",subs="attributes"] | ||
----- | ||
- module: osquery | ||
result: | ||
enabled: true | ||
var.paths: ["/path/to/osqueryd.results.log*"] | ||
----- | ||
|
||
|
||
To specify the same settings at the command line, you use: | ||
|
||
["source","sh",subs="attributes"] | ||
----- | ||
./{beatname_lc} --modules {modulename} -M "osquery.result.var.paths=[/path/to/osqueryd.results.log*]" | ||
----- | ||
|
||
include::../include/config-option-intro.asciidoc[] | ||
|
||
[float] | ||
==== `result` fileset settings | ||
|
||
include::../include/var-paths.asciidoc[] | ||
|
||
*`var.use_namespace`*:: | ||
|
||
If true, all fields exported by this module are prefixed with `osquery.result`. | ||
Set to false to copy the fields in the root of the document. If enabled, this | ||
setting also disables the renaming of some fields (e.g. `hostIdentifier` to | ||
`host_identifier`). Note that if you set this to false, the sample dashboards | ||
coming with this module won't work correctly. The default is true. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
- key: osquery | ||
title: "Osquery" | ||
description: > | ||
Fields exported by the `osquery` module | ||
fields: | ||
- name: osquery | ||
type: group | ||
description: > | ||
fields: |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tsg This seems to be a breaking change? Also saw there is no CHANGELOG for this PR.