WEBVTT

00:00:00.000 --> 00:00:03.286
So we've turned on a lot of the Windows available audit policy stuff,

00:00:03.286 --> 00:00:07.450
but we talked about a little bit more we can do to enhance that capability.

00:00:07.450 --> 00:00:09.042
So what else is there?

00:00:09.042 --> 00:00:12.370
So one of the other programs that I would highly recommend installing is Sysmon.

00:00:12.370 --> 00:00:14.332
Sysmon is a Microsoft tool.

00:00:14.332 --> 00:00:15.243
It's freely available.

00:00:15.243 --> 00:00:18.004
You go out to Microsoft's website to the Sysinternals tools,

00:00:18.004 --> 00:00:20.829
and it's going to be there, and you can download it.

00:00:20.829 --> 00:00:23.642
And what Sysmon is going to do is just enhance your logging.

00:00:23.642 --> 00:00:25.334
It's going to be logging additional things.

00:00:25.335 --> 00:00:26.901
You can log WMI command,

00:00:26.901 --> 00:00:31.200
and it's just a great tool that you can use in order to just

00:00:31.200 --> 00:00:33.251
enhance your logging and find these attacks.

00:00:33.251 --> 00:00:37.347
And that runs as a service on the machine and will continually log.

00:00:37.348 --> 00:00:40.059
It's not something you run one time.

00:00:40.059 --> 00:00:42.407
Once you install it, it's there until you uninstall it.

00:00:42.407 --> 00:00:44.988
It'll persist across reboots, and you're good to go.

00:00:44.988 --> 00:00:47.574
So let's look at what it's like to install it.

00:00:47.575 --> 00:00:50.770
So I'm going to launch Command Prompt and go to Run as administrator.

00:00:50.771 --> 00:00:53.195
We need to be an administrator because it does install a service.

00:00:53.195 --> 00:00:54.974
We need to have those elevated privileges.

00:00:54.974 --> 00:00:55.172
Okay.

00:00:55.172 --> 00:00:56.165
And you've already downloaded it.

00:00:56.165 --> 00:00:56.986
And I've already downloaded it.

00:00:56.986 --> 00:00:58.969
I'm just going to go to the directory where it's at.

00:00:58.969 --> 00:01:02.213
And here, you can see I've got the Sysmon executables,

00:01:02.213 --> 00:01:05.201
and then I also have a configuration file.

00:01:05.202 --> 00:01:07.402
Now you don't need to install it with a configuration file.

00:01:07.402 --> 00:01:10.485
By default, it will set up a lot of logging.

00:01:10.486 --> 00:01:11.680
But if you have a configuration file,

00:01:11.681 --> 00:01:14.287
it just kind of enhances everything that you can do.

00:01:14.287 --> 00:01:18.661
And the configuration file that I'm using is from Swift on Security's GitHub.

00:01:18.662 --> 00:01:24.879
Swift on Security has created basically like the default Sysmon configuration

00:01:24.879 --> 00:01:28.742
file that everybody seems to use and go from their base on.

00:01:28.743 --> 00:01:32.037
Yeah, you wouldn't know that Taylor Swift's night job is--- It's amazing.

00:01:32.037 --> 00:01:32.846
She can do everything.

00:01:32.847 --> 00:01:33.666
---security operations.

00:01:33.666 --> 00:01:34.808
She can do everything.

00:01:34.808 --> 00:01:39.780
So what we're going, and let me say too, I would recommend just using this.

00:01:39.780 --> 00:01:41.986
Install it on your system, let it run for a little while,

00:01:41.986 --> 00:01:43.681
like a day or so, and then see what it's logging,

00:01:43.681 --> 00:01:46.343
and you may want to whitelist some things in the configuration file.

00:01:46.343 --> 00:01:47.647
Every environment is unique,

00:01:47.647 --> 00:01:50.280
and so you want to make sure that your configuration

00:01:50.280 --> 00:01:52.308
file is tailored for your environment.

00:01:52.308 --> 00:01:54.382
Don't just fully trust Taylor.

00:01:54.383 --> 00:01:58.070
You've got to implement stuff in on your own as well.

00:01:58.071 --> 00:02:01.123
So what I'm going to do is I'm going to run sysmon64.

00:02:01.123 --> 00:02:04.790
I'm using sysmon64 because I have a 64-bit system.

00:02:04.790 --> 00:02:06.901
If you have a 32-bit system, just use Sysmon.

00:02:06.901 --> 00:02:09.375
And because we're initially installing it,

00:02:09.376 --> 00:02:13.770
I'll give it the -i option and then the configuration file.

00:02:13.770 --> 00:02:17.308
Yeah, and -i installs it as a service.

00:02:17.308 --> 00:02:19.137
If you were updating your configuration file,

00:02:19.137 --> 00:02:23.315
instead of -i, you would give it -c and then the configuration file.

00:02:23.315 --> 00:02:24.289
So I hit Enter.

00:02:24.289 --> 00:02:25.264
I get the EULA.

00:02:25.264 --> 00:02:26.453
You have to click through the EULA.

00:02:26.453 --> 00:02:29.514
If you don't want to click through the EULA if like you're scripting this out,

00:02:29.515 --> 00:02:32.904
you can give it the -accept EULA option.

00:02:32.904 --> 00:02:37.343
I'm going to click Agree, and you can see it went through, and it installed it.

00:02:37.344 --> 00:02:38.162
So it's installed.

00:02:38.162 --> 00:02:38.707
It's running.

00:02:38.708 --> 00:02:39.875
It's logging things.

00:02:39.875 --> 00:02:45.016
So we can see where it is logging things by going back into Event

00:02:45.016 --> 00:02:50.620
Viewer and then under Applications and Service Logs,

00:02:50.620 --> 00:02:55.215
Microsoft, Windows, and when we start scrolling down,

00:02:55.216 --> 00:02:58.465
there should be a Sysmon log in here.

00:02:58.465 --> 00:02:59.504
Here it is.

00:02:59.504 --> 00:03:02.074
So here we've got Sysmon under Operational,

00:03:02.074 --> 00:03:07.352
and you can see that we already have started logging things.

00:03:07.353 --> 00:03:11.068
We have Process Creation logs, and I'll just jump into this.

00:03:11.068 --> 00:03:13.272
The nice thing about Sysmon is,

00:03:13.272 --> 00:03:16.717
not only does it log the process that was running,

00:03:16.717 --> 00:03:21.594
it logs the command line automatically, it logs the user that launched it,

00:03:21.594 --> 00:03:24.868
it logs a ton of information that you can go through,

00:03:24.868 --> 00:03:28.144
it even logs the hash of the file that executed.

00:03:28.144 --> 00:03:34.538
So if you were using hashes as an indicator,

00:03:34.538 --> 00:03:37.660
now you can essentially log all your Sysmon logs and just

00:03:37.660 --> 00:03:39.300
search for that hash and see if it executed.

00:03:39.301 --> 00:03:39.452
Yeah,

00:03:39.452 --> 00:03:41.692
have that parsed out and in some sort of database that has

00:03:41.692 --> 00:03:46.410
the seam of your choice and with the Sysmon Jester and then

00:03:46.410 --> 00:03:49.227
search by hash and indicator, maybe even link that to some threat intelligence,

00:03:49.227 --> 00:03:51.568
and that's where we start getting some automation that

00:03:51.568 --> 00:03:53.742
helps us really find these attacks.

00:03:53.743 --> 00:03:55.743
That's awesome.
