WEBVTT

00:00:00.240 --> 00:00:01.180
So we're back.

00:00:01.180 --> 00:00:03.010
Here's where we're at in the scenario.

00:00:03.010 --> 00:00:06.110
We didn't prevent it.

00:00:06.120 --> 00:00:07.840
Or at least we didn't think we did.

00:00:07.850 --> 00:00:10.220
We're starting to see maybe some signs or some user

00:00:10.220 --> 00:00:11.460
reports that something weird's going on.

00:00:11.940 --> 00:00:14.730
Now as a defender, it's our job to detect it.

00:00:14.730 --> 00:00:18.050
And so as I understand it, you have some stuff prepared to talk about.

00:00:18.050 --> 00:00:20.060
We already talked about network traffic a little bit.

00:00:20.440 --> 00:00:25.070
And now I just want to prep everybody for a second about you have to capture

00:00:25.070 --> 00:00:28.350
the traffic and/or you have to be inspecting the traffic.

00:00:28.350 --> 00:00:29.880
You don't necessarily always have to capture it,

00:00:29.880 --> 00:00:31.950
but you have to be inspecting that traffic.

00:00:31.950 --> 00:00:34.870
Preferably, I think in this case, and totally correct me if I'm wrong,

00:00:34.870 --> 00:00:37.820
we're talking mainly north‑south traffic,

00:00:37.830 --> 00:00:39.660
or south to north really.

00:00:40.040 --> 00:00:43.490
So internal to external traffic is going capture at your edge.

00:00:43.500 --> 00:00:46.960
And we're going to apply signatures and analysis at that point.

00:00:46.960 --> 00:00:49.580
So that's where we're going to inject here,

00:00:49.580 --> 00:00:50.610
and, Josh,

00:00:50.610 --> 00:00:54.730
thanks so much for being the expert on this and showing us all the

00:00:54.730 --> 00:00:57.050
awesome Suricata stuff you're about to get into.

00:00:57.940 --> 00:00:58.930
‑‑Yeah, absolutely.

00:00:58.930 --> 00:01:00.870
And, yes, that's 100% correct.

00:01:00.880 --> 00:01:06.610
We're going to have to peel back the next layer of how detections can occur,

00:01:06.610 --> 00:01:08.930
what's currently available.

00:01:08.940 --> 00:01:12.310
This will give you some insight into maybe the stuff that

00:01:12.310 --> 00:01:13.590
you're paying for and how they're operating,

00:01:13.590 --> 00:01:14.940
as well as, hopefully,

00:01:14.940 --> 00:01:18.860
some ideas and some insights as to how you can create custom

00:01:18.940 --> 00:01:21.860
signatures to help with your detections as well.

00:01:21.860 --> 00:01:26.130
Most of this activity, in order for a threat actor to be successful,

00:01:26.130 --> 00:01:28.580
they have to reach out of your network at some point in time.

00:01:28.590 --> 00:01:32.500
There are scenarios where, say, they get ransomware in the environment,

00:01:32.500 --> 00:01:34.500
and then it's all sort of self‑contained from there,

00:01:34.500 --> 00:01:37.180
and they maybe don't have to beacon back out.

00:01:37.180 --> 00:01:39.370
They wait for you to contact them at that point.

00:01:39.370 --> 00:01:42.180
But in a lot of cases, Dridex is one of them,

00:01:42.190 --> 00:01:45.350
it is reliant on checking into its command and control,

00:01:45.360 --> 00:01:46.840
receiving additional commands.

00:01:46.840 --> 00:01:49.430
And so, eventually, it is going to leave the perimeter.

00:01:49.440 --> 00:01:52.490
The initial infection is where a lot of this activity is located.

00:01:52.490 --> 00:01:57.600
So it's really one of the better chances we have at observing,

00:01:57.610 --> 00:01:59.430
or not only preventing,

00:01:59.430 --> 00:02:02.960
but then detecting this possible threat actor from being in the environment.

00:02:04.040 --> 00:02:04.600
‑‑Perfect.

00:02:04.610 --> 00:02:08.199
From my perspective, especially watching this kind of thing,

00:02:08.199 --> 00:02:08.830
it's like, okay,

00:02:08.830 --> 00:02:14.660
well any network I'm included on or a defender on or maybe even my home network,

00:02:14.660 --> 00:02:16.430
I'm going to look for these detections and say,

00:02:16.430 --> 00:02:19.660
What can I do to go find out and get some peace of mind that

00:02:20.040 --> 00:02:22.160
this isn't running rampant in my environment.

00:02:22.840 --> 00:02:25.320
So we're back here watching.

00:02:25.320 --> 00:02:28.240
ANY.RUN's executed, and we see this network traffic.

00:02:28.240 --> 00:02:29.270
That's kind of our start.

00:02:29.270 --> 00:02:33.360
We're imagining now this is our device and our environment.

00:02:33.740 --> 00:02:35.360
Let's get some detections on.

00:02:37.040 --> 00:02:39.750
‑‑Yeah, so just to help kind of refocus that,

00:02:39.760 --> 00:02:43.360
we're looking at those IDS alerts because that's where really the

00:02:43.370 --> 00:02:47.350
signatures take place predominantly on the network side.

00:02:47.360 --> 00:02:51.630
The value in learning how signatures work is that once

00:02:51.630 --> 00:02:55.450
you understand what to look for, the patterns,

00:02:55.450 --> 00:02:57.920
what becomes good content to create a signature,

00:02:57.920 --> 00:03:01.050
whether you're writing it for an IDS system,

00:03:01.050 --> 00:03:05.140
network activity, or something on the host or static file analysis,

00:03:05.140 --> 00:03:07.820
the concepts really become quite similar.

00:03:07.820 --> 00:03:09.840
We're going to take this traffic.

00:03:09.850 --> 00:03:14.040
One of the benefits of many online sandboxes is that we can

00:03:14.050 --> 00:03:15.540
export the network traffic as a PCAP,

00:03:15.540 --> 00:03:18.160
and we can replay it in systems for analysis.

00:03:18.440 --> 00:03:19.620
We also have the ability,

00:03:19.630 --> 00:03:22.850
if you're monitoring these in real time on your network,

00:03:22.860 --> 00:03:26.690
you're going to have a SIM or some capability,

00:03:26.690 --> 00:03:29.510
some tool that's going to be inspecting the traffic,

00:03:29.520 --> 00:03:31.610
looking for those alerts that are being generated,

00:03:31.610 --> 00:03:34.120
and then providing you with a visual way,

00:03:34.120 --> 00:03:38.330
a dashboard and other capabilities to identify when these things

00:03:38.330 --> 00:03:40.600
occur and then to dig into them a little bit deeper.

00:03:40.610 --> 00:03:45.010
We're looking at‑‑‑I'm going to use Suricata for all of

00:03:45.010 --> 00:03:47.900
the PCAP processing here going forward.

00:03:47.910 --> 00:03:51.380
One of the tools that is available,

00:03:51.380 --> 00:03:54.470
sort of under the umbrella of the Suricata project,

00:03:54.470 --> 00:03:55.410
is EveBox.

00:03:55.410 --> 00:04:00.700
And EveBox is just a very straightforward rule and event manager.

00:04:00.710 --> 00:04:03.290
So you can see here, we're looking at the alerts.

00:04:03.290 --> 00:04:05.450
These are all the same alerts that we saw previously.

00:04:05.840 --> 00:04:08.220
What we can use EveBox for is to triage those.

00:04:08.230 --> 00:04:11.930
And so now we can select one of these alerts and dig a little

00:04:11.930 --> 00:04:13.960
bit deeper into what that alert is telling us.

00:04:13.960 --> 00:04:18.029
So one of our goals here is not just to understand the alert

00:04:18.029 --> 00:04:21.950
itself but then to build some context around that.

00:04:23.540 --> 00:04:27.710
‑‑So this is, again, the same process flow as now we're executed,

00:04:27.710 --> 00:04:30.260
and now we're analyzing the PCAP.

00:04:30.640 --> 00:04:33.320
I'm assuming, is this one downloaded from ANY.RUN because you can just click,

00:04:33.320 --> 00:04:35.600
you can spoof that button, and you get a PCAP.

00:04:35.610 --> 00:04:37.360
Is that what this is from specifically?

00:04:38.140 --> 00:04:40.070
‑‑Yes, specifically, that's what this is from.

00:04:40.080 --> 00:04:43.930
But we could also pretend that this was a dashboard that we're

00:04:43.930 --> 00:04:45.650
monitoring regularly in our environment,

00:04:45.650 --> 00:04:48.080
and all of a sudden these alerts popped up.

00:04:48.090 --> 00:04:49.670
So what do we do next?

00:04:49.680 --> 00:04:53.720
‑‑So that will be the same execution flow that we're looking at that executed,

00:04:53.720 --> 00:04:54.960
needs to go download something.

00:04:54.960 --> 00:04:56.510
So that's the first step.

00:04:56.520 --> 00:04:57.950
And so, hopefully, we can catch it there.

00:04:59.140 --> 00:05:03.010
‑‑This is really the first step we can take in peeling back the information.

00:05:03.020 --> 00:05:07.360
We have the contextual data around the alert itself,

00:05:07.370 --> 00:05:10.400
the source and destination IPs, as well as the ports.

00:05:10.400 --> 00:05:12.020
We have the flow ID.

00:05:12.100 --> 00:05:14.410
And that's something that's important because we're going to use that

00:05:14.410 --> 00:05:18.120
in just a minute to take one more step further back.

00:05:18.120 --> 00:05:21.120
To the right, you can see things like the signature,

00:05:21.130 --> 00:05:24.480
which is normally the message that you get when the alert is generated.

00:05:24.490 --> 00:05:25.880
We have the category,

00:05:25.880 --> 00:05:29.850
the signature ID if we wanted to investigate the rule itself

00:05:29.860 --> 00:05:33.730
because we need to understand the syntax of the rule to really

00:05:33.730 --> 00:05:35.310
understand what this rule is telling us.

00:05:35.310 --> 00:05:38.260
Sometimes it's quite obvious, a PE file is being downloaded,

00:05:38.340 --> 00:05:42.010
that's fairly straightforward if you understand what the PE file is.

00:05:42.020 --> 00:05:45.660
But other rules are going to be a little bit more difficult to

00:05:45.660 --> 00:05:48.570
comprehend because that message is typically very terse.

00:05:48.580 --> 00:05:53.150
The severity, that kind of goes into the color coding of the interface.

00:05:53.150 --> 00:05:55.920
Red generally means bad, severity 1.

00:05:56.170 --> 00:05:58.960
As we get away from 1, the severity decreases.

00:05:59.140 --> 00:06:02.300
And so that's just the way that rule writers can help draw

00:06:02.300 --> 00:06:06.760
attention to what they would consider higher severity events

00:06:06.760 --> 00:06:07.960
that you should investigate.

00:06:08.940 --> 00:06:10.770
‑‑In this case, I'm seeing a bit more of a mauve,

00:06:10.770 --> 00:06:14.590
but red to pink ratio means bad.

00:06:14.600 --> 00:06:15.150
Got it.

00:06:15.940 --> 00:06:17.350
‑‑We also have the protocol data.

00:06:17.360 --> 00:06:21.250
So something that isn't always immediately obvious when an

00:06:21.250 --> 00:06:23.960
alert is generated is what happened around it.

00:06:23.970 --> 00:06:26.780
This alert was associated with an HTTP event,

00:06:26.780 --> 00:06:30.370
that is, the PE file is downloaded over the HTTP protocol.

00:06:30.380 --> 00:06:34.690
So here's all the content around that HTTP request and response.

00:06:34.700 --> 00:06:39.570
Some of this can become very valuable information to detect on,

00:06:39.570 --> 00:06:41.850
to look in the environment for,

00:06:41.850 --> 00:06:46.030
either previously unknown activity as you're trying to scope an incident

00:06:46.040 --> 00:06:49.340
or to consider maybe creating additional detections on.

00:06:49.350 --> 00:06:53.560
So we have user agents; sometimes these user agents can be quite distinct.

00:06:53.940 --> 00:06:55.080
You might have to look,

00:06:55.080 --> 00:06:59.310
and hopefully you have the ability in your environment to compare that to

00:06:59.310 --> 00:07:02.520
all the other traffic on the network because if something like the user

00:07:02.520 --> 00:07:05.540
agent emerges as a very unique piece of content,

00:07:05.540 --> 00:07:09.330
then that helps you to scope this particular threat actor a little bit better.

00:07:09.340 --> 00:07:12.800
Oftentimes, these requests are quite minimal,

00:07:12.800 --> 00:07:15.760
and we'll see some examples of that here a little bit later on.

00:07:16.140 --> 00:07:20.840
The URL, the URL and the host fjb2016.com,

00:07:20.840 --> 00:07:22.580
I can't look at that and say it's good or bad.

00:07:22.580 --> 00:07:26.110
Seems a bit odd, but it's likely a legitimate website,

00:07:26.120 --> 00:07:31.390
so we can't just instantly condemn that as communication to a compromised host.

00:07:31.400 --> 00:07:32.900
Same with the URL.

00:07:32.900 --> 00:07:39.160
Yeah, it's a bit suspicious to me to see a rather terse,

00:07:39.160 --> 00:07:41.860
somewhat random‑looking PHP file,

00:07:41.860 --> 00:07:45.450
the request being made to that PHP file and the fact

00:07:45.460 --> 00:07:47.300
that it's returning a PE file,

00:07:47.310 --> 00:07:52.470
especially since it's buried so deep in the path structure of the server.

00:07:52.470 --> 00:07:56.210
But, again, it's not something that we can just instantly say,

00:07:56.210 --> 00:07:58.360
This is 100% bad traffic.

00:07:59.240 --> 00:08:01.440
Okay, so I mentioned the flow ID,

00:08:01.440 --> 00:08:05.240
and what the flow ID allows us to do is to take that step

00:08:05.240 --> 00:08:09.090
further back and try to get broader context around the

00:08:09.090 --> 00:08:11.370
activity generated from this alert.

00:08:11.370 --> 00:08:14.710
So not only the HTTP request, but as you see here,

00:08:14.720 --> 00:08:16.730
we have information about different flows,

00:08:16.730 --> 00:08:19.300
in this case the TCP session.

00:08:19.300 --> 00:08:23.450
We have the alert that was generated based off of that HTTP request.

00:08:23.450 --> 00:08:25.810
And then we even have a FILEINFO event,

00:08:25.810 --> 00:08:30.280
which can be really helpful because that can be data that can allow us

00:08:30.280 --> 00:08:34.850
to more quickly gain and gather other information about this file that

00:08:34.850 --> 00:08:36.450
now has just come across the network.

00:08:37.039 --> 00:08:40.120
‑‑So for Suricata, to relate this to Wireshark,

00:08:40.120 --> 00:08:41.720
which maybe a few more people have done,

00:08:41.720 --> 00:08:43.409
the right‑click TCP follow,

00:08:43.409 --> 00:08:47.400
this is like that but on steroids because you're getting everything within

00:08:47.400 --> 00:08:50.420
the TCP connection but then kind of more granular as well.

00:08:50.420 --> 00:08:51.580
So was there a file transfer?

00:08:51.580 --> 00:08:53.860
That's extracted with that Suricata framework.

00:08:54.240 --> 00:08:57.360
Same thing for, now let's go next level to HTTP protocol.

00:08:57.360 --> 00:09:00.720
That's extracted as well but all within a TCP flow.

00:09:00.720 --> 00:09:02.250
Would that be a good way to describe that?

00:09:03.040 --> 00:09:04.170
‑‑Yeah, absolutely.

00:09:04.170 --> 00:09:08.890
And so maybe it looks a little less impressive with just the singular event,

00:09:08.890 --> 00:09:12.630
but you can imagine as there's more activity,

00:09:12.640 --> 00:09:16.490
more alerts, more things happening from an infection,

00:09:16.490 --> 00:09:20.290
the flow really helps to take that step back and start to

00:09:20.290 --> 00:09:22.250
paint that picture of what's going on.

00:09:23.540 --> 00:09:26.450
So with each one of those event types,

00:09:26.450 --> 00:09:31.610
and not to get too deep into the specifics of how Suricata generates data,

00:09:31.620 --> 00:09:34.440
but every record,

00:09:34.440 --> 00:09:38.660
every transaction that happens on the network comes out as an event type.

00:09:38.670 --> 00:09:41.840
So we can look at those event types to get even more data.

00:09:41.850 --> 00:09:45.580
In this case, we're taking a look into that FILEINFO event.

00:09:45.580 --> 00:09:50.000
And here you can see that we have the libmagic,

00:09:50.000 --> 00:09:53.130
so the file identification PE32 DLL.

00:09:53.130 --> 00:09:56.610
We have the different checks and values, the hashes.

00:09:56.610 --> 00:10:01.460
So MD5, SHA1, SHA256, whichever hash value that we want.

00:10:01.840 --> 00:10:07.130
And having that data can be helpful because now we have a hash from the network

00:10:07.140 --> 00:10:10.840
that all we had to do was look into a dashboard somewhere,

00:10:10.840 --> 00:10:11.620
grab it,

00:10:11.620 --> 00:10:16.580
and we can search for it on the URLhaus or abuse.ch or take it to VirusTotal.

00:10:16.590 --> 00:10:22.120
Suricata as an engine has the ability to do file extraction as well.

00:10:22.120 --> 00:10:25.110
So there is some potential to automate not only the

00:10:25.110 --> 00:10:28.020
identification but then the extraction and then sending

00:10:28.020 --> 00:10:30.460
those files off to different workflows.

00:10:30.470 --> 00:10:33.130
It's not limited to just PE files.

00:10:33.140 --> 00:10:33.810
Of course,

00:10:33.810 --> 00:10:37.040
it does have some limitations in terms of the file types

00:10:37.040 --> 00:10:38.420
and the protocols that it supports.

00:10:38.420 --> 00:10:40.390
But it's all very well documented.

00:10:40.390 --> 00:10:44.760
So I would refer you to the docs to figure out if it meets your needs there.

00:10:45.240 --> 00:10:49.170
‑‑So that's all the output that we get from this if we want to

00:10:49.180 --> 00:10:51.230
make this custom for our environment because,

00:10:51.230 --> 00:10:54.460
again, everything changes, so we can't just necessarily use this MD5,

00:10:54.460 --> 00:10:57.350
but we could if you detected it in your environment.

00:10:57.350 --> 00:10:58.470
You take the MD5,

00:10:58.470 --> 00:11:02.020
and now you can find out everywhere that may be or everywhere that may

00:11:02.020 --> 00:11:04.310
have been downloaded and maybe a historical capture.

00:11:04.320 --> 00:11:07.970
But if we want to change that, we can do that in this.

00:11:07.980 --> 00:11:08.320
‑‑Yeah,

00:11:08.320 --> 00:11:16.110
and that's a really important point because a lot of the ability to threat hunt

00:11:16.120 --> 00:11:19.700
is dependent upon having the data to go back and look at.

00:11:19.710 --> 00:11:22.750
And so you can run in IDS mode, and it can generate alerts,

00:11:22.750 --> 00:11:25.970
and you can kind of stop caring about all of the data that

00:11:25.970 --> 00:11:28.530
it's also generating and logging that and having that

00:11:28.530 --> 00:11:31.150
historical sort of archival capability.

00:11:31.150 --> 00:11:33.620
But that's really important because we could,

00:11:33.620 --> 00:11:36.020
we could take that hash, we could now say,

00:11:36.020 --> 00:11:39.160
All right, any FILEINFO records that have this hash,

00:11:39.170 --> 00:11:39.980
I want to see them.

00:11:39.980 --> 00:11:42.870
And that might help us to discover other endpoints

00:11:42.870 --> 00:11:43.970
that have downloaded this Trojan,

00:11:43.970 --> 00:11:48.460
maybe from different IPs or different hosts that went previously undiscovered.

00:11:48.840 --> 00:11:51.510
We'll take a look at the signature in a minute,

00:11:51.510 --> 00:11:55.110
and we'll talk about some of the caveats with signatures.

00:11:55.110 --> 00:11:58.250
Signatures are still signatures; they can be bypassed.

00:11:58.250 --> 00:12:01.630
And then ways we can customize them to help make them

00:12:01.630 --> 00:12:02.950
more unique to your environment.

00:12:04.340 --> 00:12:09.100
Okay, so I briefly pointed out the signature ID, or the SID.

00:12:09.100 --> 00:12:15.130
Signature IDs don't follow a very strict form in terms of how

00:12:15.130 --> 00:12:17.620
you assign signature IDs or create them.

00:12:17.630 --> 00:12:19.300
But, generally speaking,

00:12:19.300 --> 00:12:22.850
Suricata as an engine will not let you have duplicate SIDs.

00:12:22.940 --> 00:12:25.670
So for the most part, the rulesets that you're consuming,

00:12:25.670 --> 00:12:28.100
they should be de‑conflicted to some degree.

00:12:28.110 --> 00:12:32.540
That SID allows you to look at the rule, and so we can use visual tools.

00:12:32.540 --> 00:12:36.710
You can see here, I'm actually using what's called Scirius from Stamus Networks,

00:12:36.710 --> 00:12:39.230
an open‑source project you can find on GitHub.

00:12:39.230 --> 00:12:41.710
You could just look at the rule file itself,

00:12:41.710 --> 00:12:45.350
and Suricata configuration will direct you to where those rules are.

00:12:45.350 --> 00:12:47.860
Then you could cat the file, grep on the SID,

00:12:47.870 --> 00:12:49.850
and get the syntax that you're seeing here.

00:12:50.240 --> 00:12:54.690
The syntax is unique to Suricata, much like if you were to look at another IDS,

00:12:54.690 --> 00:12:55.460
such as Snort.

00:12:55.460 --> 00:12:57.160
It also has its own syntax.

00:12:57.160 --> 00:12:58.250
But, again,

00:12:58.250 --> 00:13:02.970
what we're trying to identify are unique enough patterns that are

00:13:02.980 --> 00:13:06.900
repeatable by this either activity that we're investigating or a

00:13:06.900 --> 00:13:10.630
particular threat actor that makes for a solid alert,

00:13:10.630 --> 00:13:11.940
something that will generate an alert,

00:13:11.940 --> 00:13:15.990
that will really raise an event that will draw our

00:13:15.990 --> 00:13:18.260
attention to something we should investigate.

00:13:18.270 --> 00:13:21.090
We won't go through all of the structure here.

00:13:21.090 --> 00:13:24.620
It's a little bit‑‑‑we could spend a couple hours doing that.

00:13:24.630 --> 00:13:28.130
But what it really boils down to is certain keywords,

00:13:28.130 --> 00:13:31.460
the dark blue content that you see in the screenshot,

00:13:31.640 --> 00:13:35.060
certain keywords that tell the engine where to look.

00:13:35.140 --> 00:13:36.380
And, again, this is very common.

00:13:36.380 --> 00:13:37.330
Think about ClamAV.

00:13:37.330 --> 00:13:39.610
When we write a signature for an AV,

00:13:39.610 --> 00:13:43.100
we need to tell it where to look in the files that it's scanning.

00:13:43.110 --> 00:13:44.280
So where do we look?

00:13:44.280 --> 00:13:48.550
And then the content that follows is what are we looking for?

00:13:48.940 --> 00:13:52.960
So if you can identify the file data,

00:13:53.340 --> 00:13:57.800
then that is a content match on the first two characters,

00:13:57.800 --> 00:13:58.450
MZ.

00:13:58.460 --> 00:14:02.280
And those are the first two bytes typically in PE files, MZ.

00:14:02.290 --> 00:14:03.070
From there,

00:14:03.070 --> 00:14:06.430
it does a little bit more of a thorough detection in that it

00:14:06.430 --> 00:14:08.760
looks a little bit further into the file to say,

00:14:08.760 --> 00:14:13.900
Okay, if we find the bytes MZ, then 60‑some odd bytes later,

00:14:13.900 --> 00:14:17.750
we should also find another signature, which is the PE signature.

00:14:18.070 --> 00:14:21.460
And you'll see that sort of in the middle of this rule here.

00:14:21.940 --> 00:14:25.340
That's an attempt to reduce the false positives because,

00:14:25.340 --> 00:14:27.300
yeah, in any sequence of bytes,

00:14:27.300 --> 00:14:30.310
the characters M and Z are probably going to be there.

00:14:30.310 --> 00:14:34.200
And so getting a little bit more thorough helps to reduce that noise.

00:14:34.210 --> 00:14:39.370
The other thing that's important to point out here is that it's really hard,

00:14:39.370 --> 00:14:44.250
from an IDS engine perspective, to correlate all this activity and say,

00:14:44.250 --> 00:14:46.050
Okay, if I see this, this, and this event,

00:14:46.050 --> 00:14:47.750
then generate an alert.

00:14:47.750 --> 00:14:50.790
And you'll notice in the middle of this rule, there's a flowbits.

00:14:50.790 --> 00:14:55.030
And a flowbit is just a way to basically track a Boolean to say,

00:14:55.030 --> 00:14:59.630
If this event occurs, so traffic matches on another rule,

00:14:59.630 --> 00:15:03.860
and then traffic matches on this rule, now generate the alert.

00:15:03.870 --> 00:15:06.610
And so that's how‑‑‑I mentioned with the PE files,

00:15:06.610 --> 00:15:09.830
what we're trying to, because PE files are commonly downloaded all the time,

00:15:09.840 --> 00:15:11.490
we're trying to reduce that noise.

00:15:12.050 --> 00:15:14.950
It a PE file comes from Windows update,

00:15:15.340 --> 00:15:19.230
don't set the flowbit so that we don't alert on a PE file download.

00:15:19.230 --> 00:15:25.180
If a PE file comes from evidence of a PowerShell command,

00:15:25.180 --> 00:15:27.670
set the flowbit, and then if a PE file comes,

00:15:27.670 --> 00:15:28.940
generate the alert.

00:15:28.940 --> 00:15:34.210
‑‑So this flowbit piece, and this is great even for me, so we're saying set it.

00:15:34.220 --> 00:15:35.620
And then what is the ET.http.binary?

00:15:35.620 --> 00:15:38.980
Is that what's reducing, wait for this thing to happen?

00:15:38.990 --> 00:15:41.340
What are we‑‑‑what is that referring to?

00:15:41.350 --> 00:15:44.710
‑‑So not to get too deep into the flowbit,

00:15:44.710 --> 00:15:47.820
but it's considered a Boolean variable.

00:15:47.830 --> 00:15:53.660
You either set it or you read it, and so you have the flowbit and the action,

00:15:53.660 --> 00:15:57.010
and then that's just like the variable,

00:15:57.020 --> 00:16:00.950
so that's going to be a unique variable that the engine will load,

00:16:00.960 --> 00:16:05.690
and that's how it knows where to check other flowbits to see how it's been set.

00:16:05.700 --> 00:16:12.170
So you can have different‑‑‑if you look at the different IDS rulesets,

00:16:12.180 --> 00:16:14.500
Emerging Threats Open, Emerging Threats Pro,

00:16:14.500 --> 00:16:15.910
Open is the free one,

00:16:15.910 --> 00:16:20.640
there are actually a number of alerts that are rules that

00:16:20.640 --> 00:16:22.930
are written to alert on PE file downloads.

00:16:22.940 --> 00:16:25.990
Some of them will have different flowbit scenarios though,

00:16:25.990 --> 00:16:29.890
dependencies then that are created so that they don't

00:16:29.890 --> 00:16:32.430
always alert on the same conditions.

00:16:32.440 --> 00:16:36.760
‑‑So specifically for this malware for Dridex,

00:16:36.770 --> 00:16:40.300
is this rule specifically for Dridex that we're looking for,

00:16:40.300 --> 00:16:43.440
at least for the EXE download behavior?

00:16:43.440 --> 00:16:47.510
‑‑This type of a rule is far more generic.

00:16:47.520 --> 00:16:49.990
There are a couple of flowbits in this one.

00:16:50.000 --> 00:16:54.170
The first instance of the flowbits is looking if an

00:16:54.170 --> 00:16:56.680
ET.INFO.WindowsUpdate is not set.

00:16:56.680 --> 00:17:01.840
So, again, it's a bit broad in that if it's not related to Windows Update,

00:17:01.840 --> 00:17:04.910
some other rule somewhere else is setting that flowbit,

00:17:04.920 --> 00:17:07.700
which you could then look at the ruleset to figure out,

00:17:07.700 --> 00:17:09.089
then it's generating.

00:17:09.099 --> 00:17:11.780
So we're going to see these kind of regardless.

00:17:11.780 --> 00:17:14.450
Using that structure, though,

00:17:14.460 --> 00:17:18.990
we can begin to create more custom scenarios where maybe there is a

00:17:18.990 --> 00:17:22.010
particular type of executable that we care about,

00:17:22.010 --> 00:17:24.310
or maybe there's some additional content in the

00:17:24.310 --> 00:17:26.720
executable that we always see that is there.

00:17:26.720 --> 00:17:28.770
That's more of a research activity.

00:17:28.780 --> 00:17:32.740
So for common threat defense, Blue Teamers,

00:17:32.750 --> 00:17:36.090
we just don't have the time to go through and do that sort of research.

00:17:36.090 --> 00:17:38.670
That's what companies like Emerging Threats and Proofpoint,

00:17:38.670 --> 00:17:41.840
that's what they do on our behalf is they look for those patterns,

00:17:41.840 --> 00:17:48.100
and they try to make them as as unique and also then be able to

00:17:48.100 --> 00:17:51.300
detect very specifically as they possibly can.

00:17:51.300 --> 00:17:52.890
But it's not always the case.

00:17:52.900 --> 00:17:53.680
However, again,

00:17:53.690 --> 00:17:57.210
with this sort of information, it really disguised the limit then and

00:17:57.210 --> 00:17:59.350
how you can take it and apply it to your environment.

00:18:00.240 --> 00:18:00.440
‑‑Yeah.

00:18:00.440 --> 00:18:03.030
And as a defender, so I can take something like this that's more generic,

00:18:03.030 --> 00:18:06.330
we know that executable for Dridex has to download,

00:18:06.330 --> 00:18:09.010
and whether whatever the extension of the file is,

00:18:09.010 --> 00:18:13.770
it still has the MZ and the‑‑‑this can now execute in DOS or whatever.

00:18:13.770 --> 00:18:17.540
And so it's going to have that stuff in it.

00:18:17.550 --> 00:18:18.270
I can get that alert.

00:18:18.270 --> 00:18:21.840
But in context with other alerts that are also either

00:18:21.840 --> 00:18:26.450
more or less specific to Dridex, that starts to help me figure out,

00:18:26.450 --> 00:18:29.560
I have a higher confidence that this is a true positive.

00:18:31.040 --> 00:18:31.680
‑‑Yeah.

00:18:31.690 --> 00:18:35.570
And that's a great‑‑‑you could take a rule like this and you could,

00:18:35.580 --> 00:18:39.800
once you became comfortable with the rule syntax,

00:18:39.810 --> 00:18:42.660
you could add additional content matches and say,

00:18:42.670 --> 00:18:47.190
Okay, not only do I want to look for the evidence of a PE file,

00:18:47.190 --> 00:18:54.050
but if it came from a .php or a .tar or a .zip or something

00:18:54.340 --> 00:18:57.950
that is a very nonstandard file extension that you wouldn't

00:18:57.950 --> 00:18:59.590
expect a PE file to come from,

00:18:59.600 --> 00:19:03.380
we could use very specific examples from behaviors to see with Dridex.

00:19:03.380 --> 00:19:05.740
We could be a little bit more broad or generic.

00:19:05.750 --> 00:19:06.330
Again,

00:19:06.330 --> 00:19:10.600
it really boils down to how much time you have in order to

00:19:10.610 --> 00:19:12.670
customize your detections in your environment.

00:19:13.240 --> 00:19:17.670
‑‑Do we have some more higher fidelity rulesets for Dridex that we can show off?

00:19:18.140 --> 00:19:18.560
‑‑Yes.

00:19:18.570 --> 00:19:22.660
So we do have the ability then to try to get a little bit higher fidelity.

00:19:22.670 --> 00:19:24.350
Here are two examples.

00:19:24.360 --> 00:19:26.300
We have two alerts.

00:19:26.310 --> 00:19:29.590
The Feodo Tracker Command and Control Server.

00:19:29.600 --> 00:19:31.820
This is an alert that's going to be generated because we've

00:19:31.820 --> 00:19:36.850
identified previously IPs that we know are related to some

00:19:36.850 --> 00:19:38.260
threat actor or some group.

00:19:38.260 --> 00:19:39.010
In this case,

00:19:39.010 --> 00:19:41.570
the alert's a bit more generic in that it's saying it's

00:19:41.570 --> 00:19:45.970
part of this broader tracker service.

00:19:45.970 --> 00:19:49.790
The other, and this one is a bit more precise,

00:19:49.790 --> 00:19:50.470
and, again,

00:19:50.470 --> 00:19:56.730
the quality of the rule all depends on what we observe in the threat actors,

00:19:56.740 --> 00:20:02.550
how much research is done, how unique the patterns that they leave behind.

00:20:02.560 --> 00:20:06.400
So here we have a detection based off of the TLS,

00:20:06.400 --> 00:20:10.070
the SSL certificate, they still use SSL in the names.

00:20:10.070 --> 00:20:13.550
And more specifically, you'll see they saw three alerts that were Dridex.

00:20:13.550 --> 00:20:18.360
So they're saying, Yeah, I'm pretty confident that's Dridex but maybe not 100%.

00:20:18.360 --> 00:20:19.710
And that's true.

00:20:19.720 --> 00:20:23.810
It can be, when we start looking at some of these other detections,

00:20:23.810 --> 00:20:28.790
well, they can be very high fidelity in some situations.

00:20:28.790 --> 00:20:31.760
They also have a tendency to be a little bit more

00:20:31.760 --> 00:20:33.720
noisy in terms of the false positives.

00:20:33.730 --> 00:20:36.640
So let's take a look at these two alerts real quick.

00:20:36.640 --> 00:20:39.190
‑‑Especially with certificate detection,

00:20:39.190 --> 00:20:41.980
that's really near and dear to my heart because I think it's

00:20:41.980 --> 00:20:43.600
something that sometimes gets bypassed.

00:20:43.610 --> 00:20:44.450
So let's check it out.

00:20:45.640 --> 00:20:45.980
‑‑Okay,

00:20:45.980 --> 00:20:49.280
so the first thing I'll do is just step into the alert

00:20:49.280 --> 00:20:52.120
information here as we saw with the previous alerts,

00:20:52.120 --> 00:20:53.270
source and destinations.

00:20:53.270 --> 00:20:55.300
We have ports.

00:20:55.310 --> 00:20:57.640
So this one is communicating over 443.

00:20:57.650 --> 00:21:02.850
So we can suspect that a TLS session is to follow, although not a guarantee.

00:21:02.860 --> 00:21:05.450
We'll actually use the flow ID, though,

00:21:05.450 --> 00:21:09.450
and we'll pivot off of the flow ID in order to get that broader context here.

00:21:09.840 --> 00:21:14.430
And here you can see how all of these alerts actually tie together.

00:21:14.440 --> 00:21:17.710
It's not always 100% clear when looking at that

00:21:17.710 --> 00:21:19.490
sort of inbox approach of alerts.

00:21:19.500 --> 00:21:24.290
So we have the TCP session established, then we see we have a TLS event.

00:21:24.300 --> 00:21:28.740
So the first alert is generating just simply off of the IP address.

00:21:28.740 --> 00:21:33.180
So it's using an IP reputation capability within the Suricata engine.

00:21:33.180 --> 00:21:37.110
From there, once we have established or once that TLS session,

00:21:37.110 --> 00:21:40.790
as that's being established, information from the certificate,

00:21:40.800 --> 00:21:44.140
there is a rule that has been written in order to generate detections

00:21:44.140 --> 00:21:46.440
based off of that or to generate that alert there.

00:21:46.450 --> 00:21:48.580
And that's where then those alerts follow.

00:21:48.580 --> 00:21:51.310
So, in fact, we have four different alerts,

00:21:51.310 --> 00:21:54.270
but they're all related to the same activity,

00:21:54.270 --> 00:21:56.850
the same connection to a singular host.

00:21:56.850 --> 00:21:59.700
‑‑Theoretically, and just to set this up for like a real‑time detection,

00:21:59.700 --> 00:22:01.960
if I take this to an environment I'm working on now,

00:22:02.340 --> 00:22:03.970
inspect the traffic,

00:22:03.980 --> 00:22:07.890
I may not get the first alert because it just may not be

00:22:07.890 --> 00:22:09.690
on the black list for the C2 server.

00:22:09.690 --> 00:22:10.940
But this is, in fact,

00:22:10.940 --> 00:22:16.930
we did have clear text or unencrypted communication for the first stage,

00:22:16.930 --> 00:22:21.860
but now this is TLS secured connection for C2.

00:22:22.340 --> 00:22:25.010
And so, hopefully, we got lucky and it is on a black list.

00:22:25.010 --> 00:22:29.860
But if we didn't get lucky for that, we may only see the certificate alert.

00:22:31.240 --> 00:22:32.000
‑‑Right, right.

00:22:32.000 --> 00:22:32.980
And that's, again,

00:22:32.980 --> 00:22:37.160
that's the challenge with these detections is that if that IP

00:22:37.160 --> 00:22:39.180
address isn't being tracked and reported,

00:22:39.180 --> 00:22:42.050
and we don't have good fidelity on that,

00:22:42.060 --> 00:22:44.050
then we lose the visibility.

00:22:44.060 --> 00:22:45.840
Same with the certificate.

00:22:45.850 --> 00:22:49.170
The certificates obviously can change, they can be set up,

00:22:49.540 --> 00:22:54.580
they can get changed out as with all of the infrastructure that they're using.

00:22:54.590 --> 00:22:59.440
And so a lot of the detections are very reactive.

00:22:59.440 --> 00:23:03.110
We don't know that there's a new C2 node until there's a new C2 node.

00:23:03.110 --> 00:23:06.050
We don't know that they changed their TLS cert until they change their TLS cert.

00:23:06.050 --> 00:23:07.500
We can try to be generic,

00:23:07.500 --> 00:23:11.180
and that's one of the things that some of the detections that

00:23:11.180 --> 00:23:13.830
we create hope to be is that we can say,

00:23:13.830 --> 00:23:13.920
All right,

00:23:13.920 --> 00:23:19.330
if we see a lot of high entropy content in the name of the TLS certificate,

00:23:19.330 --> 00:23:20.800
well, that seems a bit odd.

00:23:20.800 --> 00:23:22.850
So let's try to be proactively alerting on that.

00:23:23.240 --> 00:23:24.130
But, again,

00:23:24.130 --> 00:23:29.900
it's not a 100% way of ensuring coverage of preventing any sort of activity.

00:23:29.910 --> 00:23:33.640
So we have to take all this stuff and kind of combine it together and

00:23:33.640 --> 00:23:37.510
layer it together and hope that through all of it,

00:23:37.510 --> 00:23:38.560
we are effective.

00:23:40.040 --> 00:23:42.190
Let's look at both of the detections.

00:23:42.190 --> 00:23:47.580
The first one is the Command and Control, that Feodo Tracker, that's IP rep.

00:23:47.580 --> 00:23:49.230
And here is the rule.

00:23:49.230 --> 00:23:54.630
It's actually pretty straightforward in that if you look

00:23:54.630 --> 00:23:56.770
at the very beginning of an IDS rule,

00:23:56.780 --> 00:23:59.560
the first verb is just what it's supposed to do,

00:23:59.560 --> 00:24:01.450
alert or drop or reject.

00:24:01.450 --> 00:24:03.110
It's that action that it takes.

00:24:03.110 --> 00:24:06.560
The default is just to alert so it doesn't modify the traffic.

00:24:06.940 --> 00:24:09.740
The next is what is it looking at?

00:24:09.750 --> 00:24:11.230
So we're looking at IPs.

00:24:11.240 --> 00:24:13.550
And then from there at the very end of the rule,

00:24:13.550 --> 00:24:17.730
we see IP rep, and there's some dst, a unique number,

00:24:17.730 --> 00:24:19.540
a greater‑than sign, and a 1,

00:24:19.540 --> 00:24:23.530
and that is just simply saying that in the configuration for,

00:24:23.530 --> 00:24:28.360
in this case, Suricata, it's been configured to use an IP reputation list.

00:24:28.640 --> 00:24:34.460
And if this IP is on that list, then generate this alert.

00:24:35.640 --> 00:24:36.090
Okay,

00:24:36.100 --> 00:24:40.180
the last rule is‑‑‑you can just eyeball this one and

00:24:40.180 --> 00:24:41.750
see it's a lot more complicated.

00:24:42.280 --> 00:24:44.000
It is just an alert rule.

00:24:44.000 --> 00:24:47.470
Again, you can modify those as you see fit in your environment,

00:24:47.480 --> 00:24:48.930
but it's looking for just TLS.

00:24:48.930 --> 00:24:52.860
And it's not bound to TLS on a certain port.

00:24:52.860 --> 00:24:56.020
It's bound to any TLS session that the engine identifies.

00:24:56.020 --> 00:24:59.360
How this one is being matched is a bit more generic,

00:24:59.370 --> 00:25:03.450
like I had mentioned, in that they're using the PCREs,

00:25:03.450 --> 00:25:05.520
the PERL Compatible Regular Expressions,

00:25:05.520 --> 00:25:12.030
to try to write a more generic enough pattern to‑‑‑you don't want a

00:25:12.030 --> 00:25:16.640
signature to be so precise that it only alerts on one TLS cert.

00:25:16.640 --> 00:25:19.470
If it does that, then they make a change,

00:25:19.480 --> 00:25:23.030
one small change to it, and now that alert is no longer good.

00:25:23.030 --> 00:25:26.180
And so trying to make something a bit more generic,

00:25:26.180 --> 00:25:32.420
particularly as it associates with how a particular threat actor is operating,

00:25:32.430 --> 00:25:34.530
that's what they're attempting to do here.

00:25:34.530 --> 00:25:36.430
So this one, these are a challenge.

00:25:36.440 --> 00:25:37.730
I can't look at that.

00:25:37.730 --> 00:25:42.040
My ability to just process regular expressions on the fly just never existed.

00:25:42.040 --> 00:25:43.610
It's like trying to solve a Rubik's cube.

00:25:43.610 --> 00:25:46.670
It's like that part of my brain just never developed.

00:25:46.680 --> 00:25:48.750
And so I can't just look at that and say,

00:25:48.750 --> 00:25:50.990
Oh, it's obviously matching on this pattern.

00:25:50.990 --> 00:25:53.050
That one takes a while to really digest.

00:25:53.050 --> 00:25:59.050
But it shows how, on one hand, rules can be very strict,

00:25:59.050 --> 00:26:02.420
and then on the other, they can be a bit more broad.

00:26:02.420 --> 00:26:09.260
So, again, it's really up to you to decide how to use this information,

00:26:09.260 --> 00:26:11.090
how to create detections in your environment.

00:26:11.090 --> 00:26:15.000
‑‑Well, hopefully‑‑‑I'm not a regex ranger either,

00:26:15.000 --> 00:26:18.680
but, hopefully, if we have viewers out there,

00:26:18.690 --> 00:26:24.150
someone is highly focused on regex in their group.

00:26:24.150 --> 00:26:26.920
Like me, I'm just like, I don't know, let me go test it on,

00:26:26.920 --> 00:26:30.180
there's that Java site where you can test your regex to make sure it works,

00:26:30.180 --> 00:26:31.420
and let me just make sure this works.

00:26:31.420 --> 00:26:33.390
And that's every single time for me.

00:26:33.390 --> 00:26:35.290
Like I have zero confidence in my regex abilities.

00:26:35.290 --> 00:26:39.680
But, ideally, someone's sitting there making this happen,

00:26:39.680 --> 00:26:43.600
and in a lot of cases, especially when you see like the capital A to Z,

00:26:43.600 --> 00:26:44.900
lowercase a to z, it's like, okay,

00:26:44.900 --> 00:26:47.660
well, that's the whole known character set uppercase and

00:26:47.660 --> 00:26:50.970
lowercase and 0 to 4 of these letters, that kind of thing.

00:26:50.970 --> 00:26:55.550
But one thing we get to here and ahead of what you're trying to

00:26:55.560 --> 00:26:58.330
get to is if they are randomly generated,

00:26:58.340 --> 00:27:02.000
we can look at something like string entropy for the fields that are

00:27:02.000 --> 00:27:04.700
randomly generated and attempt to try to use that.

00:27:04.700 --> 00:27:06.670
So it's not like known words and that kind of stuff.

00:27:06.670 --> 00:27:07.070
‑‑Yeah,

00:27:07.070 --> 00:27:10.530
and it's also important to note that the rules are

00:27:10.530 --> 00:27:13.530
only as effective as the author.

00:27:13.530 --> 00:27:16.000
And so not all rules are created equal.

00:27:16.000 --> 00:27:22.460
So you can't always just assume that what you're receiving is 100% awesome.

00:27:22.470 --> 00:27:27.260
You do want to give it a critical eye before deploying it in

00:27:27.260 --> 00:27:30.950
production or using it as the basis that creates something

00:27:31.140 --> 00:27:32.270
custom for your environment.

00:27:32.840 --> 00:27:34.680
‑‑Yeah, and so from a network perspective,

00:27:34.680 --> 00:27:38.100
that's us looking at certificates and kind of understanding the way that those

00:27:38.100 --> 00:27:42.300
are filled out, what's always interesting to me is I'm mentally tying that to

00:27:42.300 --> 00:27:44.590
someone in a chair filling out the certificate.

00:27:44.590 --> 00:27:47.260
And sometimes its automated, but at some point,

00:27:47.260 --> 00:27:50.010
someone had to make the automated tool to generate the certificates.

00:27:50.010 --> 00:27:52.150
And so they had to like‑‑‑we're basically just making

00:27:52.150 --> 00:27:55.310
regex that describes how they type.

00:27:55.320 --> 00:27:57.280
And so they thought it was really cool to use four

00:27:57.280 --> 00:27:59.200
letters first and then do this.

00:27:59.210 --> 00:28:02.730
And so it's really just kind of modeling human behavior,

00:28:02.730 --> 00:28:04.440
which is always interesting to me.

00:28:04.450 --> 00:28:10.000
That being said, computers are a lot more predictable in my mind.

00:28:10.010 --> 00:28:13.820
And so one thing that we did see was on the endpoint,

00:28:13.820 --> 00:28:16.910
and just to give a little bit of endpoint perspective for detection,

00:28:16.910 --> 00:28:19.070
is this process execution change.

00:28:19.070 --> 00:28:22.570
And not that they can't change, but there are only so many LOLBins,

00:28:22.570 --> 00:28:28.420
or living off the land binaries, that can execute other code or execute a file.

00:28:28.420 --> 00:28:32.330
And so there's kind of an inherently small list that

00:28:32.330 --> 00:28:34.040
we can detect onto that behavior.

00:28:34.170 --> 00:28:36.440
Now, this isn't like 100% test or anything,

00:28:36.440 --> 00:28:39.280
but I'm going to share this in the exercise documents.

00:28:39.280 --> 00:28:42.690
I want everybody to be able to have the idea of what we were talking about.

00:28:42.690 --> 00:28:46.900
Now super basic, again, but if you're looking to detect this on a device,

00:28:46.900 --> 00:28:49.460
or you can shove this out to a bunch of devices,

00:28:49.640 --> 00:28:51.460
feel free to modify this as you see fit.

00:28:51.840 --> 00:28:56.000
I'm going to get stuff to yell at me because I use aliases 100% of the time,

00:28:56.000 --> 00:28:58.180
and 100% of the time, it tells me that they're going to break,

00:28:58.180 --> 00:28:58.920
and they never do.

00:28:58.930 --> 00:29:00.930
They haven't broken for 10 years, and they've been fine.

00:29:00.940 --> 00:29:04.610
So I'm going to continue to use these aliases.

00:29:04.610 --> 00:29:05.290
But, basically,

00:29:05.290 --> 00:29:08.310
what we're saying here is I'm setting different variables and

00:29:08.310 --> 00:29:10.420
then waiting to see if those variables are true,

00:29:10.420 --> 00:29:11.450
and it'll write out, Hey,

00:29:11.450 --> 00:29:14.800
we've got some Dridex detectors and indicators detected.

00:29:14.800 --> 00:29:18.150
And we're, just like you mentioned before,

00:29:18.160 --> 00:29:23.640
we can look at, hey, I'm sharing the right screen.

00:29:23.650 --> 00:29:29.590
‑‑Yeah, I see, it looks like Visual Studio.

00:29:29.590 --> 00:29:29.960
‑‑Perfect.

00:29:30.940 --> 00:29:31.220
Okay.

00:29:31.230 --> 00:29:34.050
The main thing we're looking for here is the command lines

00:29:34.050 --> 00:29:37.490
that are executed kind of with some variance.

00:29:37.490 --> 00:29:42.320
And, again, if we use like here, at least in PowerShell, we get rid of the case.

00:29:42.320 --> 00:29:46.300
So this will, especially when we're looking for WMIC,

00:29:46.300 --> 00:29:48.440
if we're looking for WMIC running,

00:29:48.440 --> 00:29:50.560
it's going to catch it whether whatever the case may be.

00:29:50.560 --> 00:29:53.410
So that's just one thing to look at when you run these kind of things.

00:29:53.410 --> 00:29:55.090
And, yes, this does apply to other stuff.

00:29:55.090 --> 00:29:58.750
And so there's kind of one that matched one of the samples that we were

00:29:58.750 --> 00:30:01.510
looking at and one that matches the other samples.

00:30:01.510 --> 00:30:03.090
Really, its phases of execution,

00:30:03.090 --> 00:30:07.730
are we at the point where Excel is using DDE to launch another file?

00:30:07.730 --> 00:30:09.630
Is Excel the parent process?

00:30:09.630 --> 00:30:11.390
That's the more high fidelity.

00:30:11.390 --> 00:30:13.820
And so that's why that's the requirement.

00:30:13.820 --> 00:30:19.530
So #3 is, Does the parent process of rundll launch WMIC.

00:30:19.530 --> 00:30:23.100
And then we can, in addition to the other indicators that are all there,

00:30:23.100 --> 00:30:27.730
that's something kind of real quick that we can launch to try to detect that.

00:30:27.730 --> 00:30:30.210
And then the same thing for if we happen to catch it

00:30:30.210 --> 00:30:36.100
with Excel; #6 there is saying, Does Excel launch regsvr.

00:30:36.100 --> 00:30:40.090
And that's kind of what we're looking at while simultaneously launching and

00:30:40.090 --> 00:30:42.940
looking at the command line that's used to see if DDE is used.

00:30:42.940 --> 00:30:43.750
So, again,

00:30:43.750 --> 00:30:47.440
always to say just because that happens doesn't mean it's something bad,

00:30:47.440 --> 00:30:49.900
but the more indicators we can get successively,

00:30:49.900 --> 00:30:51.540
kind of even like a YARA rule.

00:30:51.550 --> 00:30:57.210
So this is like a YARA rule for process execution on Windows to say,

00:30:57.210 --> 00:31:00.510
If all of these are true, it's even more likely that it's bad.

00:31:00.510 --> 00:31:02.020
And that's what this goes after.

00:31:02.020 --> 00:31:03.500
So this will be available.

00:31:03.500 --> 00:31:08.300
You can run this on Windows and modify it as you see fit in the exercise files.

00:31:08.300 --> 00:31:10.810
I wanted to just present that real quick to get a

00:31:10.810 --> 00:31:13.650
little bit of an endpoint perspective.

00:31:13.650 --> 00:31:18.130
And then even as we talk about the endpoint piece,

00:31:18.140 --> 00:31:21.340
really, a lot of these detections are if you find it,

00:31:21.340 --> 00:31:22.330
what does that mean?

00:31:22.330 --> 00:31:23.690
What happens if we actually find this?

00:31:23.690 --> 00:31:25.250
Like we're in deduction mode, we find it,

00:31:25.250 --> 00:31:28.780
that means we're infected, and we have to go to incident response mode.

00:31:28.780 --> 00:31:31.530
So that's what we're going to talk about next.

00:31:31.530 --> 00:31:35.280
How do we leverage these detections to help us with our incident response,

00:31:35.280 --> 00:31:36.660
and what do we do to clean this up?
