[00:00.000 --> 00:03.900] My name is Connor Morley. This is Lacey Fan. We are Threat Hunters with Cantercept. [00:03.900 --> 00:06.780] And we're going to be doing a presentation here about Killsuit. [00:07.080 --> 00:09.260] So, what exactly are we going to be covering today? [00:09.260 --> 00:13.020] We're going to be covering what Killsuit is, what it does, [00:13.020 --> 00:17.240] what happens when it's installed into a system, how to detect and remediate Killsuit, [00:17.240 --> 00:20.720] how Killsuit persists in the system using advanced bootkit Solartime, [00:20.720 --> 00:23.560] and how to detect and remediate a Solartime infection. [00:23.920 --> 00:28.060] So, first things first, what exactly is Killsuit? [00:28.060 --> 00:31.200] So, Killsuit is a post exploitation framework [00:31.200 --> 00:33.720] that was developed by the Equation Group prior to 2013 [00:34.380 --> 00:38.360] and leaked by the Shadow Brokers in the Lost in Translation leak in 2017. [00:38.900 --> 00:41.320] It's supposedly developed by the Equation Group, [00:41.320 --> 00:45.680] which are strongly associated with the NSA, although not confirmed, [00:45.680 --> 00:49.220] so it's likely a state-sponsored actor-level attack framework. [00:49.340 --> 00:51.920] We know this is in the Dan Spitz framework, which was inside the leak, [00:51.920 --> 00:56.020] and United Rake, which has direct references to it inside its instruction manual. [00:56.020 --> 00:59.880] So, this is basically an overview of what Killsuit is. [00:59.880 --> 01:02.740] So, what exactly does Killsuit do? [01:03.040 --> 01:09.540] So, as we mentioned earlier, it is a post-exploitation modular capability mechanism. [01:09.540 --> 01:13.880] It's a bit of a mouthful, but we've done a diagram to basically outline what this means. [01:14.640 --> 01:21.060] Effectively, the Dan de Spitz framework uses the Fuzzy Bunch exploitation collection [01:21.060 --> 01:25.660] in order to pwn a victim, to install a pedal-cheap agent, [01:25.660 --> 01:30.940] which is their advanced C2 channel, which then allows them to install a Killsuit instance, [01:30.940 --> 01:34.660] which has underlying Killsuit modules, which allows for a certain functionality. [01:35.180 --> 01:37.320] Now, the modules all have individual functionalities, [01:37.320 --> 01:39.740] and the instances have individual functionalities. [01:40.460 --> 01:43.620] They can't hear me. Do you hear me now? [01:43.860 --> 01:46.280] Yeah? All right, fantastic. Sorry about that. [01:46.920 --> 01:48.060] Where was I? [01:48.060 --> 01:51.560] Yep, so the individual modules all have individual capabilities, [01:51.560 --> 01:52.960] and so do all the instances. [01:52.960 --> 01:56.360] Some of these can include persistence of the pedal-cheap agent, [01:56.360 --> 01:59.680] which is a priority for the Dan de Spitz framework, [01:59.680 --> 02:02.400] as this allows persistence of their C2 channel inside the victim. [02:02.600 --> 02:05.040] Each instance and module type has a different codename. [02:05.040 --> 02:07.800] This is a list of the codenames that we know about. [02:08.300 --> 02:10.060] They all have different functionalities, [02:10.060 --> 02:14.160] such as Strangeland, which is a covert keylogger, [02:14.160 --> 02:17.200] Magic Bean, which is a Wi-Fi man-in-the-middle attack [02:18.480 --> 02:22.220] capability enablement, or DarkSky, which is a packet capture utility, [02:22.220 --> 02:23.660] which is a module type. [02:23.660 --> 02:25.960] Now, we've gone over modules and instances. [02:26.180 --> 02:28.380] Basically, this is the way that they fit together. [02:28.480 --> 02:32.200] So, you can have instance types which have individual capabilities, [02:32.200 --> 02:34.580] but you can install separate modules under them, [02:34.580 --> 02:37.820] which allows multiple instances to have the same capability. [02:37.980 --> 02:41.940] So, in this diagram, you can see that SOKN, which is Sombernave, [02:41.940 --> 02:45.980] and WRWA, which is Wraithwrath, both have the DarkSky module installed, [02:45.980 --> 02:50.220] which means that both instances have the capability to do packet capture. [02:50.440 --> 02:54.380] Whereas, Magic Bean and Sombernave, which are the two on the left, [02:54.380 --> 02:56.880] the one on the left has FluAvenue, which is Flav, [02:56.880 --> 03:00.340] which is the IPv4 custom-made IPvTCP stack [03:00.340 --> 03:02.660] that the guys use in order to avoid detection, [03:02.660 --> 03:06.420] and DMGZ, which is Doorman Gores, which is the IPv6 variant. [03:06.600 --> 03:10.040] So, you can have lots of instance types which have different capabilities, [03:10.040 --> 03:12.620] and you can install separate modules under them [03:12.620 --> 03:16.400] to have either repeated or specific functionality. [03:16.840 --> 03:18.940] You see on the right, we also added custom modules. [03:18.940 --> 03:23.220] That's because the Kilsu module library had the capacity to add new modules, [03:23.700 --> 03:26.300] but we didn't actually find how they built these things [03:26.300 --> 03:27.720] or the sort of language they used. [03:27.720 --> 03:29.600] They used a custom scripting language to begin with, [03:29.600 --> 03:31.100] and then moved over to Python. [03:31.240 --> 03:34.100] So, although it has the capacity to load new modules [03:34.100 --> 03:35.440] that have never been seen before, [03:35.440 --> 03:37.580] we couldn't actually find a way to build these or put them in. [03:37.580 --> 03:40.140] So, if anyone wants to have a poke at that, that'd be great. [03:40.700 --> 03:42.700] For the main research for this, [03:42.700 --> 03:44.800] for the instance types and the module capabilities, [03:44.900 --> 03:47.420] a guy, Francisco Donoso, is the one pioneering this. [03:47.420 --> 03:48.940] So, we do recommend looking at his work, [03:48.940 --> 03:50.980] because that's basically where he focuses. [03:51.120 --> 03:54.520] We, however, are focused on basically detection of Kilsu [03:54.520 --> 03:56.080] when it's installed on a system. [03:56.140 --> 03:58.300] So, we are going to look at what happens [03:58.300 --> 04:01.660] when Kilsu is actually installed on a system. [04:01.840 --> 04:04.880] So, we did this by obviously creating lots of victim machines [04:04.880 --> 04:06.160] and an operating machine, [04:06.160 --> 04:07.440] pwning using Fuzzy Bunch, [04:07.440 --> 04:09.900] and then installing Kilsu to see exactly what happened. [04:10.640 --> 04:14.600] For an example, so, we had to condense this down, [04:14.600 --> 04:15.900] but one of the main things that we saw [04:15.900 --> 04:19.280] was that we injected into a calculator process [04:19.280 --> 04:21.120] using DoublePulsar, [04:21.460 --> 04:26.040] and this created this sort of action when Kilsu was installed. [04:26.040 --> 04:27.680] I call this the Jones-Bond function, [04:27.680 --> 04:31.120] but basically it's an HTML hash generation, [04:31.120 --> 04:32.580] which happens inside Calculator, [04:32.580 --> 04:34.080] which, as you might imagine, [04:34.080 --> 04:37.560] there's no reason it should be generating hashes inside Calculator. [04:37.560 --> 04:39.240] Now, that's anomalous, [04:39.240 --> 04:42.200] only in processes that shouldn't do it. [04:42.240 --> 04:44.020] So, by default, [04:44.020 --> 04:45.720] Dynasphere is actually injecting to Lsas, [04:45.720 --> 04:48.460] so Lsas generating hashes is not so anomalous, [04:48.460 --> 04:49.680] Calculator is very anomalous. [04:49.680 --> 04:52.700] So, depending on where the operator decides to inject into, [04:52.700 --> 04:54.240] it's quite detectable or not, [04:54.240 --> 04:55.580] so it's not a be-all, end-all. [04:55.580 --> 04:58.420] However, what it then did with that hash was more interesting. [04:58.420 --> 05:03.220] So, we actually traced where that hash was used inside the process, [05:03.220 --> 05:05.240] and we found that it basically was used [05:05.240 --> 05:08.640] to inject or modify this registry key, [05:08.640 --> 05:10.040] OEM Management. [05:10.040 --> 05:12.600] Now, OEM Management doesn't actually exist. [05:12.600 --> 05:17.100] There's no real reference to that registry key that we could find. [05:17.240 --> 05:19.340] And we found that that's actually where it installed [05:19.340 --> 05:22.460] the encrypted Kilsu database, [05:22.460 --> 05:25.640] where it basically installed its capabilities. [05:25.740 --> 05:26.720] Now, in the bottom there, [05:26.720 --> 05:29.320] you'll see that we've got a KSModuleStoreRoot. [05:29.320 --> 05:31.580] This was basically generated using an internal tool [05:31.580 --> 05:34.000] for the framework called DoubleFeature. [05:34.000 --> 05:35.740] DoubleFeature is used by the operators [05:35.740 --> 05:37.240] in order to basically verify [05:37.240 --> 05:38.800] what is already on their system [05:38.800 --> 05:40.120] in a network that's being attacked. [05:40.120 --> 05:41.760] So, the two operators don't necessarily [05:41.760 --> 05:42.900] pwn the same machine. [05:42.900 --> 05:44.820] They can see if something's already been installed. [05:45.140 --> 05:46.400] Now, the KSModuleStoreRoot [05:46.400 --> 05:48.300] actually corresponds to OEM Management. [05:48.300 --> 05:49.300] Obviously, in this slide, [05:49.300 --> 05:51.660] the ones with key eyes can see that it doesn't match. [05:51.720 --> 05:53.280] And the reason for that is, [05:53.280 --> 05:56.160] there are a lot of variations about where it put this. [05:56.160 --> 05:58.760] These are just some of the registry locations [05:58.760 --> 06:00.760] that we found while experimenting. [06:01.160 --> 06:03.420] Now, you might see that the second half, [06:03.420 --> 06:06.520] CACHE, CFG, CONFIG is actually repeated. [06:06.620 --> 06:08.360] And it's split by a capital letter. [06:08.360 --> 06:09.480] Now, we found that actually, [06:09.480 --> 06:10.380] the first half and second half [06:10.380 --> 06:12.220] were actually repeated quite frequently. [06:12.220 --> 06:15.440] And eventually, it started to basically recur on itself. [06:15.440 --> 06:16.480] So, we came to the conclusion [06:16.480 --> 06:18.660] that this was more or less two lists [06:18.660 --> 06:20.160] that were being concatenated together [06:20.160 --> 06:24.580] and randomly or systematically selected at installation. [06:24.580 --> 06:26.520] So, we concluded that if we could find these two lists [06:26.520 --> 06:28.760] with inside the framework or the binary, [06:28.760 --> 06:30.380] we could therefore generate every combination [06:30.380 --> 06:33.760] and have an easy IOC identifier [06:33.760 --> 06:34.900] for where the kill C was installed [06:34.900 --> 06:36.160] and basically just sweep registries [06:36.160 --> 06:37.540] to be able to find this. [06:37.860 --> 06:40.000] We wanted to prove that this was what we thought, [06:40.000 --> 06:42.520] and we did this by finding the concatenation operation. [06:42.800 --> 06:44.620] So, we found that the registry location [06:44.620 --> 06:46.040] had two separate strings [06:46.040 --> 06:47.120] that were then concatenated together [06:47.120 --> 06:48.400] and then added to the end of the registering [06:48.400 --> 06:50.880] to verify that this was in fact what we thought it was. [06:50.980 --> 06:51.860] So, hooray. [06:51.860 --> 06:53.280] So, we broke down basically [06:53.280 --> 06:54.140] where we're going to investigate [06:54.140 --> 06:55.760] to try and find these lists. [06:55.780 --> 06:57.360] And it broke down into three areas. [06:57.360 --> 06:59.280] Basically, whether the communic- [06:59.280 --> 07:00.980] whether the operator's framework [07:00.980 --> 07:02.240] communicated the location [07:02.240 --> 07:04.740] to the active, uh, Petalchip agent [07:04.740 --> 07:06.200] to install the kill suit. [07:06.200 --> 07:07.500] Whether the Petalchip agent, [07:07.500 --> 07:08.500] when it was in its DLL form [07:08.500 --> 07:10.300] before being injected by DoublePulsar, [07:10.300 --> 07:11.400] had it hard-coded. [07:11.480 --> 07:13.320] Or whether the payload, uh, [07:13.320 --> 07:15.800] the Petalchip agent had both lists already in it [07:15.800 --> 07:18.560] and then decided basically to put, uh, [07:18.560 --> 07:22.700] on the victim's, uh, victim system variables [07:22.700 --> 07:24.720] what options it was going to pick. [07:24.720 --> 07:26.300] Now, we very quickly eliminated [07:26.300 --> 07:28.080] that it was hard-coded into the payload [07:28.080 --> 07:29.600] because reuse of the payload [07:29.600 --> 07:30.700] didn't generate the same result [07:30.700 --> 07:31.920] so it still was randomized. [07:32.060 --> 07:33.660] So, definitely not hard-coded. [07:33.760 --> 07:35.360] So, we started looking at, uh, [07:35.360 --> 07:36.900] whether it was communicated from the attacker. [07:36.900 --> 07:37.800] Now, in order to do this, [07:37.800 --> 07:39.800] we had to basically break down, uh, [07:39.800 --> 07:42.300] how the commands were used [07:42.300 --> 07:43.900] inside the- inside the framework [07:43.900 --> 07:45.920] and how it was then transmitted to the agent. [07:46.080 --> 07:47.860] And it- it breaks down to this. [07:48.260 --> 07:49.640] The Dynaspirit's user interface [07:49.640 --> 07:51.900] was then communicated to Demi library [07:51.900 --> 07:53.160] which is decibel minute. [07:53.440 --> 07:54.700] Uh, this was then handed off [07:54.700 --> 07:56.280] to the Dynaspirit or DSZ library [07:56.280 --> 07:58.020] which in turn communicated [07:58.020 --> 08:00.000] with the primary, uh, the primary binary [08:00.000 --> 08:02.940] which is the DD-DDZS core, uh, SC core [08:02.940 --> 08:04.060] which communicated with the [08:04.060 --> 08:05.340] prototype agent inside the victim [08:05.340 --> 08:07.200] which then, uh, enacted, uh, [08:07.200 --> 08:08.520] kill suit capabilities. [08:08.880 --> 08:11.340] So, we looked at the decibel minute library [08:11.860 --> 08:12.920] to start with. [08:12.920 --> 08:14.320] Uh, we quickly came to the conclusion [08:14.320 --> 08:15.520] that decibel minute, uh, [08:15.520 --> 08:17.700] was actually used for all of the, uh, [08:17.700 --> 08:19.020] kill suit operations. [08:19.100 --> 08:21.040] One of the libraries that this one is inside, [08:21.040 --> 08:21.720] the handle connects, [08:21.720 --> 08:23.660] is actually, um, uh, [08:23.660 --> 08:25.540] is responsible for, uh, [08:25.540 --> 08:27.500] dynamically loading and unload module drivers [08:27.500 --> 08:29.320] inside a kill suit instance. [08:29.320 --> 08:31.400] So, this particular, uh, function [08:31.400 --> 08:33.760] allows for, um, changing of the modules [08:33.760 --> 08:35.480] inside an active kill suit instance. [08:35.580 --> 08:37.500] But, from the bit that I've highlighted, [08:37.500 --> 08:39.160] you can see that it actually hands off, [08:39.160 --> 08:41.700] uh, to a, uh, MCL dot tasking [08:41.700 --> 08:43.060] RPC perform call. [08:43.060 --> 08:45.120] And this is inside the Dynaspirit library. [08:45.320 --> 08:47.820] Now, the DSZ library in turn [08:47.820 --> 08:49.820] calls a hidden underscore, [08:49.820 --> 08:51.880] uh, private underscore DSZ library. [08:51.880 --> 08:52.740] Now, this is where we actually [08:52.740 --> 08:54.240] run into a bit of a problem. [08:54.240 --> 08:55.440] The underscore DSZ library [08:55.440 --> 08:56.260] and the functions inside it [08:56.260 --> 08:57.460] were nowhere inside the framework [08:57.460 --> 08:58.480] that we could find. [08:58.480 --> 09:00.060] So, all of the libraries were, uh, [09:00.060 --> 09:01.820] Python based and this underscore [09:01.820 --> 09:02.800] or any of the functions [09:02.800 --> 09:04.240] were not in there. [09:04.240 --> 09:05.580] And that created a real problem [09:05.580 --> 09:06.780] because this was primary [09:06.780 --> 09:07.960] to how it communicates [09:07.960 --> 09:09.320] with the pedal cheap agent. [09:09.520 --> 09:11.300] So, we started looking, [09:11.300 --> 09:12.140] because we couldn't find it [09:12.140 --> 09:13.500] inside the framework itself, [09:13.500 --> 09:14.980] we started looking in the binary. [09:15.340 --> 09:17.180] We, uh, sadly analyzed the binary [09:17.180 --> 09:18.860] and we found that it did have error captures [09:18.860 --> 09:20.960] for particular functions inside, [09:20.960 --> 09:21.700] that we knew were inside [09:21.700 --> 09:22.540] this private library. [09:22.540 --> 09:24.560] But the, uh, function locations [09:24.560 --> 09:25.240] that we found for them [09:25.240 --> 09:26.440] were all empty. [09:26.640 --> 09:28.060] So, a bit more extra research [09:28.060 --> 09:29.300] by one of our colleagues, [09:29.300 --> 09:30.360] Alex Kornitsa, [09:30.360 --> 09:31.640] uh, found that it was in fact [09:31.840 --> 09:33.080] a C Python module library [09:33.080 --> 09:34.320] that was loaded at runtime, [09:34.320 --> 09:35.120] which is why we couldn't [09:35.120 --> 09:36.140] find it statically. [09:36.220 --> 09:37.360] So, although we were trying [09:37.360 --> 09:38.240] to statically analyze it, [09:38.240 --> 09:39.100] it wasn't there. [09:39.100 --> 09:40.680] So, we moved on to dynamic analysis [09:40.680 --> 09:41.340] of the binary, [09:41.340 --> 09:42.020] but we ran into even [09:42.020 --> 09:42.900] secondary problems. [09:42.900 --> 09:44.320] Now, whoever built this tool, [09:44.320 --> 09:45.560] uh, the equation group, [09:45.560 --> 09:46.900] um, they really didn't want [09:46.900 --> 09:47.720] this being analyzed. [09:47.720 --> 09:48.760] They put in quite a lot of things [09:48.760 --> 09:50.420] to prevent us from analyzing it. [09:50.420 --> 09:51.640] One of them was that it detect- [09:51.640 --> 09:53.380] detected debug hookers, [09:53.380 --> 09:54.520] and if it found one, [09:54.520 --> 09:55.860] it would instantly terminate. [09:55.980 --> 09:57.180] So, that was just an indicator [09:57.180 --> 09:58.260] of they don't want us [09:58.260 --> 09:59.180] looking at this. [09:59.180 --> 09:59.920] We were actually able [09:59.920 --> 10:01.040] to hide the debugger [10:01.040 --> 10:02.500] and get it to run anyway, [10:02.500 --> 10:03.500] but all the memory locations [10:03.500 --> 10:04.060] that we found that were [10:04.060 --> 10:05.220] allocated to the function, [10:05.220 --> 10:06.300] including the index root [10:06.300 --> 10:07.380] for the functions, [10:07.380 --> 10:08.140] there were multiple, [10:08.140 --> 10:09.480] and a lot of them were dummies. [10:09.560 --> 10:10.620] And even the locations [10:10.620 --> 10:11.340] for the variables, [10:11.340 --> 10:12.240] we found that the data [10:12.240 --> 10:12.940] was either loaded [10:12.940 --> 10:13.760] and unloaded so quickly [10:13.760 --> 10:14.440] we couldn't find it, [10:14.440 --> 10:15.100] or we couldn't find [10:15.100 --> 10:16.020] the true variable [10:16.020 --> 10:17.340] that was actually looking for, [10:17.340 --> 10:19.340] which was extremely annoying. [10:19.340 --> 10:20.740] So, we actually reached [10:20.740 --> 10:22.580] the capability of our analysis, [10:22.580 --> 10:23.500] and we had to conclude [10:24.080 --> 10:25.240] we don't know if it's there, [10:25.240 --> 10:26.940] which was very unfortunate. [10:27.080 --> 10:28.840] So, we came to the conclusion of, [10:28.840 --> 10:29.720] although we've got to the end [10:29.720 --> 10:30.920] of our capability, [10:30.920 --> 10:32.180] we're not sure it's there, [10:32.180 --> 10:33.120] but if we can eliminate [10:33.120 --> 10:34.340] that it's inside the payload, [10:34.340 --> 10:35.200] at least we can focus [10:35.200 --> 10:36.600] on one particular area. [10:36.680 --> 10:37.580] So, we moved on to where [10:37.580 --> 10:38.700] the payload was deciding it [10:38.700 --> 10:40.580] from environmental variables [10:40.580 --> 10:41.700] inside the target. [10:41.700 --> 10:42.680] However, this created [10:42.680 --> 10:44.080] another set of problems. [10:44.220 --> 10:45.680] So, the binary, [10:45.680 --> 10:46.460] when it's injected, [10:46.460 --> 10:47.760] is actually encrypted, [10:47.760 --> 10:49.940] and in looking at the stack [10:49.940 --> 10:51.340] of the process injected into, [10:51.340 --> 10:52.420] the variables we were looking for [10:52.420 --> 10:53.900] for kill suit operations, [10:53.900 --> 10:54.960] where instead of being, [10:54.960 --> 10:55.920] as far as we can tell, [10:55.920 --> 10:56.560] instead of being injected [10:56.560 --> 10:57.240] into the process, [10:57.240 --> 10:58.800] we're injected into kernel data. [10:58.920 --> 11:00.100] Now, we couldn't figure out [11:00.100 --> 11:00.600] how it did it, [11:00.600 --> 11:01.260] we couldn't figure out [11:01.260 --> 11:02.100] why it did it, [11:02.100 --> 11:02.920] and we couldn't extract [11:02.920 --> 11:04.180] the variables we were looking for, [11:04.180 --> 11:05.180] which, again, created [11:05.180 --> 11:06.280] the situation of, [11:06.860 --> 11:08.260] we don't know if it's there, [11:08.260 --> 11:10.620] which made us very upset. [11:11.160 --> 11:12.520] So, although this came [11:12.520 --> 11:13.180] to the conclusion of, [11:13.180 --> 11:14.560] we have a lot of [11:15.320 --> 11:16.040] possible variations [11:16.040 --> 11:17.220] of the combination [11:17.220 --> 11:18.060] of the two lists we have, [11:18.060 --> 11:19.060] we couldn't actually find [11:19.060 --> 11:20.480] the two lists within the system. [11:20.480 --> 11:21.820] Now, if anyone does have [11:21.820 --> 11:22.820] expertise in this area, [11:22.820 --> 11:24.220] please talk to me, [11:24.220 --> 11:25.320] because we really want to [11:25.320 --> 11:25.960] find this list, [11:25.960 --> 11:26.580] because that would be [11:27.100 --> 11:28.200] really awesome. [11:28.200 --> 11:29.360] But, although we couldn't [11:29.360 --> 11:30.280] find these two lists [11:30.280 --> 11:30.880] we were looking for, [11:30.880 --> 11:31.800] we didn't let it stop us, [11:31.800 --> 11:33.000] and we carried on anyway. [11:33.620 --> 11:34.680] And in doing so, [11:34.680 --> 11:36.100] we came across this, [11:36.100 --> 11:37.500] which we found was, [11:37.840 --> 11:38.600] a check that was made [11:38.600 --> 11:39.520] against every fresh [11:39.520 --> 11:40.680] kill suit installation [11:40.680 --> 11:42.020] on a fresh, [11:42.020 --> 11:42.980] petal cheap instance [11:42.980 --> 11:44.100] on site of victim. [11:44.140 --> 11:45.080] And it does this, [11:45.600 --> 11:46.680] cryptographic default [11:46.680 --> 11:46.980] provider type [11:46.980 --> 11:47.980] of type 023 [11:47.980 --> 11:49.480] registry check. [11:49.580 --> 11:50.760] Now, the first thing [11:50.760 --> 11:51.520] of noting is, [11:51.520 --> 11:52.300] what exactly is [11:52.400 --> 11:54.000] a cryptographic provider type? [11:54.000 --> 11:54.620] Now, a cryptographic [11:54.620 --> 11:55.340] provider type [11:55.340 --> 11:56.700] is basically a [11:56.700 --> 11:57.800] plug and play function, [11:58.120 --> 11:58.960] or a plug and play [11:58.960 --> 11:59.400] description [11:59.400 --> 12:00.060] inside the registry, [12:00.060 --> 12:01.720] which explains how [12:01.720 --> 12:02.560] certain encryption [12:02.560 --> 12:03.220] algorithms are to be used [12:03.220 --> 12:04.300] with certain variables [12:04.300 --> 12:05.940] for specific outcomes. [12:05.940 --> 12:06.500] Now, this is under [12:06.500 --> 12:07.600] the Windows default, [12:07.600 --> 12:08.500] and it has a number [12:08.500 --> 12:09.380] for AES, DSS, [12:09.380 --> 12:10.020] and Diffie-Hyman, [12:10.020 --> 12:10.860] things like that. [12:10.860 --> 12:11.760] And it has versions [12:11.760 --> 12:12.920] 1, 3, 5, 12, [12:12.920 --> 12:14.180] 13, 18, and 24. [12:14.180 --> 12:15.860] It does not have [12:15.860 --> 12:16.740] a default type of 23. [12:16.740 --> 12:17.940] This was confirmed [12:17.940 --> 12:18.660] by looking at [12:18.660 --> 12:19.760] Microsoft documentation, [12:19.760 --> 12:21.420] as accurate as that can be. [12:21.620 --> 12:22.480] But we found, [12:22.480 --> 12:22.900] we also found [12:22.900 --> 12:23.960] no trace of any [12:23.960 --> 12:25.080] legitimate form of [12:25.920 --> 12:26.880] type 023 [12:26.880 --> 12:28.020] within the default [12:28.020 --> 12:29.180] provider types. [12:29.180 --> 12:30.540] So, we had something [12:30.540 --> 12:31.480] that was consistent [12:31.480 --> 12:32.920] across all infections, [12:32.920 --> 12:33.380] and something that [12:33.380 --> 12:33.960] could be easily [12:33.960 --> 12:35.200] checked for using [12:35.200 --> 12:35.880] registry monitoring. [12:35.880 --> 12:37.960] So, we had a [12:37.960 --> 12:38.560] consistent point [12:38.560 --> 12:38.880] of installation [12:38.880 --> 12:39.840] that we can monitor for, [12:39.840 --> 12:41.060] using this type 023, [12:41.060 --> 12:42.100] and we had a [12:42.100 --> 12:44.260] semi-conclusive way [12:44.260 --> 12:44.680] of monitoring [12:44.680 --> 12:45.240] for legacy installations, [12:44.340 --> 12:45.540] using the registry [12:45.240 --> 12:46.280] locations that we [12:46.280 --> 12:47.240] generated. [12:47.820 --> 12:48.940] So, moving on from [12:48.940 --> 12:49.960] how we actually [12:49.960 --> 12:50.960] did the research, [12:50.960 --> 12:51.540] how to detect [12:51.540 --> 12:51.940] and actually [12:51.940 --> 12:52.740] really remediate [12:52.740 --> 12:53.360] killsuit using [12:53.360 --> 12:54.500] this information. [12:54.900 --> 12:55.880] So, it breaks down [12:55.880 --> 12:57.000] into the type 023 [12:57.640 --> 12:58.080] default cryptographic [12:58.080 --> 12:58.860] type that I just [12:58.860 --> 12:59.680] explained. [12:59.680 --> 13:00.860] The system function [13:00.860 --> 13:01.960] 007, which is the [13:01.960 --> 13:03.040] NTML hash generation, [13:03.040 --> 13:03.600] depending on which [13:03.600 --> 13:04.160] process it's [13:04.160 --> 13:05.060] injected into. [13:05.060 --> 13:06.180] That has, obviously, [13:06.180 --> 13:07.120] quite a big variable [13:07.120 --> 13:07.840] for hit and miss, [13:07.840 --> 13:08.320] depending on what [13:08.320 --> 13:08.800] the operator's [13:08.800 --> 13:09.780] injected into. [13:09.780 --> 13:10.840] And the, uh, [13:10.840 --> 13:11.700] registry directory [13:11.700 --> 13:12.460] that installs [13:12.460 --> 13:13.420] the encrypted database. [13:13.420 --> 13:13.940] Again, that's [13:13.940 --> 13:14.540] semi-conclusive [13:14.540 --> 13:15.040] at the moment, [13:15.040 --> 13:15.440] and not fully [13:15.440 --> 13:16.320] conclusive. [13:16.340 --> 13:16.720] You'll see that [13:16.720 --> 13:17.200] there's an extra [13:17.200 --> 13:17.840] box there. [13:17.840 --> 13:18.220] That's because, [13:18.220 --> 13:18.520] in the final [13:18.520 --> 13:19.020] sweep of the [13:19.020 --> 13:19.440] framework, [13:19.440 --> 13:19.900] we found that [13:19.900 --> 13:20.460] there was actually [13:20.680 --> 13:21.340] a driver list [13:21.340 --> 13:21.960] that was inside [13:21.960 --> 13:22.840] the framework. [13:22.940 --> 13:23.240] And this [13:23.240 --> 13:24.060] contained multiple [13:24.060 --> 13:24.880] references to [13:24.880 --> 13:26.100] killsuit only, [13:26.100 --> 13:26.740] or killsuit [13:26.740 --> 13:27.760] remove driver [13:27.760 --> 13:28.980] after installation. [13:28.980 --> 13:29.540] We found that [13:29.540 --> 13:29.940] these actually [13:29.940 --> 13:30.460] referred to [13:30.460 --> 13:31.240] killsuit loader [13:31.240 --> 13:32.060] drivers. [13:32.260 --> 13:32.780] Uh, but, [13:32.780 --> 13:33.600] after installation [13:33.600 --> 13:34.280] and infection of [13:34.280 --> 13:34.660] the machine, [13:34.660 --> 13:34.980] we couldn't [13:34.980 --> 13:35.840] actually find any [13:35.840 --> 13:36.380] trace of them [13:36.380 --> 13:37.440] ever being used. [13:37.440 --> 13:37.940] So, although they [13:37.940 --> 13:38.600] were inside the [13:38.600 --> 13:39.120] framework, [13:39.120 --> 13:40.060] we couldn't find [13:40.060 --> 13:41.000] any trace of them [13:41.000 --> 13:41.580] on what we were [13:41.580 --> 13:42.120] looking at. [13:42.120 --> 13:43.160] So, something that [13:43.160 --> 13:43.720] could be looked at [13:43.720 --> 13:44.760] but we, we [13:44.760 --> 13:45.160] couldn't find [13:45.160 --> 13:45.920] anything. [13:46.100 --> 13:46.880] So, removal [13:46.880 --> 13:47.780] and neutering [13:47.780 --> 13:48.420] of a killsuit [13:48.420 --> 13:48.820] basically [13:49.340 --> 13:50.040] requires the [13:50.040 --> 13:50.500] understanding [13:50.500 --> 13:51.320] of how, uh, [13:51.320 --> 13:52.140] killsuit operates. [13:52.240 --> 13:53.040] And it [13:53.040 --> 13:54.000] focuses basically [13:54.000 --> 13:55.360] on that it [13:55.360 --> 13:56.020] always refers to [13:56.020 --> 13:56.520] this encrypted [13:56.520 --> 13:57.140] registry database [13:57.140 --> 13:58.220] that I explained. [13:58.220 --> 13:58.880] So, the [13:58.880 --> 13:59.300] boot pack [13:59.300 --> 14:00.000] itself will [14:00.000 --> 14:00.800] load the, uh, [14:00.800 --> 14:01.300] the killsuit [14:01.300 --> 14:02.200] modules from [14:02.200 --> 14:02.580] the registry [14:02.580 --> 14:03.160] database. [14:03.160 --> 14:03.520] The running [14:03.520 --> 14:03.820] killsuit [14:03.820 --> 14:04.880] instances refer to [14:04.880 --> 14:05.820] the database. [14:05.820 --> 14:06.300] The Pailchip [14:06.300 --> 14:06.940] instance, when it [14:06.940 --> 14:07.620] tries to enact [14:07.620 --> 14:08.660] killsuit, um, [14:08.660 --> 14:09.220] actions, [14:09.220 --> 14:09.760] has to refer to [14:09.760 --> 14:10.320] the database. [14:10.320 --> 14:10.820] So, as you can [14:10.820 --> 14:12.120] notice, everything [14:12.120 --> 14:12.720] refers to the [14:12.720 --> 14:13.320] database. [14:13.320 --> 14:14.060] So, if you know [14:14.060 --> 14:14.460] what the registry [14:14.460 --> 14:15.460] database is, [14:15.460 --> 14:16.400] and you remove [14:16.400 --> 14:17.500] it, you just, [14:17.500 --> 14:17.980] you destroy, [14:17.980 --> 14:18.360] you basically [14:18.360 --> 14:19.180] neuter killsuit [14:19.180 --> 14:19.700] and all of its [14:19.700 --> 14:20.440] functionality. [14:20.720 --> 14:21.320] Now, that [14:21.320 --> 14:21.780] breaks down to [14:21.780 --> 14:22.340] knowing where [14:22.340 --> 14:23.420] killsuit is. [14:23.440 --> 14:24.340] So, um, [14:24.340 --> 14:24.960] that, that [14:24.960 --> 14:25.780] requires, obviously, [14:25.840 --> 14:26.080] a bit more [14:26.080 --> 14:26.820] searching of the [14:26.820 --> 14:27.420] two lists. [14:27.420 --> 14:27.780] And obviously, [14:27.780 --> 14:28.080] if we find two [14:28.080 --> 14:28.480] lists, we can [14:28.480 --> 14:29.360] find all of it. [14:29.580 --> 14:30.220] Um, if [14:30.220 --> 14:30.940] not, uh, [14:30.940 --> 14:31.340] the list that [14:31.340 --> 14:31.980] we provided, [14:31.980 --> 14:32.740] we have done a [14:32.740 --> 14:33.320] research paper, [14:33.320 --> 14:33.780] and the two [14:33.780 --> 14:34.340] lists that we [14:34.340 --> 14:34.920] found of the [14:34.920 --> 14:35.740] two halves, [14:35.740 --> 14:36.240] and basically, [14:36.240 --> 14:36.840] any combination [14:36.840 --> 14:37.280] you can find, [14:37.280 --> 14:38.120] it's an easy [14:38.120 --> 14:38.660] sweep to do [14:38.660 --> 14:40.040] across an estate. [14:40.040 --> 14:40.280] So, now [14:40.280 --> 14:40.820] I've gone over [14:40.820 --> 14:41.800] how to find [14:41.800 --> 14:42.360] killsuit, [14:42.360 --> 14:42.740] and how to [14:42.740 --> 14:43.440] remove it. [14:43.440 --> 14:44.000] What's more [14:44.000 --> 14:44.540] interesting, [14:44.540 --> 14:44.980] and what's very [14:44.980 --> 14:45.380] important, [14:45.380 --> 14:45.700] is how the [14:45.700 --> 14:46.580] SOTY there, [14:46.580 --> 14:47.260] SOTY bootpack, [14:47.260 --> 14:47.940] SOTY bootpack [14:47.940 --> 14:48.500] operator, [14:48.500 --> 14:48.800] which is their [14:48.800 --> 14:49.860] advanced bootloader, [14:49.860 --> 14:50.680] works. [14:50.820 --> 14:51.300] Um, and for that, [14:51.300 --> 14:51.620] I'm going to hand [14:51.620 --> 14:52.300] over to Lacey, [14:52.300 --> 14:52.800] who did the [14:52.800 --> 14:53.660] research. [14:59.910 --> 15:01.370] So, thinking [15:01.370 --> 15:02.450] about all those, [15:02.450 --> 15:02.910] like, complex [15:02.910 --> 15:03.810] frameworks that we [15:03.810 --> 15:04.470] just saw for [15:04.470 --> 15:05.590] defense evasion, [15:05.590 --> 15:06.110] um, it will [15:06.110 --> 15:06.630] probably be [15:06.630 --> 15:07.510] pointless if [15:07.510 --> 15:07.890] you do not [15:07.890 --> 15:09.070] implement a [15:09.770 --> 15:10.730] persisting module, [15:10.730 --> 15:11.350] which the [15:11.350 --> 15:11.870] attackers could [15:11.870 --> 15:12.690] connect back to, [15:12.190 --> 15:12.910] should a [15:12.690 --> 15:13.470] parallel chip [15:13.470 --> 15:14.110] connection be [15:14.110 --> 15:14.950] dropped. [15:15.630 --> 15:16.710] Installing a [15:16.710 --> 15:17.670] persistence mechanism [15:17.670 --> 15:18.330] actually means [15:18.330 --> 15:18.930] that if the [15:18.930 --> 15:20.050] system is patched [15:20.050 --> 15:20.690] from the [15:20.690 --> 15:21.610] exploits that is [15:21.610 --> 15:22.210] present in [15:22.210 --> 15:23.530] fastpunch, [15:23.530 --> 15:23.950] the attacker [15:23.950 --> 15:24.790] will still be [15:24.790 --> 15:25.530] able to [15:25.530 --> 15:25.890] compromise the [15:25.890 --> 15:26.670] system at any [15:26.670 --> 15:29.970] time they want. [15:29.970 --> 15:30.790] So, how do we [15:30.790 --> 15:31.970] find out the [15:31.970 --> 15:32.790] different methods [15:32.790 --> 15:33.250] of persistence [15:33.250 --> 15:33.990] in killsuit? [15:33.990 --> 15:35.050] Um, we can [15:35.050 --> 15:35.450] type the [15:35.450 --> 15:35.870] command [15:35.870 --> 15:36.710] kiso-survey [15:36.710 --> 15:37.650] in the [15:38.530 --> 15:39.950] dendospirits [15:39.950 --> 15:40.130] terminal. [15:40.130 --> 15:40.750] This figure [15:40.750 --> 15:41.610] here shows [15:41.610 --> 15:41.950] that there's [15:41.950 --> 15:42.670] three types of, [15:41.170 --> 15:42.050] um, persistence [15:42.050 --> 15:42.610] methods that [15:42.670 --> 15:43.070] you can [15:43.070 --> 15:43.770] do with [15:43.770 --> 15:44.410] killsuit. [15:44.410 --> 15:44.990] And the [15:44.990 --> 15:45.430] very first [15:45.430 --> 15:45.810] one is [15:45.810 --> 15:46.850] driver. [15:47.370 --> 15:47.890] Then you [15:47.890 --> 15:48.270] have [15:48.270 --> 15:49.030] soti, [15:49.030 --> 15:49.490] which stands [15:49.490 --> 15:49.710] for [15:49.710 --> 15:50.870] solar time. [15:50.870 --> 15:51.150] And then [15:51.150 --> 15:51.490] you have [15:51.490 --> 15:51.950] juvy, [15:51.950 --> 15:52.370] which stands [15:52.370 --> 15:52.650] for [15:52.650 --> 15:53.870] just visiting. [15:55.050 --> 15:55.870] So, one [15:55.870 --> 15:56.210] cool thing [15:56.210 --> 15:56.670] about this [15:56.670 --> 15:57.230] command is [15:57.230 --> 15:57.590] that it will [15:57.590 --> 15:57.970] tell you [15:57.970 --> 15:58.490] whether it is [15:58.490 --> 15:58.990] compatible [15:58.990 --> 15:59.430] with [15:59.430 --> 15:59.810] your [15:59.810 --> 16:00.290] victim [16:00.290 --> 16:01.310] host. [16:01.470 --> 16:02.690] For example, [16:02.690 --> 16:03.270] driver is [16:03.270 --> 16:03.690] outdated [16:03.690 --> 16:04.530] because of [16:04.530 --> 16:05.010] code signing [16:05.010 --> 16:05.650] policies [16:05.650 --> 16:06.050] that [16:06.050 --> 16:06.330] in [16:06.330 --> 16:06.830] Windows [16:06.830 --> 16:07.990] implemented. [16:08.390 --> 16:08.830] And [16:08.830 --> 16:09.650] just visiting [16:09.650 --> 16:10.210] is also [16:10.210 --> 16:10.650] outdated [16:10.650 --> 16:11.310] because it [16:11.310 --> 16:11.750] is built [16:11.750 --> 16:12.110] for [16:12.110 --> 16:12.510] Windows [16:12.510 --> 16:13.410] Vista. [16:14.130 --> 16:14.910] So, the [16:14.910 --> 16:15.290] only [16:15.290 --> 16:16.130] compatible [16:16.130 --> 16:16.590] method [16:16.590 --> 16:16.930] that we [16:16.930 --> 16:17.030] are [16:17.030 --> 16:17.290] left [16:17.290 --> 16:17.590] with [16:17.590 --> 16:17.790] is [16:17.790 --> 16:18.170] actually [16:18.170 --> 16:19.450] solar time. [16:20.810 --> 16:21.670] But what [16:21.670 --> 16:22.250] exactly [16:22.250 --> 16:22.750] is solar [16:22.750 --> 16:23.710] time? [16:23.850 --> 16:24.550] So, I [16:24.550 --> 16:24.710] was [16:24.710 --> 16:24.930] really [16:24.930 --> 16:25.410] curious [16:25.410 --> 16:25.730] and I [16:25.730 --> 16:25.950] wanted [16:25.950 --> 16:26.230] to [16:26.230 --> 16:26.990] find out [16:27.710 --> 16:28.070] whether [16:28.070 --> 16:28.390] there are [16:28.390 --> 16:28.570] any [16:28.570 --> 16:29.150] information [16:29.150 --> 16:30.090] available [16:30.090 --> 16:30.690] online [16:30.690 --> 16:30.950] about [16:30.950 --> 16:31.210] this [16:31.210 --> 16:31.630] elusive [16:31.630 --> 16:32.410] method. [16:32.670 --> 16:33.410] And I [16:33.410 --> 16:33.570] found [16:33.570 --> 16:33.730] out [16:33.730 --> 16:34.030] to be [16:34.030 --> 16:34.530] as safe [16:34.530 --> 16:34.710] as [16:34.710 --> 16:35.170] possible [16:35.170 --> 16:35.750] equation [16:35.750 --> 16:36.110] group [16:36.110 --> 16:36.950] when [16:36.950 --> 16:37.590] really [16:37.590 --> 16:37.890] low [16:37.890 --> 16:38.270] level [16:38.270 --> 16:38.550] as [16:38.550 --> 16:38.730] they [16:38.730 --> 16:39.630] can, [16:39.630 --> 16:40.030] which [16:40.030 --> 16:40.190] is [16:40.190 --> 16:40.750] infecting [16:40.750 --> 16:40.910] the [16:40.910 --> 16:41.850] firmware. [16:42.590 --> 16:43.330] So, [16:43.330 --> 16:43.630] according [16:43.630 --> 16:44.050] to [16:44.270 --> 16:44.670] a [16:44.670 --> 16:44.990] report [16:44.990 --> 16:45.270] made [16:45.270 --> 16:45.970] by [16:45.970 --> 16:47.710] Kaspersky, [16:47.710 --> 16:48.110] solar [16:48.110 --> 16:48.330] time [16:48.330 --> 16:48.570] was [16:48.570 --> 16:48.810] first [16:48.810 --> 16:49.350] termed [16:49.350 --> 16:49.970] by [16:50.270 --> 16:50.470] them [16:50.470 --> 16:50.850] as [16:51.150 --> 16:51.610] Grayfish. [16:51.610 --> 16:51.830] It [16:51.830 --> 16:52.190] inserts [16:52.190 --> 16:52.690] a [16:52.690 --> 16:53.170] pill [16:53.170 --> 16:53.370] into [16:53.370 --> 16:53.530] the [16:53.530 --> 16:54.050] firmware [16:54.050 --> 16:54.270] which [16:54.270 --> 16:54.770] hijacks [16:54.770 --> 16:55.270] the [16:55.270 --> 16:55.630] boot [16:55.630 --> 16:56.150] sequence [16:56.150 --> 16:56.270] of [16:56.270 --> 16:56.430] the [16:56.430 --> 16:56.670] operating [16:56.670 --> 16:57.810] system, [16:57.810 --> 16:58.410] and then [16:58.590 --> 16:58.890] it gains [16:58.890 --> 16:59.190] complete [16:59.190 --> 16:59.630] control [16:59.630 --> 16:59.910] to [16:59.910 --> 17:00.030] install [17:00.030 --> 17:00.490] a [17:00.490 --> 17:00.850] virtual [17:00.850 --> 17:00.990] file [17:00.990 --> 17:01.190] system [17:01.190 --> 17:01.610] in [17:01.610 --> 17:02.230] the [17:05.780 --> 17:06.400] registry [17:06.400 --> 17:06.660] of [17:06.660 --> 17:06.800] the [17:06.800 --> 17:06.980] hard [17:06.980 --> 17:07.380] drive. [17:07.380 --> 17:08.000] And [17:08.000 --> 17:08.560] this [17:08.560 --> 17:09.560] is the [17:09.560 --> 17:10.860] Grayfish [17:10.860 --> 17:10.980] architecture [17:10.980 --> 17:11.160] presented [17:11.160 --> 17:11.300] by [17:11.300 --> 17:13.200] Kaspersky. [17:13.200 --> 17:13.760] So, [17:10.820 --> 17:11.060] in [17:11.060 --> 17:11.220] an [17:11.220 --> 17:11.780] infected [17:11.780 --> 17:12.180] volume [17:12.180 --> 17:12.500] boot [17:12.500 --> 17:13.060] record, [17:13.060 --> 17:13.300] an [17:13.300 --> 17:13.780] encrypted [17:14.820 --> 17:14.860] container [17:14.860 --> 17:15.440] is loaded. [17:15.700 --> 17:16.240] The [17:16.240 --> 17:16.560] container [17:16.560 --> 17:16.820] file [17:16.820 --> 17:17.200] will then [17:17.200 --> 17:17.880] load a [17:17.880 --> 17:18.180] kernel [17:18.180 --> 17:18.880] mode [17:18.880 --> 17:19.520] orchestrator [17:19.520 --> 17:19.820] which [17:19.820 --> 17:20.020] then [17:20.020 --> 17:20.620] loads the [17:20.620 --> 17:20.980] user [17:20.980 --> 17:21.320] mode [17:21.320 --> 17:21.880] part [17:21.880 --> 17:22.580] from [17:22.580 --> 17:23.040] registry [17:23.040 --> 17:23.220] before [17:23.220 --> 17:23.840] starting [17:23.840 --> 17:24.380] the [17:24.560 --> 17:24.940] payloads. [17:24.940 --> 17:25.180] And so [17:25.180 --> 17:25.480] what we [17:25.480 --> 17:25.700] are [17:25.700 --> 17:25.880] going [17:25.880 --> 17:26.040] to [17:26.040 --> 17:26.380] do [17:26.380 --> 17:26.740] is to [17:26.740 --> 17:26.980] focus [17:26.980 --> 17:27.800] on the [17:27.800 --> 17:27.980] left [17:27.980 --> 17:28.100] box [17:28.100 --> 17:28.500] portion [17:28.500 --> 17:29.040] of [17:32.140 --> 17:32.340] the [17:32.340 --> 17:33.080] diagram. [17:33.080 --> 17:33.360] But [17:33.360 --> 17:33.580] what [17:33.580 --> 17:33.980] exactly [17:33.980 --> 17:34.820] is this [17:34.820 --> 17:35.000] encrypted [17:35.000 --> 17:35.120] container [17:35.120 --> 17:35.420] file [17:35.420 --> 17:35.800] that is [17:35.800 --> 17:36.080] loaded [17:36.080 --> 17:36.320] in [17:36.320 --> 17:36.820] the [17:36.820 --> 17:37.360] volume [17:37.540 --> 17:37.940] boot [17:37.940 --> 17:38.660] record? [17:38.660 --> 17:39.660] To [17:39.660 --> 17:40.260] check [17:40.260 --> 17:40.760] whether, [17:40.760 --> 17:41.040] to [17:41.040 --> 17:41.260] check [17:41.260 --> 17:41.600] which [17:41.600 --> 17:42.100] is the [17:42.100 --> 17:42.440] container [17:42.440 --> 17:42.660] file [17:42.660 --> 17:42.780] being [17:42.780 --> 17:43.320] loaded, [17:43.320 --> 17:43.540] you [17:42.660 --> 17:42.900] can [17:42.900 --> 17:43.220] run [17:43.220 --> 17:43.380] the [17:43.540 --> 17:44.140] solty [17:44.140 --> 17:44.440] python [17:44.440 --> 17:44.880] script [17:44.880 --> 17:45.080] in [17:45.080 --> 17:45.220] the [17:45.220 --> 17:45.660] dendasprite [17:45.660 --> 17:46.140] terminal [17:46.140 --> 17:46.880] and it [17:46.880 --> 17:47.000] will [17:47.000 --> 17:47.420] tell you [17:47.420 --> 17:47.720] the [17:47.720 --> 17:48.160] solartime [17:48.160 --> 17:48.560] container [17:48.560 --> 17:48.940] present [17:48.940 --> 17:49.120] in [17:49.120 --> 17:49.240] the [17:49.240 --> 17:50.160] disk. [17:50.220 --> 17:50.660] This is [17:50.660 --> 17:50.820] the [17:50.820 --> 17:51.060] only [17:51.060 --> 17:51.400] file [17:51.400 --> 17:51.640] that [17:51.640 --> 17:51.820] is [17:51.820 --> 17:52.220] searchable [17:52.220 --> 17:52.540] through [17:52.540 --> 17:52.780] the [17:52.780 --> 17:52.980] file [17:52.980 --> 17:53.380] system [17:53.380 --> 17:53.640] on [17:53.640 --> 17:54.560] disk. [17:55.080 --> 17:55.500] And [17:55.500 --> 17:55.700] this [17:55.700 --> 17:56.120] container [17:56.120 --> 17:56.420] file [17:56.420 --> 17:56.640] is [17:56.640 --> 17:56.880] stored [17:56.880 --> 17:57.440] as a [17:57.440 --> 17:57.700] true [17:57.700 --> 17:57.980] type [17:57.980 --> 17:58.340] font [17:58.340 --> 17:58.900] file [17:58.900 --> 17:59.040] and [17:59.040 --> 17:59.160] will [17:59.160 --> 17:59.340] be [17:59.340 --> 17:59.560] the [17:59.560 --> 17:59.920] very [17:59.920 --> 18:00.220] first [18:00.220 --> 18:00.580] file [18:00.580 --> 18:00.900] loaded [18:00.900 --> 18:01.520] by [18:01.520 --> 18:02.140] Windows [18:02.140 --> 18:02.540] even [18:02.540 --> 18:02.840] prior [18:02.840 --> 18:03.140] to [18:03.140 --> 18:04.160] kernel [18:04.160 --> 18:08.390] initialization. [18:08.390 --> 18:09.050] So [18:09.050 --> 18:09.410] since [18:09.410 --> 18:10.090] solartime [18:10.090 --> 18:10.450] affects [18:10.450 --> 18:10.730] the volume [18:10.730 --> 18:10.970] boot [18:10.970 --> 18:11.890] record, [18:11.890 --> 18:12.050] it is [18:10.970 --> 18:11.610] considered [18:11.610 --> 18:11.930] as a [18:12.050 --> 18:12.690] and [18:12.690 --> 18:13.530] before [18:13.530 --> 18:14.230] analyzing [18:14.230 --> 18:14.490] boot [18:14.490 --> 18:14.790] kits, [18:14.790 --> 18:14.970] I would [18:14.970 --> 18:15.170] like [18:15.170 --> 18:15.330] to [18:15.330 --> 18:15.530] go [18:15.530 --> 18:15.910] through [18:16.230 --> 18:16.430] a [18:16.430 --> 18:16.650] little [18:16.650 --> 18:16.830] bit [18:16.830 --> 18:16.970] on [18:16.970 --> 18:17.230] the [18:17.230 --> 18:17.570] Windows [18:17.570 --> 18:18.210] boot [18:18.210 --> 18:20.270] process. [18:20.270 --> 18:20.450] So [18:20.450 --> 18:20.970] the first [18:20.970 --> 18:21.190] step [18:21.190 --> 18:21.770] is during [18:21.770 --> 18:22.110] power [18:22.110 --> 18:22.330] on, [18:22.330 --> 18:22.630] the [18:22.630 --> 18:23.190] BIOS [18:23.190 --> 18:23.670] boot [18:23.670 --> 18:23.930] code [18:23.930 --> 18:24.370] begins [18:24.370 --> 18:24.810] with [18:24.810 --> 18:25.730] basic [18:25.730 --> 18:26.010] system [18:26.010 --> 18:26.930] initialization, [18:26.930 --> 18:27.330] for [18:27.330 --> 18:28.410] example, [18:28.410 --> 18:29.070] simplified [18:29.070 --> 18:29.670] input [18:30.670 --> 18:31.270] output [18:31.270 --> 18:31.630] interface. [18:31.630 --> 18:31.830] The [18:31.830 --> 18:32.290] BIOS [18:32.290 --> 18:32.610] then [18:32.610 --> 18:32.870] loads [18:32.870 --> 18:33.250] the [18:33.250 --> 18:33.450] master [18:33.450 --> 18:33.630] boot [18:33.630 --> 18:34.190] record, [18:34.190 --> 18:34.570] which [18:34.570 --> 18:34.990] finds [18:34.990 --> 18:35.370] the [18:35.370 --> 18:35.590] active [18:35.590 --> 18:35.770] partition [18:35.770 --> 18:36.270] and loads [18:36.270 --> 18:36.630] the [18:36.630 --> 18:37.230] volume [18:38.430 --> 18:39.030] boot [18:39.030 --> 18:39.490] record. [18:39.490 --> 18:39.830] The [18:39.830 --> 18:40.430] volume [18:40.430 --> 18:40.950] boot [18:40.950 --> 18:41.390] record [18:39.890 --> 18:40.450] contains [18:40.450 --> 18:40.930] partition [18:40.930 --> 18:41.490] layout [18:41.390 --> 18:41.870] information [18:41.870 --> 18:42.870] in a [18:42.870 --> 18:43.370] data [18:43.370 --> 18:43.650] structure [18:43.650 --> 18:44.150] called the [18:44.150 --> 18:45.130] BIOS [18:45.130 --> 18:45.730] parameter [18:45.750 --> 18:46.450] block. [18:46.450 --> 18:46.930] This [18:46.930 --> 18:47.130] block [18:47.130 --> 18:47.450] describes [18:47.450 --> 18:47.850] the [18:47.850 --> 18:48.030] physical [18:48.030 --> 18:48.410] layout of [18:48.410 --> 18:48.890] the [18:48.890 --> 18:49.230] data [18:49.230 --> 18:49.370] storage [18:49.370 --> 18:49.890] volume, [18:49.890 --> 18:50.090] for [18:50.090 --> 18:50.310] example, [18:50.310 --> 18:51.110] is it [18:51.110 --> 18:51.290] an [18:51.290 --> 18:51.610] NTFS [18:51.610 --> 18:52.390] or the [18:52.390 --> 18:53.190] FAT [18:53.190 --> 18:53.350] file [18:53.350 --> 18:54.150] system, [18:54.150 --> 18:54.730] was [18:54.730 --> 18:54.970] the [18:54.970 --> 18:55.350] number [18:55.350 --> 18:55.550] of [18:55.550 --> 18:55.850] sectors [18:55.850 --> 18:56.450] per [18:58.930 --> 18:59.550] cluster, [18:59.550 --> 19:00.110] etc. [19:00.110 --> 19:00.490] The [19:00.490 --> 19:00.850] volume [19:00.850 --> 19:01.430] boot [19:01.430 --> 19:01.790] record [19:01.790 --> 19:01.990] then [19:01.990 --> 19:02.350] passes [19:02.350 --> 19:02.790] control [19:02.790 --> 19:03.210] to [19:03.210 --> 19:03.270] the [19:03.270 --> 19:03.410] initial [19:03.410 --> 19:03.550] program [19:03.550 --> 19:04.950] loader, [19:04.950 --> 19:05.110] which [19:05.110 --> 19:05.290] is [19:05.290 --> 19:05.710] responsible [19:05.710 --> 19:06.310] for [19:07.310 --> 19:07.810] parsing [19:07.810 --> 19:08.030] the [19:08.030 --> 19:08.250] file [19:08.250 --> 19:08.850] system. [19:08.850 --> 19:09.030] It [19:09.030 --> 19:09.190] then [19:09.190 --> 19:09.650] loads [19:09.650 --> 19:09.890] the [19:09.890 --> 19:10.090] boot [19:10.090 --> 19:10.970] manager, [19:08.910 --> 19:09.150] which [19:09.150 --> 19:09.630] manages [19:09.630 --> 19:09.790] the [19:09.790 --> 19:10.110] boot [19:10.110 --> 19:10.670] process [19:10.670 --> 19:10.990] until [19:10.970 --> 19:11.110] the [19:11.110 --> 19:11.490] user [19:11.490 --> 19:12.050] chooses [19:12.290 --> 19:12.410] a [19:12.410 --> 19:12.910] boot [19:12.910 --> 19:14.210] option, [19:14.210 --> 19:14.710] before [19:14.710 --> 19:15.090] loading [19:15.090 --> 19:16.350] wingload.exe, [19:16.350 --> 19:16.930] which [19:16.930 --> 19:17.310] is [19:17.310 --> 19:17.770] responsible [19:17.770 --> 19:17.930] for [19:17.930 --> 19:18.230] starting [19:18.230 --> 19:18.790] the [19:21.050 --> 19:21.790] kernel. [19:21.790 --> 19:22.170] So, [19:22.170 --> 19:22.310] after [19:22.310 --> 19:22.810] all this [19:22.810 --> 19:23.390] reading up [19:23.390 --> 19:23.610] and [19:23.610 --> 19:23.790] discovering [19:23.790 --> 19:24.050] on [19:24.050 --> 19:24.250] boot [19:24.250 --> 19:24.730] kits [19:24.730 --> 19:24.830] and [19:24.830 --> 19:25.650] greyfish, [19:25.650 --> 19:25.990] how [19:25.990 --> 19:26.450] does [19:26.450 --> 19:27.310] Solartime [19:27.310 --> 19:27.550] actually [19:27.550 --> 19:27.750] work [19:27.750 --> 19:28.230] in [19:28.230 --> 19:28.790] relation [19:30.610 --> 19:31.170] to [19:31.170 --> 19:31.270] this [19:31.270 --> 19:31.330] boot [19:31.330 --> 19:31.810] process? [19:31.810 --> 19:32.250] So, [19:32.250 --> 19:32.630] the [19:32.630 --> 19:32.970] very [19:32.970 --> 19:33.250] first [19:33.250 --> 19:33.850] change [19:33.850 --> 19:34.410] we [19:34.410 --> 19:34.810] noticed [19:34.810 --> 19:35.350] is [19:35.350 --> 19:35.630] that [19:35.630 --> 19:36.250] Solartime [19:36.250 --> 19:37.190] disables [19:38.750 --> 19:39.310] error [19:39.310 --> 19:39.470] reporting [19:39.470 --> 19:39.590] in [19:39.590 --> 19:39.830] the [19:39.830 --> 19:40.030] volume [19:40.030 --> 19:40.430] boot [19:40.430 --> 19:40.590] record. [19:38.890 --> 19:39.210] Looking [19:39.210 --> 19:39.450] at the [19:39.450 --> 19:39.770] volume [19:39.770 --> 19:39.930] boot [19:39.930 --> 19:40.490] record, [19:40.590 --> 19:40.810] instead [19:40.810 --> 19:41.490] of a [19:41.490 --> 19:41.830] hot [19:42.110 --> 19:42.710] instruction, [19:42.710 --> 19:43.550] Solartime [19:43.550 --> 19:44.050] changed [19:44.050 --> 19:44.470] it [19:44.470 --> 19:45.150] into [19:45.550 --> 19:46.130] infinite [19:46.130 --> 19:46.890] loop. [19:46.890 --> 19:47.390] Operational [19:47.390 --> 19:47.910] errors [19:47.910 --> 19:48.210] are [19:48.210 --> 19:48.910] standardly [19:48.910 --> 19:49.270] displayed [19:49.270 --> 19:49.710] by [19:49.710 --> 19:50.190] hitting [19:50.190 --> 19:50.610] a hot [19:50.610 --> 19:51.070] command [19:51.070 --> 19:51.370] stopping [19:51.370 --> 19:52.510] function, [19:52.510 --> 19:52.910] so [19:52.910 --> 19:53.450] examples [19:53.450 --> 19:54.850] could be a [19:55.090 --> 19:55.250] missing [19:55.250 --> 19:55.650] or [19:55.650 --> 19:56.130] compressed [19:56.130 --> 19:56.430] boot [19:56.430 --> 19:56.670] manager. [19:56.670 --> 19:57.010] And [19:57.010 --> 19:57.990] Solartime [19:57.990 --> 19:58.290] changes [19:58.290 --> 19:59.330] this, [19:59.330 --> 19:59.790] so [19:59.790 --> 20:00.510] even if [20:00.510 --> 20:00.770] an [20:00.770 --> 20:01.650] operation- [20:01.650 --> 20:02.230] operational [20:02.230 --> 20:02.530] error [20:02.530 --> 20:03.150] occurs, [20:03.150 --> 20:03.710] no error [20:03.710 --> 20:04.150] reporting [20:04.150 --> 20:04.430] actually [20:04.430 --> 20:04.950] happens. [20:04.950 --> 20:06.010] So, [20:06.010 --> 20:06.230] this [20:06.230 --> 20:06.470] prevents [20:06.470 --> 20:06.630] alerts [20:06.770 --> 20:06.910] or [20:06.910 --> 20:07.310] cause [20:07.310 --> 20:07.990] of [20:12.110 --> 20:12.370] investigation [20:12.370 --> 20:12.510] into [20:12.510 --> 20:12.770] the [20:12.770 --> 20:13.410] cause [20:06.430 --> 20:06.590] of [20:06.590 --> 20:06.670] a [20:06.670 --> 20:06.990] boot [20:06.990 --> 20:07.390] failure. [20:12.150 --> 20:12.310] And [20:12.310 --> 20:12.470] the [20:12.470 --> 20:12.790] second [20:12.790 --> 20:13.510] disparity [20:13.410 --> 20:13.590] between [20:14.450 --> 20:14.750] a [20:14.750 --> 20:15.050] normal [20:15.050 --> 20:15.390] boot [20:15.630 --> 20:16.010] process [20:16.010 --> 20:16.670] and [20:16.670 --> 20:17.690] Solartime [20:17.690 --> 20:17.890] infected [20:17.890 --> 20:18.070] boot [20:18.070 --> 20:19.230] is that [20:19.230 --> 20:19.430] it [20:19.430 --> 20:19.970] relocates [20:19.970 --> 20:20.650] the [20:22.230 --> 20:23.230] IPL. [20:23.230 --> 20:23.710] And [20:23.710 --> 20:24.150] right [20:24.150 --> 20:24.370] before [20:24.370 --> 20:24.550] passing [20:24.550 --> 20:25.090] control [20:25.090 --> 20:25.230] to [20:25.230 --> 20:25.630] the [20:25.630 --> 20:27.230] IPL, [20:27.230 --> 20:28.230] Solartime [20:28.230 --> 20:28.770] replaces [20:28.770 --> 20:29.270] multiple [20:29.270 --> 20:29.470] instructions [20:29.470 --> 20:29.670] with [20:29.670 --> 20:31.650] NOTBYTES [20:31.650 --> 20:31.810] and [20:31.810 --> 20:32.870] overwrites [20:32.870 --> 20:33.150] the [20:33.150 --> 20:33.710] jump [20:33.710 --> 20:34.290] destination. [20:34.290 --> 20:34.870] And [20:34.870 --> 20:35.510] so [20:35.730 --> 20:35.930] the [20:35.930 --> 20:36.130] reason [20:36.130 --> 20:36.470] for [20:36.470 --> 20:37.770] overwriting [20:37.770 --> 20:38.450] this [20:38.990 --> 20:39.670] destination [20:39.670 --> 20:40.310] is that [20:40.310 --> 20:40.790] Solartime [20:40.790 --> 20:40.970] hides [20:40.970 --> 20:41.550] a lot [20:41.550 --> 20:41.910] of [20:41.910 --> 20:42.550] data [20:42.550 --> 20:42.850] at [20:42.850 --> 20:43.150] 7E7A. [20:39.410 --> 20:39.570] So [20:39.570 --> 20:39.890] this [20:39.890 --> 20:40.210] forces [20:40.210 --> 20:40.770] Solartime [20:40.770 --> 20:40.930] to [20:40.930 --> 20:41.250] use [20:41.250 --> 20:41.490] an [20:41.490 --> 20:41.970] alternate [20:41.970 --> 20:42.610] location [20:42.610 --> 20:42.770] to [20:42.770 --> 20:43.090] launch [20:43.150 --> 20:43.290] the [20:43.290 --> 20:43.770] IPL [20:43.770 --> 20:43.950] from [20:43.950 --> 20:44.290] within [20:44.290 --> 20:44.510] the [20:44.510 --> 20:44.770] volume [20:44.770 --> 20:44.970] boot [20:44.970 --> 20:45.850] record. [20:49.020 --> 20:49.500] So [20:49.500 --> 20:49.720] this [20:49.720 --> 20:50.320] is a [20:50.320 --> 20:50.640] sample [20:50.640 --> 20:50.780] from [20:50.780 --> 20:51.180] an [20:51.180 --> 20:51.560] infected [20:51.560 --> 20:51.780] boot. [20:51.780 --> 20:51.960] You [20:51.960 --> 20:52.220] can [20:52.220 --> 20:52.380] see [20:52.380 --> 20:52.520] that [20:52.520 --> 20:52.900] the [20:53.440 --> 20:53.920] address [20:53.920 --> 20:55.300] 7E7A [20:55.300 --> 20:55.680] contains [20:55.680 --> 20:56.160] lots [20:56.600 --> 20:56.680] of [20:56.680 --> 20:56.840] random [20:56.840 --> 20:57.260] bytes. [20:57.260 --> 20:57.480] And [20:57.480 --> 20:57.680] so [20:57.680 --> 20:58.000] it [20:58.000 --> 20:58.400] turns [20:58.400 --> 20:58.740] out [20:58.740 --> 20:59.000] that [20:59.000 --> 20:59.240] these [20:59.240 --> 20:59.780] bytes [20:59.780 --> 21:00.000] store [21:00.000 --> 21:00.520] the [21:00.520 --> 21:00.920] file [21:00.920 --> 21:01.140] reference [21:01.140 --> 21:01.280] and [21:01.280 --> 21:01.520] encryption [21:01.520 --> 21:01.800] key [21:01.800 --> 21:02.040] that [21:02.040 --> 21:02.460] are used [21:02.460 --> 21:03.040] later on [21:03.040 --> 21:03.220] to [21:03.220 --> 21:03.540] load [21:03.540 --> 21:04.020] and [21:06.600 --> 21:07.400] decrypt [21:07.400 --> 21:07.680] the [21:07.680 --> 21:08.220] file. [21:08.220 --> 21:08.360] So [21:08.360 --> 21:09.020] if [21:09.020 --> 21:09.220] the [21:09.220 --> 21:09.600] control [21:09.600 --> 21:09.800] passed [21:09.800 --> 21:10.120] to [21:10.120 --> 21:10.300] the [21:10.300 --> 21:11.060] IPL, [21:11.060 --> 21:11.220] Solartime [21:09.580 --> 21:09.740] then [21:09.740 --> 21:10.140] starts [21:10.140 --> 21:10.220] to [21:10.220 --> 21:10.700] locate [21:10.700 --> 21:10.780] and [21:10.780 --> 21:11.020] load [21:11.020 --> 21:11.180] the [21:11.220 --> 21:11.560] container [21:11.560 --> 21:12.300] file. [21:13.040 --> 21:13.300] And [21:13.300 --> 21:13.480] to [21:13.480 --> 21:13.640] do [21:13.640 --> 21:14.040] that, [21:14.040 --> 21:14.340] Solartime [21:14.340 --> 21:14.700] uses [21:14.700 --> 21:15.340] many of [21:15.340 --> 21:15.440] the [21:15.440 --> 21:15.800] in-built [21:15.800 --> 21:16.140] loading [21:16.140 --> 21:16.620] functions [21:16.620 --> 21:17.020] already [21:17.020 --> 21:17.680] in a [21:17.680 --> 21:17.900] normal [21:17.900 --> 21:18.120] boot [21:18.120 --> 21:18.580] by [21:18.580 --> 21:18.780] inserting [21:18.780 --> 21:19.300] an [21:19.300 --> 21:20.160] ECX [21:20.160 --> 21:20.700] flag. [21:20.700 --> 21:20.940] So [21:20.940 --> 21:21.040] this [21:21.040 --> 21:21.400] way, [21:21.400 --> 21:22.400] Solartime [21:22.400 --> 21:22.600] can [21:22.600 --> 21:22.800] control [21:22.800 --> 21:23.000] when [21:23.000 --> 21:23.360] to [21:23.360 --> 21:23.740] load [21:23.740 --> 21:24.000] its [21:24.000 --> 21:24.520] malicious [21:24.520 --> 21:24.740] file [21:24.740 --> 21:25.020] without [21:25.020 --> 21:25.500] affecting [21:25.500 --> 21:26.080] the [21:26.080 --> 21:26.680] normal [21:27.400 --> 21:28.020] IPL [21:28.020 --> 21:28.860] process. [21:28.860 --> 21:29.040] So [21:29.040 --> 21:29.700] reusing [21:29.700 --> 21:30.160] standard [21:30.160 --> 21:30.640] bootcode [21:30.640 --> 21:30.780] is [21:30.780 --> 21:30.900] more [21:30.900 --> 21:31.100] efficient [21:31.100 --> 21:31.240] because [21:31.240 --> 21:32.600] Solartime [21:32.600 --> 21:33.220] will not [21:33.220 --> 21:34.140] have to [21:34.140 --> 21:34.340] rewrite [21:34.340 --> 21:35.020] everything [21:35.020 --> 21:35.620] which [21:35.620 --> 21:35.760] would [21:35.760 --> 21:36.120] probably [21:36.120 --> 21:36.720] introduce [21:38.480 --> 21:39.260] a lot [21:39.260 --> 21:39.640] more [21:34.580 --> 21:35.460] instability [21:35.460 --> 21:35.540] in [21:35.540 --> 21:35.700] the [21:35.700 --> 21:36.100] system. [21:38.740 --> 21:38.980] As [21:38.980 --> 21:39.140] the [21:39.140 --> 21:39.620] IPL [21:41.280 --> 21:41.800] file [21:41.800 --> 21:42.720] system, [21:42.720 --> 21:42.960] I'll [21:42.960 --> 21:43.340] squeeze in [21:43.460 --> 21:43.620] a little [21:43.620 --> 21:44.180] information [21:44.180 --> 21:45.300] on that. [21:45.440 --> 21:45.680] So [21:45.680 --> 21:46.300] NTFS [21:46.300 --> 21:46.460] is [21:46.460 --> 21:46.600] the [21:46.600 --> 21:46.800] file [21:46.800 --> 21:47.120] system [21:47.120 --> 21:47.340] of [21:47.340 --> 21:47.900] Windows, [21:47.900 --> 21:47.980] and [21:47.980 --> 21:48.380] everything [21:48.380 --> 21:48.800] on an [21:48.800 --> 21:49.380] NTFS [21:49.380 --> 21:49.680] volume [21:49.680 --> 21:50.300] is a [21:50.300 --> 21:51.140] file. [21:51.140 --> 21:51.340] And [21:51.340 --> 21:51.460] one [21:51.460 --> 21:51.580] of [21:51.580 --> 21:51.920] the [21:51.920 --> 21:52.180] special [21:52.180 --> 21:52.320] file [21:52.320 --> 21:52.620] you [21:52.620 --> 21:52.800] have [21:52.800 --> 21:53.440] in [21:53.440 --> 21:54.280] NTFS [21:54.280 --> 21:54.540] is [21:54.540 --> 21:54.980] object [21:54.980 --> 21:55.740] ID [21:55.740 --> 21:56.160] which [21:56.160 --> 21:56.460] contains [21:56.460 --> 21:56.700] unique [21:56.700 --> 21:57.020] IDs [21:57.020 --> 21:57.340] given [21:57.340 --> 21:57.860] to [21:58.540 --> 21:59.060] every [21:59.060 --> 21:59.720] file. [21:59.720 --> 21:59.940] So [21:59.940 --> 22:00.320] the [22:00.320 --> 22:00.580] attributes [22:00.580 --> 22:00.740] of [22:00.740 --> 22:00.880] object [22:00.880 --> 22:01.120] ID [22:01.120 --> 22:01.420] are [22:01.420 --> 22:01.740] the [22:01.740 --> 22:02.000] five [22:02.000 --> 22:02.140] shown [22:02.140 --> 22:02.460] here [22:02.460 --> 22:03.100] at [22:03.100 --> 22:03.320] the [22:03.320 --> 22:03.640] different [22:03.640 --> 22:04.020] offsets. [22:04.020 --> 22:04.200] And [22:04.200 --> 22:04.420] I [22:04.420 --> 22:04.600] would [22:04.600 --> 22:05.020] like [22:05.020 --> 22:05.540] to [22:04.100 --> 22:04.340] draw [22:04.340 --> 22:04.580] your [22:04.580 --> 22:05.140] attention [22:05.140 --> 22:05.620] to [22:05.540 --> 22:05.800] the [22:05.800 --> 22:06.500] third [22:06.500 --> 22:07.060] attribute [22:07.060 --> 22:07.400] which [22:07.400 --> 22:07.580] is [22:07.580 --> 22:07.980] index [22:07.980 --> 22:08.500] root. [22:08.940 --> 22:09.540] Index [22:09.540 --> 22:09.800] root [22:09.800 --> 22:10.000] is [22:10.000 --> 22:10.160] the [22:10.160 --> 22:10.360] root [22:10.360 --> 22:10.660] node [22:10.660 --> 22:10.900] and [22:10.900 --> 22:11.300] contains [22:11.480 --> 22:11.740] a [22:11.740 --> 22:11.960] list [22:11.960 --> 22:12.220] of [22:12.220 --> 22:12.560] all [22:12.560 --> 22:13.000] index [22:13.000 --> 22:13.220] entries [22:13.220 --> 22:13.340] of [22:13.340 --> 22:13.620] the [22:13.620 --> 22:14.020] object [22:14.020 --> 22:17.160] IDs. [22:17.320 --> 22:17.620] So [22:17.620 --> 22:18.060] a [22:18.060 --> 22:18.380] typical [22:18.380 --> 22:18.800] index [22:18.800 --> 22:19.020] entry [22:19.020 --> 22:19.140] structure [22:19.140 --> 22:19.480] in [22:19.480 --> 22:19.700] the [22:19.700 --> 22:19.880] index [22:19.880 --> 22:20.020] root [22:20.020 --> 22:20.360] of [22:20.360 --> 22:20.720] the [22:20.720 --> 22:21.080] object [22:21.080 --> 22:21.380] ID [22:21.380 --> 22:21.620] file [22:21.620 --> 22:21.840] is [22:21.840 --> 22:21.980] called [22:21.980 --> 22:22.400] the [22:22.400 --> 22:23.000] O [22:23.060 --> 22:23.660] index. [22:23.660 --> 22:24.420] And [22:24.420 --> 22:25.400] Solartime [22:25.400 --> 22:25.600] identifies [22:25.600 --> 22:26.120] its [22:26.120 --> 22:26.400] container [22:26.400 --> 22:26.660] file [22:26.660 --> 22:27.000] by [22:27.000 --> 22:27.380] comparing [22:27.380 --> 22:27.740] the [22:27.740 --> 22:28.240] GU [22:28.240 --> 22:28.720] ID [22:28.720 --> 22:28.840] object [22:28.840 --> 22:29.000] ID [22:29.000 --> 22:29.440] value [22:29.440 --> 22:29.680] in [22:29.680 --> 22:29.800] the [22:29.800 --> 22:30.040] O [22:30.040 --> 22:30.380] index [22:30.380 --> 22:30.660] with [22:30.660 --> 22:30.840] the [22:30.840 --> 22:31.160] object [22:31.160 --> 22:32.200] ID [22:32.200 --> 22:32.440] stored [22:30.580 --> 22:30.740] at [22:30.740 --> 22:31.060] address [22:31.060 --> 22:32.180] 7E7A. [22:35.540 --> 22:36.160] MFT file [22:36.160 --> 22:36.740] reference [22:36.740 --> 22:37.140] can be [22:37.140 --> 22:37.660] fetched [22:37.660 --> 22:38.100] to load [22:38.100 --> 22:38.460] the file [22:38.460 --> 22:39.380] record. [22:40.740 --> 22:41.160] So this [22:41.160 --> 22:41.880] diagram shows [22:41.880 --> 22:42.160] how [22:42.160 --> 22:42.580] Solartime [22:42.580 --> 22:43.000] actually [22:43.000 --> 22:43.520] hijacks [22:43.680 --> 22:43.940] a [22:43.940 --> 22:44.500] normal [22:44.500 --> 22:44.740] operation [22:44.740 --> 22:45.400] of the [22:45.400 --> 22:45.920] IPL and [22:45.920 --> 22:46.340] loads [22:46.340 --> 22:46.680] its [22:46.680 --> 22:47.220] container [22:47.360 --> 22:47.740] file. [22:47.740 --> 22:48.120] And in [22:48.120 --> 22:48.580] the [22:48.580 --> 22:48.660] malicious [22:48.660 --> 22:49.120] flow, [22:49.120 --> 22:50.060] Solartime [22:50.060 --> 22:50.340] passes [22:50.340 --> 22:50.860] the [22:50.860 --> 22:51.160] object [22:51.160 --> 22:51.640] ID [22:51.640 --> 22:51.880] index [22:51.880 --> 22:52.020] root [22:52.020 --> 22:52.500] depending [22:52.500 --> 22:53.500] on the [22:53.800 --> 22:54.360] ECX [22:54.360 --> 22:54.860] register. [22:54.860 --> 22:55.060] This [22:55.060 --> 22:55.260] object [22:55.260 --> 22:55.600] ID [22:55.600 --> 22:56.040] file [22:56.040 --> 22:56.320] is [22:56.320 --> 22:56.580] not [22:56.580 --> 22:56.820] usually [22:56.820 --> 22:56.940] loaded [22:56.940 --> 22:57.380] or [22:57.380 --> 22:57.780] needed [22:57.780 --> 22:58.040] in [22:58.160 --> 22:58.380] the [22:58.380 --> 22:59.180] IPL [22:59.180 --> 22:59.720] section [22:59.740 --> 23:00.120] of a [23:00.120 --> 23:00.280] normal [23:00.280 --> 23:00.760] boot [23:00.760 --> 23:01.460] process. [23:01.460 --> 23:01.820] And [23:01.820 --> 23:02.220] if the [23:00.580 --> 23:01.140] ECX [23:01.140 --> 23:01.620] register [23:01.620 --> 23:01.780] is [23:01.780 --> 23:02.340] set, [23:02.340 --> 23:02.500] a [23:02.220 --> 23:02.480] standard [23:02.480 --> 23:02.800] load [23:02.800 --> 23:03.020] will [23:03.020 --> 23:03.600] occur. [23:03.600 --> 23:03.720] If [23:03.720 --> 23:04.160] not, [23:04.160 --> 23:04.260] it [23:04.260 --> 23:04.420] will [23:04.420 --> 23:04.720] load [23:04.720 --> 23:05.020] the- [23:05.020 --> 23:05.300] load [23:05.300 --> 23:05.540] the [23:05.540 --> 23:05.960] index [23:05.960 --> 23:06.220] root [23:06.220 --> 23:06.500] of [23:06.500 --> 23:06.700] the [23:06.700 --> 23:07.000] object [23:07.000 --> 23:07.300] ID [23:07.300 --> 23:08.180] file, [23:08.180 --> 23:08.540] locates [23:08.540 --> 23:08.760] the [23:08.760 --> 23:09.100] index [23:09.100 --> 23:09.560] entry [23:09.560 --> 23:09.860] of [23:09.860 --> 23:10.000] the [23:10.000 --> 23:10.340] container [23:10.340 --> 23:10.980] file, [23:10.980 --> 23:11.360] and then [23:11.360 --> 23:11.580] load [23:11.580 --> 23:11.780] the [23:11.780 --> 23:11.980] file [23:11.980 --> 23:12.380] record [23:12.380 --> 23:12.740] before [23:12.740 --> 23:13.100] loading [23:13.100 --> 23:13.320] the [23:13.320 --> 23:13.540] file [23:13.540 --> 23:14.420] data. [23:16.400 --> 23:16.920] So [23:16.920 --> 23:17.240] on the [23:17.240 --> 23:17.480] left [23:17.480 --> 23:17.880] shows [23:17.880 --> 23:18.120] the [23:18.120 --> 23:18.440] file [23:18.440 --> 23:18.780] record [23:18.780 --> 23:18.980] of [23:18.980 --> 23:19.160] the [23:19.160 --> 23:19.360] boot [23:19.360 --> 23:19.740] pack [23:19.740 --> 23:20.200] loaded [23:20.200 --> 23:20.500] with [23:20.500 --> 23:20.660] the [23:20.660 --> 23:20.880] name [23:20.880 --> 23:21.220] david [23:21.220 --> 23:21.500] byte [23:21.500 --> 23:21.680] or [23:21.680 --> 23:22.800] ttf. [23:22.900 --> 23:23.280] And [23:23.280 --> 23:23.440] on [23:23.440 --> 23:23.580] the [23:23.580 --> 23:23.800] right [23:23.800 --> 23:24.080] are the [23:24.080 --> 23:24.520] contents [23:24.520 --> 23:24.740] of [23:24.740 --> 23:24.860] the [23:24.860 --> 23:25.060] file [23:25.060 --> 23:25.300] being [23:25.300 --> 23:25.620] loaded [23:25.620 --> 23:25.840] to [23:25.840 --> 23:26.220] address [23:26.220 --> 23:27.840] 600,000. [23:28.800 --> 23:29.480] And [23:29.480 --> 23:29.640] so [23:29.640 --> 23:29.900] after [23:29.900 --> 23:30.280] loading [23:30.280 --> 23:30.460] the [23:30.460 --> 23:30.640] true [23:30.640 --> 23:30.920] type [23:30.920 --> 23:31.220] font [23:31.220 --> 23:31.780] file, [23:31.780 --> 23:32.100] SOTY [23:32.100 --> 23:32.700] decrypts [23:32.700 --> 23:32.980] the [23:32.980 --> 23:33.220] malware [23:33.220 --> 23:33.600] using [23:33.600 --> 23:33.780] the [23:33.780 --> 23:34.200] encryption [23:34.200 --> 23:34.580] key [23:34.580 --> 23:34.920] hidden [23:34.920 --> 23:35.260] under [23:35.260 --> 23:36.860] 7E7A. [23:36.860 --> 23:37.300] After [23:37.300 --> 23:37.840] decryption [23:37.840 --> 23:38.060] of [23:38.060 --> 23:38.220] the [23:38.220 --> 23:38.780] malware, [23:38.780 --> 23:39.160] Solartime [23:39.160 --> 23:39.380] then [23:39.380 --> 23:39.720] proceeds [23:39.720 --> 23:39.940] on [23:39.940 --> 23:40.080] to [23:40.080 --> 23:40.440] calculate [23:40.640 --> 23:41.680] a [23:41.680 --> 23:42.640] CRC32 [23:42.640 --> 23:42.960] hash [23:42.960 --> 23:43.140] to [23:43.140 --> 23:43.600] verify [23:43.600 --> 23:44.280] the [23:45.820 --> 23:46.500] file [23:46.500 --> 23:46.920] integrity. [23:46.920 --> 23:47.040] So [23:47.040 --> 23:47.460] how [23:47.460 --> 23:47.720] can [23:47.720 --> 23:48.460] we [23:48.460 --> 23:49.140] detect [23:49.140 --> 23:49.740] and [23:49.740 --> 23:50.420] remediate [23:50.420 --> 23:51.720] Solartime? [23:51.720 --> 23:51.860] Since [23:51.860 --> 23:53.520] Qsuit [23:53.520 --> 23:54.620] can only [23:54.620 --> 23:54.860] use [23:54.860 --> 23:55.500] Solartime [23:55.500 --> 23:55.660] to [23:51.820 --> 23:52.380] install [23:52.380 --> 23:52.620] on [23:53.180 --> 23:53.500] modern [23:53.500 --> 23:54.060] operating [23:54.060 --> 23:54.620] systems [23:54.620 --> 23:54.860] that are [23:54.860 --> 23:55.180] still [23:55.180 --> 23:55.420] using [23:55.420 --> 23:55.580] the [23:55.660 --> 23:55.980] legacy [23:55.980 --> 23:56.900] boot, [23:56.900 --> 23:57.320] detecting [23:57.320 --> 23:57.920] Solartime [23:57.920 --> 23:58.780] will be a [23:58.780 --> 23:59.020] solution [23:59.020 --> 23:59.480] to [23:59.480 --> 23:59.840] detecting [23:59.840 --> 24:00.180] all [24:00.180 --> 24:02.860] Qsuit [24:02.860 --> 24:03.560] instances. [24:03.560 --> 24:03.900] Installation [24:03.900 --> 24:04.320] of [24:04.320 --> 24:05.260] Solartime [24:05.260 --> 24:05.920] can be [24:05.920 --> 24:06.000] determined [24:06.000 --> 24:06.060] in [24:06.060 --> 24:06.200] two [24:06.200 --> 24:06.640] ways. [24:06.640 --> 24:07.420] First, [24:07.420 --> 24:08.120] you can [24:08.120 --> 24:08.320] use [24:08.320 --> 24:08.400] the [24:08.400 --> 24:08.620] checked [24:08.620 --> 24:09.940] Solartime [24:09.940 --> 24:10.460] Python [24:10.460 --> 24:11.020] script, [24:11.020 --> 24:11.200] but [24:11.200 --> 24:11.600] this is [24:11.600 --> 24:11.780] inconvenient [24:11.780 --> 24:12.080] because [24:12.080 --> 24:12.520] you probably [24:12.520 --> 24:13.280] need to [24:13.660 --> 24:14.220] pawn [24:14.220 --> 24:14.440] your [24:14.440 --> 24:14.580] own [24:14.580 --> 24:14.780] machine [24:14.780 --> 24:14.980] to [24:14.980 --> 24:15.260] check [24:15.260 --> 24:15.780] it. [24:15.780 --> 24:16.260] Examination [24:16.260 --> 24:16.580] of [24:16.580 --> 24:16.740] the [24:16.740 --> 24:16.900] script [24:16.900 --> 24:17.240] did [24:17.240 --> 24:17.600] reveal [24:17.600 --> 24:17.900] things [24:17.900 --> 24:18.140] that [24:18.140 --> 24:18.500] are [24:18.500 --> 24:19.000] helpful [24:19.000 --> 24:19.280] which [24:19.280 --> 24:19.480] are [24:19.480 --> 24:19.720] the [24:19.720 --> 24:20.100] various [24:20.100 --> 24:20.620] names [24:20.620 --> 24:20.980] the [24:20.980 --> 24:21.160] kernel [24:21.160 --> 24:21.400] driver [24:18.540 --> 24:19.020] container [24:19.020 --> 24:19.260] could [24:19.260 --> 24:19.420] be [24:19.420 --> 24:19.820] stored [24:19.820 --> 24:20.140] under. [24:20.780 --> 24:21.020] So [24:21.020 --> 24:21.100] in [24:21.100 --> 24:21.420] this [24:25.660 --> 24:26.520] slides. [24:26.880 --> 24:27.460] And [24:27.460 --> 24:27.600] the [24:27.600 --> 24:27.840] second [24:27.840 --> 24:28.140] way [24:28.140 --> 24:28.280] of [24:28.280 --> 24:28.740] detection [24:28.740 --> 24:29.320] is to [24:29.320 --> 24:29.560] check [24:29.560 --> 24:29.760] the [24:29.760 --> 24:30.040] volume [24:30.040 --> 24:30.240] boot [24:30.240 --> 24:30.540] record [24:30.540 --> 24:31.500] itself. [24:31.500 --> 24:31.780] As [24:31.780 --> 24:32.420] mentioned, [24:32.420 --> 24:32.860] Solartime [24:32.860 --> 24:33.300] alters [24:33.300 --> 24:33.520] the [24:33.520 --> 24:34.500] VBR, [24:34.500 --> 24:34.780] changing [24:34.780 --> 24:35.220] the jump [24:35.220 --> 24:35.720] address [24:35.720 --> 24:35.980] when [24:35.980 --> 24:36.500] transferring [24:36.500 --> 24:37.000] control [24:37.000 --> 24:37.400] to the [24:37.400 --> 24:38.500] IPL. [24:38.500 --> 24:38.840] And in [24:38.840 --> 24:39.000] doing [24:39.000 --> 24:39.380] so, [24:39.380 --> 24:39.500] it [24:39.500 --> 24:39.860] inputs [24:39.860 --> 24:40.160] two [24:40.160 --> 24:40.420] NOP [24:40.420 --> 24:40.980] commands [24:40.980 --> 24:41.220] at [24:41.220 --> 24:41.360] the [24:42.040 --> 24:42.620] 267 [24:42.620 --> 24:42.880] and [24:42.880 --> 24:43.940] 268 [24:43.940 --> 24:44.300] bytes [24:44.300 --> 24:44.560] of [24:44.560 --> 24:44.700] the [24:44.700 --> 24:45.780] VBR. [24:46.520 --> 24:47.100] So [24:47.100 --> 24:47.340] this [24:47.340 --> 24:48.060] alteration [24:48.060 --> 24:48.580] can be [24:48.580 --> 24:48.860] searched [24:48.860 --> 24:49.460] by using [24:49.460 --> 24:50.480] Python. [24:50.480 --> 24:50.680] We [24:50.680 --> 24:51.100] modified [24:51.100 --> 24:51.320] the [24:51.320 --> 24:51.540] open [24:51.540 --> 24:51.940] source [24:51.940 --> 24:52.380] code [24:52.380 --> 24:53.100] PyMBR [24:53.100 --> 24:53.460] written [24:53.460 --> 24:53.720] by [24:53.720 --> 24:54.760] Hamtas. [24:54.760 --> 24:55.000] And in [24:55.000 --> 24:55.140] our [24:55.660 --> 24:56.120] version, [24:56.120 --> 24:56.400] find [24:56.400 --> 24:56.580] the [24:56.580 --> 24:56.840] first [24:56.840 --> 24:57.280] section [24:57.280 --> 24:57.480] of [24:57.480 --> 24:57.600] the [24:57.600 --> 24:58.020] MBR [24:58.020 --> 24:58.300] to [24:58.300 --> 24:58.520] find [24:58.520 --> 24:58.660] the [24:58.660 --> 24:59.080] start [24:59.080 --> 24:59.320] of [24:59.320 --> 24:59.440] the [24:59.440 --> 25:00.120] VBR. [25:00.120 --> 25:00.480] We [25:00.480 --> 25:00.680] then [25:00.680 --> 25:00.900] check [25:00.900 --> 25:01.040] the [25:01.040 --> 25:01.340] data [25:01.340 --> 25:01.560] in [25:01.560 --> 25:01.680] the [25:01.680 --> 25:02.140] VBR [25:02.140 --> 25:02.480] at [25:02.480 --> 25:02.640] byte [25:03.360 --> 25:03.860] 267 [25:03.860 --> 25:04.080] and [25:04.080 --> 25:05.040] 268 [25:05.040 --> 25:05.240] for [25:05.240 --> 25:05.400] the [25:05.400 --> 25:05.620] hex [25:05.620 --> 25:05.980] value [25:05.980 --> 25:06.960] 90, [25:06.960 --> 25:07.320] which [25:07.320 --> 25:07.480] is [25:07.480 --> 25:07.680] code [25:07.680 --> 25:07.900] for [25:07.900 --> 25:08.680] NOP. [25:09.100 --> 25:09.780] And if [25:09.780 --> 25:09.940] the [25:09.940 --> 25:10.100] NOP [25:10.100 --> 25:10.360] value [25:10.360 --> 25:10.620] in [25:10.620 --> 25:11.040] place [25:11.040 --> 25:11.380] is [25:11.380 --> 25:11.540] in [25:11.540 --> 25:11.860] place, [25:11.860 --> 25:11.920] we [25:11.920 --> 25:12.040] can [25:12.040 --> 25:12.420] confirm [25:12.420 --> 25:12.580] that [25:12.580 --> 25:12.720] the [25:12.720 --> 25:13.040] VBR [25:13.040 --> 25:13.320] has [25:13.320 --> 25:13.520] been [25:13.520 --> 25:14.400] modified. [25:15.400 --> 25:15.760] So [25:15.760 --> 25:16.260] Solartime [25:16.260 --> 25:16.420] is [25:16.420 --> 25:16.660] really [25:16.660 --> 25:16.940] hard [25:16.940 --> 25:17.140] to [25:17.140 --> 25:17.480] prevent [25:17.480 --> 25:17.860] because [25:17.860 --> 25:18.020] it [25:18.020 --> 25:18.520] infects [25:18.520 --> 25:18.680] the [25:25.660 --> 25:26.360] However, [25:26.360 --> 25:26.620] since [25:26.620 --> 25:27.200] Solartime [25:27.200 --> 25:27.420] does [25:27.420 --> 25:27.680] only [25:27.680 --> 25:28.060] affect [25:28.060 --> 25:28.260] the [25:28.260 --> 25:28.620] legacy [25:28.620 --> 25:28.880] boot [25:28.880 --> 25:29.540] systems, [25:29.540 --> 25:29.840] opting [25:29.840 --> 25:30.060] for [25:30.060 --> 25:30.700] UEFI [25:30.700 --> 25:31.120] secure [25:31.120 --> 25:31.360] boot [25:31.360 --> 25:32.040] would prevent [25:32.040 --> 25:32.640] Solartime [25:32.640 --> 25:32.860] from [25:32.860 --> 25:33.780] working. [25:35.080 --> 25:35.720] Okay, [25:35.720 --> 25:35.840] so [25:35.840 --> 25:36.040] this [25:36.040 --> 25:36.160] is [25:36.160 --> 25:36.480] supposed [25:36.480 --> 25:36.700] to [25:36.700 --> 25:36.860] be [25:37.000 --> 25:37.220] a [25:37.220 --> 25:37.480] talk [25:37.480 --> 25:37.700] given [25:37.700 --> 25:38.120] by [25:38.120 --> 25:38.620] Francisco [25:38.620 --> 25:39.380] Donoso, [25:39.380 --> 25:39.600] but [25:39.600 --> 25:39.960] internet [25:39.960 --> 25:40.220] is [25:40.220 --> 25:40.520] definitely [25:40.520 --> 25:40.820] not [25:40.820 --> 25:41.340] working [25:42.140 --> 25:42.920] now. [25:42.920 --> 25:43.100] But [25:43.100 --> 25:43.320] this [25:43.320 --> 25:44.580] is what [25:44.580 --> 25:45.060] inspired [25:45.060 --> 25:45.480] our [25:45.480 --> 25:45.960] research. [25:45.960 --> 25:46.080] And [25:46.220 --> 25:46.460] this [25:46.460 --> 25:48.320] is a [25:48.320 --> 25:48.700] book [25:48.700 --> 25:49.200] that [25:49.200 --> 25:49.880] is [25:49.880 --> 25:50.900] also [25:50.900 --> 25:51.300] fantastic [25:51.300 --> 25:51.480] for [25:51.480 --> 25:51.560] my [25:51.560 --> 25:51.980] research, [25:51.980 --> 25:52.180] so [25:52.180 --> 25:52.380] do [25:52.380 --> 25:52.560] check [25:52.560 --> 25:52.700] them [25:52.700 --> 25:52.940] out [25:52.940 --> 25:53.260] if [25:53.260 --> 25:53.780] you [25:54.640 --> 25:55.160] have [25:52.940 --> 25:53.180] time. [25:54.460 --> 25:54.860] And [25:55.660 --> 25:56.300] yep, [25:56.300 --> 25:56.440] we're [25:56.440 --> 25:57.280] done.