WEBVTT

00:00:00.340 --> 00:00:02.650
Welcome to the last demo of this module.

00:00:03.140 --> 00:00:06.570
We're going to get the last task completed so we end up with

00:00:06.570 --> 00:00:09.160
our network data in the analysis platform.

00:00:09.740 --> 00:00:14.750
I will show you how to install the Filebeat agent on the Zeek management host.

00:00:15.240 --> 00:00:18.750
Then we will look at and install the Filebeat Zeek plugin.

00:00:19.440 --> 00:00:21.220
Once we have installed the plugin,

00:00:21.460 --> 00:00:25.350
I will show you how to configure it to capture a few of the Zeek logs.

00:00:25.860 --> 00:00:29.600
The last task will be to activate Filebeat and have it ship the

00:00:29.600 --> 00:00:32.659
belongs to the Globomantics Elasticsearch instance.

00:00:33.040 --> 00:00:34.360
Let's dive in.

00:00:36.240 --> 00:00:41.060
Before we get started, we need to make sure Zeek is logging in the JSON format.

00:00:41.440 --> 00:00:46.330
Zeek, by default, logs in a TSV, or tab‑separated values, format.

00:00:46.330 --> 00:00:49.030
If you're using something like Security Onion,

00:00:49.120 --> 00:00:53.730
the version of Zeek that comes installed is already modified to use JSON.

00:00:53.730 --> 00:00:56.650
Let's look at the Zeek site local policy,

00:00:56.660 --> 00:00:59.750
and I will show you the configuration line that needs to be present.

00:01:00.840 --> 00:01:03.970
All you need to do is add this line if it's not present,

00:01:03.970 --> 00:01:09.660
and use the zeekctl deploy command to publish the changes to all remote sensors.

00:01:10.240 --> 00:01:13.510
This change is necessary because Filebeat is expecting

00:01:13.520 --> 00:01:16.060
the Zeek logs to be in the JSON format.

00:01:18.940 --> 00:01:21.250
Now we're ready to install the Filebeat agent.

00:01:21.640 --> 00:01:24.250
You can download it directly from the Elastic website.

00:01:24.950 --> 00:01:29.060
I'm using an RPM‑based Linux distribution, so I chose the RPM format.

00:01:29.740 --> 00:01:32.460
Remember that the version you choose should match the other

00:01:32.460 --> 00:01:35.280
products deployed from the Elastic suite.

00:01:35.280 --> 00:01:39.920
Globomantics is using version 7.12 of the Elastic Stack,

00:01:39.930 --> 00:01:43.460
which is why I've already downloaded that same version of Filebeat.

00:01:44.240 --> 00:01:46.480
Installation takes only a few seconds,

00:01:46.490 --> 00:01:49.510
and the most recent version comes with a lot of modules

00:01:49.520 --> 00:01:51.760
that support various third‑party software.

00:01:52.640 --> 00:01:53.820
If you look closely,

00:01:54.140 --> 00:01:57.970
you can see that there's a Zeek module that we will need to enable

00:01:58.060 --> 00:02:01.530
using the filebeat module enable zeek command.

00:02:01.530 --> 00:02:06.660
Now notice how the file listing has changed to represent enabled modules.

00:02:07.340 --> 00:02:11.660
Once enabled, there are several configuration changes that we will need to make.

00:02:12.440 --> 00:02:13.340
By default,

00:02:13.490 --> 00:02:17.620
Filebeat will try to monitor every supported log file that Zeek produces,

00:02:17.630 --> 00:02:19.850
even if it does not exist.

00:02:20.340 --> 00:02:21.930
I do not want that behavior,

00:02:21.940 --> 00:02:26.160
so I will modify it to only a few that I want Filebeat to monitor.

00:02:26.640 --> 00:02:29.740
Unfortunately, we still have one more thing to change,

00:02:29.800 --> 00:02:32.250
and that is the path where the logs are located.

00:02:34.140 --> 00:02:37.840
Filebeat will make some assumptions about where the logs are located,

00:02:38.040 --> 00:02:42.000
and we're going to avoid that by explicitly telling Filebeat where

00:02:42.000 --> 00:02:44.760
we have the logs using the var.paths variable.

00:02:45.240 --> 00:02:48.320
This is going to take awhile because for each enabled

00:02:48.320 --> 00:02:51.340
log in this configuration file, and there are a lot of them,

00:02:51.530 --> 00:02:54.450
I will need to add the specific path to the log file.

00:02:55.040 --> 00:02:58.550
Now there's a shortcut that involves identifying where Filebeat assumes

00:02:58.550 --> 00:03:01.650
you have the logs for your particular operating system,

00:03:01.720 --> 00:03:04.510
and then using symbolic links to map that implicit

00:03:04.510 --> 00:03:06.790
location to the explicit location.

00:03:06.790 --> 00:03:11.250
For this lesson, I'm going to define the path for the X509 logs,

00:03:11.370 --> 00:03:15.460
and then with the magic of video, I'll come back with all the other changes.

00:03:16.330 --> 00:03:18.960
And like magic, I've made all the changes.

00:03:19.340 --> 00:03:23.060
Take the time to double‑check that you've enabled or disabled the logs

00:03:23.060 --> 00:03:25.830
you need and that the correct paths are defined.

00:03:26.110 --> 00:03:28.550
It's easy to miss one when there are so many.

00:03:28.940 --> 00:03:31.600
Syntax highlighting helps a little bit here.

00:03:31.940 --> 00:03:34.130
If you get errors when Filebeat starts,

00:03:34.330 --> 00:03:37.360
this is the file that's probably a good place to visit.

00:03:39.040 --> 00:03:41.150
So that takes care of which logs to monitor.

00:03:41.450 --> 00:03:44.760
Now we need to tell Filebeat where it needs to send those logs.

00:03:44.760 --> 00:03:47.760
To do that, I'll edit the filebeat.yml file.

00:03:48.240 --> 00:03:50.880
I contacted the Globomantics network engineers,

00:03:50.890 --> 00:03:53.980
and they gave me the IP address for the Elasticsearch server,

00:03:53.990 --> 00:03:57.120
which is using the default port of 9200.

00:03:57.120 --> 00:04:00.060
If your environment is using authentication,

00:04:00.440 --> 00:04:03.770
then you'll also need to modify either the API key or

00:04:03.770 --> 00:04:05.560
the username‑password combination.

00:04:06.040 --> 00:04:09.830
More complex configurations will include Logstash, but

00:04:09.830 --> 00:04:12.060
that is outside the scope of this course.

00:04:13.240 --> 00:04:17.260
We are finally complete with all the changes we need to make in this module.

00:04:17.740 --> 00:04:20.579
I'm going to start the Filebeat agent, and then check the

00:04:20.579 --> 00:04:23.130
status to make sure there are no errors with the

00:04:23.130 --> 00:04:25.680
configuration, and if there are no errors,

00:04:25.690 --> 00:04:26.950
we are done.

00:04:27.440 --> 00:04:32.260
Awesome, no errors.

00:04:32.830 --> 00:04:36.210
The Globomantics security analysts have been notified that

00:04:36.210 --> 00:04:39.250
they should be able to see Zeek network security logs from

00:04:39.250 --> 00:04:42.100
the DMZ user and server networks.

00:04:43.340 --> 00:04:47.360
Let's take a look ourselves and see if our hard work has been fruitful.

00:04:48.040 --> 00:04:49.960
Wow, that looks great.

00:04:50.530 --> 00:04:54.550
The logs from all three sensors are being shipped to the existing Elastic Stack,

00:04:55.040 --> 00:04:58.850
and we can see the Zeek field names populated on the left.

00:05:00.740 --> 00:05:02.080
We made it to the end.

00:05:02.650 --> 00:05:03.650
In this module,

00:05:03.660 --> 00:05:07.090
I showed you how to configure a Zeek cluster using a

00:05:07.090 --> 00:05:09.460
management host and three sensors.

00:05:09.840 --> 00:05:14.040
We looked at some of the considerations for network sensor strategy, and

00:05:14.040 --> 00:05:16.760
I showed you how to deploy the cluster configuration.

00:05:17.440 --> 00:05:21.610
We ended this module with the Filebeat agent that allows us to ship all the

00:05:21.610 --> 00:05:25.660
data from the master sensor to the Globomantics Elastic Stack.

00:05:26.100 --> 00:05:27.230
In the next module,

00:05:27.290 --> 00:05:30.300
I will show you how we can leverage all the data we are

00:05:30.300 --> 00:05:33.150
collecting to support continuous monitoring.
