start	end	text
0	6220	Okay, we're about time so thank you again for being here. Um, hopefully you've been
6220	11220	enjoying DEF CON. Closing ceremonies will be soon here for the village. Later on you can
11220	15900	go and head out to uh, closing ceremonies for DEF CON. If this is your first time,
15900	20740	hopefully you had a good time. I hope that you made some friends and if you haven't,
20740	25200	then please talk to the person next to you. They might uh, be into the same things that
25200	29540	you are. Uh, and I really recommend you go to the closing ceremonies. It's always a lot
29540	32780	of fun. Again, thank you for being here. Cheers.
34860	36960	Round of applause.
40500	50200	Alright, welcome. Uh, really cool way to finish up the day. Uh, understudy 77, he is uh, not
50200	56220	only paranoid but he is actually a-paranoid. Like that's, that's in his title. How cool
56220	62820	is that, right? So, um, he's a paranoid with Verizon. Um, head of security operations.
63180	69080	Head of security operations. And um, he's going to talk, talk to you guys a little about
69080	78440	uh, hold on. Okay, cool. Um, he's going to talk with you guys about uh, an introduction
78440	82700	of malware RE, reverse engineering. If you haven't done it before, he and I were just
82700	88940	talking. Um, this is a really cool talk because it's going to be an anybody can do malware
88940	93480	reverse engineering kind of talk. So, really looking forward to this. Give him a hand.
100350	104610	Uh, sorry just to interrupt. We just, we just, the open talk just ended so if you hear a
104610	108750	little bit of noise it's because of that. So, why don't we just give him a good applause to
108750	113490	everyone that participated in the open talk because they just completed. CTF is over.
113490	114390	Sorry for that.
120070	125970	So, I want to start off at the end of the weekend by asking, did everybody have a really
125970	134190	good DEF CON and Hacker Summer Camp? All right. So, I've been here most of the weekend and
134190	137870	I want to say two things. First off, I want a round of applause for all the volunteers
137870	142450	and organizers of Blue Team Village. They kicked ass, did a really good job and a lot
142450	152710	of work. And secondly to Open Sock. Um, it was an awesome CTF and I sat up here in the
152710	157090	evening and watched them rebuild the whole thing because everybody killed it. So, they
157090	167840	worked tirelessly. I'm sure they're all tired and somebody should buy them beer. So,
167840	172180	let's do an introduction to malware analysis. Uh, I'll start with the introductions. I'm
172180	175900	the head of the security operations center at Verizon Media. I was an IR and breach
175900	180200	consultant once upon a time, slash threat hunter. Um, I'm probably a little bit rusty on
180200	184240	this topic so don't hold anything too far against me. Management. Uh, and I'm pretty
184240	189980	shitty at Twitter. Now, let's talk about what this is and what this isn't. Um, I have not
189980	193740	done this every day in a little while. I love teaching this because every time I add
193740	197780	something new and I get to do something new and learn something new. Um, there's a lot
197780	202400	more tools and different things than what I'm going to be using. This is very much an
202400	209540	introduction. Um, I built this specifically to lower the entry barrier and make the
209540	215160	concept of analyzing malware seem not so difficult. So, some people may or may not be my
215160	219200	target market and that's okay. But, I just want to make sure that I'm very clear about what
219200	223920	this is going into it. So, we can talk a little bit about what tools we're going to be using
223920	229520	primarily. I run Ubuntu 14.04 with Remnux. Remnux is an open source malware analysis
229520	235360	distro. Oh, I should mention as well, photos are fine this way. Um, I wouldn't take them
235360	240660	that way but I know that's a sensitive topic so I want everybody to know I don't care. Um,
240660	248140	in Remnux we're going to use some tools like PDF ID, PDF parser, um, OLE tools and VMs. From
248260	252480	a VM perspective we're going to be looking at things like Process Explorer, RegShot, Fiddler,
252480	257380	Wireshark. Um, we're also going to kind of touch a little bit on Cuckoo Sandbox and how you
257380	263160	can kind of automate some of this process that we're going to go over as well. So, let's set
263160	267900	up the scenario. You are a security analyst for the Daily Bugle. You received an alert or
267900	274060	notification about a suspicious email with an attachment. You got a copy of that attachment. So
274060	279840	you have a PDF right now. So now we can jump right into it. Into the good part. By the way,
279840	284460	this is all demo pretty much and I've prayed intensely to the demo gods that this is going to
284460	294920	work out okay. So, we have a PDF right here. Here's our suspicious PDF. We can do a couple
294920	300940	things to look into this. I like to start with PDF ID. Is this big enough? Can everybody read
300940	308400	it? I tried to make the size really big. Great. So, I'm already in my directory and we can hit
308400	315220	PDF ID and our file name. And we can see what's going on with this. So, if we look through
315220	319620	this, this is going to tell us in the header what's there. So, this is going to tell us
320420	326120	objects. This is going to tell us JavaScript. Importantly in this case, this is going to tell
326120	330940	us that we have an embedded file. That's interesting. Why would you put a file inside your
330940	335980	PDF? So, there's a couple different ways we can get it. We can go to a sandbox. We can open the
335980	340500	PDF and we can get the file. Or we can use some other tools. But let's see if we can find out
340500	346080	some more information about it first. So, I'm going to go ahead and clear this out. And then
346080	351880	let's see what we can find out about that file. And let's start with the file name and see if
351880	365720	we can find that. So, embedded files. Looks like a Word doc. 602803.doc. Also interesting. What
365720	372960	can we find out about that file? Or general information about this PDF in general. Or more
372960	381200	information about this PDF in general. And this is where the demo stuff happens. Because I
381200	387480	forget to type things. So, we see that there's an embedded file. We can go through. There's
387480	394240	the name. Some additional information. This will basically break down the whole PDF and give
394240	399560	you general information from it. It's really useful. It's not as human readable as either of
399560	408380	the other tools we just talked about, though. So, here's our who wrote and who made. So, now
408380	412680	we need to get that. And preferably I think we'd like to get that in a safe way. Although I do
412680	417180	like clicking on everything that I can click on. I find that that's one of my favorite things in
417180	424640	this world to do. But we'll do it the safe way. So, we'll do detach again. We know there's only
424640	431060	one file there. So, we can do save all. And then we can hit step one. So, if you take a look
431060	439700	here, this is all laid out for ease of use in case something breaks. But if I run this and we
439700	445700	take a look back there, we've now saved out our document. Easy. So, we've now successfully
445700	452840	extracted a document from a PDF file. So, now we get into analysis of that document. There's no
452840	457720	internet for this. Typically I would be on a VPN and online. But I don't really want to be
457720	464060	executing live malware throughout this experience. So, I'm going to go ahead and I'm going to
464060	470840	open up a VM. And we're going to start there. So, we will start with opening up this document
470840	480800	and seeing what we see. Because I find that to be fun. So, if we take our doc, we move it over
480800	489300	to our VM. We can run a couple things here. And we're going to talk more in-depthly about
489300	494880	different tools as we get into the file analysis as well. So, as soon as this paces, this is
494880	504580	the downside of live demos, right? I can start opening things though. For anybody
504580	511780	unfamiliar, Fiddler is basically a web debugger. So, if I have, if I'm suspicious that web based
511780	514740	call outs are going to happen or something of that nature and I'm not worried about just
514740	520140	general TCP connections, I like to use Fiddler because it displays everything really nicely and
520140	533970	very easily. So, I'm a big fan. We'll use Wireshark later as well. Come on. You know the
533970	541370	really crappy part about this is I practiced this six times and had no issues. And now,
541370	569090	everything wants to freeze. Cancel. Let's try that again. Hey, there we go. It's back.
578410	587050	All right. So, we have a document. We have something capturing web traffic. And right now,
587050	592610	we're going to get something capturing processes as well. For this, we'll use process
592610	599710	explorer. Process explorer is essentially like task manager on steroids and will give you a lot
599710	611790	more information. Yes. So, interesting thing. Process explorer is going to be pretty live. So,
611790	616950	things are going to disappear. Things are going to go away. Where Fiddler is going to record.
617010	621810	So, in this use case, I tend to always keep process explorer top so that I can pay attention
621810	626970	to it quickly. And then I'll go back to and look at the network traffic afterward. So, as we
626970	634630	open up this document, we can see here that there is a macro. We can also shrink this down so
634630	641950	it's out of our way. And we can enable content because we like to live dangerously. So, we can
641950	649270	see WinWord here. We can see PowerShell just popped up and did a lot of things. And now, it's
649270	655830	gone. So, let's move over here and see what else happened. A lot of these are going to be
655830	663590	Microsoft because I don't open Word that often. But I see a couple things that look kind of
663590	668150	suspicious over here. They can't go anywhere. But that's not traffic I would expect. That's
668150	677990	relatively suspicious. So, it's trying to get something. And if I expand this out a bit, we can
677990	682470	go take a look and see if it did anything. Although, we probably won't see very much because
682470	690190	it's not connected to the internet. Where are you? So, that's one way without network
690190	694370	connection that we can get access to see this kind of stuff. So, here's something
694370	699830	interesting. We see two URLs at least in this use case. It couldn't connect to one. It jumped
699830	706150	to another. A lot of different pieces of malware will have multiple URLs built in. In the case
706150	711030	of those multiple URLs, if you connect to the first one, meaning if the first time you run it,
711030	714870	you're on a virtual machine that connects to the internet, you might never see the second
714870	723010	piece. So, I tend to run everything first offline and then run online. I also tend to let a
723010	727190	lot of this stuff sit for several hours to see if anything happens afterward. But in this
727190	732650	case, I think there's an easier way to go through this data. So, we can go ahead and we can
732650	741010	close out some of this stuff. We'll keep some of it open. And we can go back over here. So,
741030	746770	there's a tool suite called OLE tools. Which basically will look at things and tell us what
746770	754890	they are. In this case, we're going to use OLE VBA because we know there's visual basic. Step
754890	764530	two. So, we know we have a macro user form one. It can auto exact document open. It may
764530	770510	execute or may run an executable or a system command which it launched CMD. Hex encoded
770510	776390	strings detected and executable file name being that it ran CMD. So, if we want to see
776390	787950	more on this, hit D to decode. And again, pipe more. So, this is going to give us the full
787950	794090	context around that. So, just from the beginning, we can see call command line, call
794090	799670	PowerShell. No profile. So, it's going to ignore any built in PowerShell settings. Window
799670	803850	style hidden. So, you're not going to see it run. Executable bypass. So, it's going to try to
803850	808930	bypass execution policy that you have on your computer and run locally. And then we've got a
808930	816950	whole bunch of other stuff going on here. Just numbers. And numbers and numbers and numbers.
816950	827730	So, what that data ends up looking like is this. Not really super useful yet, right? So, we
827730	832430	could probably assume that this entire section here is encoded. Actually, this entire section
832430	838990	here is decimal encoded. Is anybody here or everybody here familiar with a tool called
838990	844970	CyberChef? Great tool for this kind of stuff. Makes everything very fast. So, I can go in
844970	851690	here. I can paste all that in. And I can go from decimal. Well, that didn't work. But
851690	856710	everything is comma delimited. And you have to specify that. So, if I specify comma
856710	863730	delimited, now we have a lot more information. So, we can see some stuff. But there's still a
863730	871550	lot going on. So, I can see that there's an XOR key. This looks like byte string. Some pieces
871550	877250	of URLs down there. But there's a lot going on with this. And this is kind of an interesting
877250	882130	way to encode an additional layer. Basically, what they're doing is they're shifting numbers.
882130	888890	So, like in URLs, they're saying 10, 1, 13. And that's taking this list here and counting
888890	898650	from that list, that number. So, if we use that and take a look at that in another way, that's
898650	903770	the wrong, oh, no, that's the right one. Because that's this. We can also see an executable
903770	909290	down there. So, if we use that and we want to get rid of that, we'll use URLs as an example.
909290	913110	So, I took each one of those URL pieces. I haven't found an automated way to do this, by
913110	916450	the way. If anybody knows an automated way to do this, that would be great. Because manual
916450	925770	takes some time. Count them from 0 up. So, 0 to 20. And then piece these together. 10, H, 1,
925770	932570	TTP, and so on and so forth. And you now have three URLs. So, we saw two. We didn't see the
932570	937850	third one. But we know that there's three hard-coded URLs in this sample. Or in this piece
937850	944350	of code. If we deobfuscate the whole thing, it gets more interesting. So, we see our
944350	950650	PowerShell. We see no profile. We see hidden. We see executable bypass. And now we start to
950650	955030	get into some other interesting stuff. So, some variable calling. There's an XOR key in
955030	963270	there for XOR encoding. Um, byte string link sets. Here's our URLs. And then we start to get
963270	974440	into down here. So, write host URL. There's our file. That we're going to see. Here's our
974440	984580	write. New object. Download file invoke URL. And then unXOR. And then write bytes unXOR and
984580	990340	start said process. So, what that means, and this is a little bit out of scope of what I'm
990340	993520	going to talk about throughout the whole thing. But it's worth mentioning. If I go to one of
993520	1000280	those URLs and I WGIT and I pull down that file, it's an incomplete file. It's an XOR file that
1000280	1007260	needs to be unencoded again, which this script does. Um, I've already done that part. So, I
1007260	1017340	already have the completed file. So, we can start talking about that completed file. So, now we
1017340	1023160	get down to an EXE. So, we have an EXE. We can take a look at it. We're unsure. And now is
1023160	1029440	where we get into running malicious files. So, same system. We're going to have process
1029440	1040360	explorer up. In this case, we're going to use Wireshark. And I'm going to hide that off in the
1040360	1047960	bottom. And we're going to use another tool called RegShot. So, RegShot will take two
1047960	1052180	snapshots of your registry at different times. So, I click a button, it captures the entirety
1052180	1056380	of my registry. I click another button, it captures the entirety of my registry again. And
1056380	1062560	then compares the two files for any potential changes. So, we'll go ahead and pop that open.
1063060	1071020	And we'll take our first shot. Now, none of this is an exact science. If you have any
1071020	1075600	background processes running, things that can affect your registry, those things may come up
1075600	1080360	as well. So, unless it's a completely clean system, you might run into some things. One of
1080360	1085320	the reasons why I didn't restart this is so that it would be cleaner and all background
1085320	1091120	processes would finish running. So, that I would get the best shot possible. So, now we
1091120	1099670	will move over our file. We've got everything open. I want to make sure Process Explorer is
1099670	1108990	front and center. And we'll run it. So, we see here it is. And it's making a call to SVCHost,
1108990	1115450	which is Windows Service Host File. And now it's gone. But, SVCHost with that file still
1115450	1124590	there. That's interesting. It's doing something. Do we have any network traffic? In this case,
1124590	1133010	I'm just going to filter for TCP. And we have network traffic. Not much of any network traffic,
1133010	1137370	because, again, not connected to the internet. But, that's an unexpected call. I don't know
1137370	1145430	why my computer would be going to 199.36.194.27. So, we have network traffic, too. So,
1146010	1151090	we have network traffic. We have a suspicious SVCHost running. We can take a look at the
1151090	1155590	properties of that and kind of go through. We can continue to see the parent process here. We
1155590	1160090	can continue to see what it's doing, what it looks like, if there's an auto start location, the
1160090	1165070	command line that was run, where it's running from. Get performance graphs of how it's
1165070	1172890	running. General performance of it. GPU graph. Threads that it's running and strings of that
1172890	1178070	file. So, this is strings of the actual SVCHost. We can run strings of the specific file, as
1178070	1193810	well, over here. Strings are... I don't know how to properly explain them. Step 8. Step 9. But,
1193810	1198730	you can go through this and you can find some interesting things. So, going through this, a lot
1198730	1201890	of it's going to seem a little bit out of place, but I might be able to find some interesting
1201890	1209590	calls. And I know there's a couple interesting ones in here. So, I can see a couple things right
1209590	1215850	through here. So, set class, registry, call message filter, some calls to some DLLs,
1216290	1220890	initializations, all of these things are kind of the full word pieces of the pieces that I'm
1220890	1224590	potentially interested in when I'm going through this. This might give me an idea of what the
1224590	1231090	file does. Before I run it or after I run it or whenever. I'll get some idea. And if we look at
1231090	1245600	the registry, some of that should match up. So, we'll go ahead and take our second shot. And
1245600	1255060	then we'll compare. So, let's see. We added three keys. Google one, that's probably Google
1255840	1262620	doing something. Microsoft tracing to SVC host, that's expected. We saw that file kind of
1262620	1268380	launch from SVC host. So, we expect that. But now we know it's in registry. We have enable
1268380	1274340	file tracing, enable console tracing. And again, this is very much a touch base on things. So,
1274340	1278760	I'm not going to go into what every one of these things may mean. Just how to run it, how to find
1278760	1286280	it, some things that might be concerning or interesting. So, file directory. Then we get into
1286280	1292620	our modified values, which we're also going to get some stuff in here. I'm not as good at reading
1292620	1300360	text as I used to be. So, looking for potential current versions of different file pieces,
1300360	1312130	window placement, so on and so forth. So, we have network traffic. We have a rogue process that
1312130	1316310	looks like a legitimate Windows process and we have registry files that have changed. So,
1316310	1319990	there's a couple different ways that you can go about this. You can reimage a box like most
1319990	1325450	places do or you can go kind of harp in on each one of those individual problems. Piece by
1325450	1335030	piece. There's also a much easier way to do this, although I genuinely suggest that
1335030	1339470	everybody kind of do it in an automated or in a manual fashion as they're learning this
1339470	1344510	process. I also realize that I'm speeding through this really fast. So, I hope I'm not like
1345030	1353210	blowing anything off. I tend to go a little quick. Speak louder? Sorry. Yeah, I was standing
1353210	1361030	back there yesterday and I realized I couldn't hear much either. No problem. So, automated
1361030	1367990	sandboxing. Is anybody not familiar? Familiar? We'll talk about it anyway. Everything here is
1367990	1371110	free and open source. Everything that I'm using throughout the course of this is free and open
1371110	1375970	source. So, you can do it at home. As we get into automated sandboxing, you can build this, set
1375970	1381630	it up yourself. You need a VM, some scripts to point to it, things of that nature. And it's
1382030	1389550	literally drag and drop. So, I can take this file, I can drag and drop it to submit and then I can
1389550	1393630	tell it a whole bunch of things. Do I want it to connect to the internet? Yes, no. Do I want to
1393630	1398130	give it a priority? What's the time out? So, how long do I want to let this run for? Now,
1398130	1402370	again, one of the things I like about running something manually is I will let a file, if I'm
1402370	1406530	doing an engagement or was doing an engagement, I would often let a file run for like 24
1406530	1411390	hours. See if it did anything else interesting in that time period. In this case, you're
1411390	1417210	looking at 60 to 120. You can give it whatever set you want, but it might not get any more
1417210	1423550	information. You can add remote control, enable injection, dump process memory, um, dump
1423550	1429670	full memory, and a whole bunch of other options. There's also a wild amount of add-ons that
1429670	1435910	exist for this tool. So, you can add just about everything you want. Now, that said, even
1435910	1441150	though I'm going fast, if I run this right now, it'll take like 10 minutes probably to go
1441150	1445310	through and boot. But I've already run it because, again, I'm terrified something's going to
1445310	1451050	break. So, we can just look at the report. So, same file we looked at before, let's see if
1451050	1456350	anything matches up. Cuckoo also adds a whole bunch of base signatures. So, it's looking for
1456350	1462230	things that look suspicious, essentially. So, we can see a couple different things as we go
1462230	1468290	through this. We can, I like to start with red. Red is bad. Yellow could be bad. Blue, maybe.
1468950	1475430	Order of priority by color. Um, attempts to identify installed AV. It's looking for trend
1475430	1480910	micro. Deletes its original binary from disk. We watched that happen. Collects information
1480910	1487670	about some other installed applications. Queries details from the computer. So, you can get a
1487670	1493590	lot of general information from this. Just from running something in a sandbox. You can also
1493590	1498670	find about a bunch of them online. But full disclaimer, don't use like things that you're
1498670	1504730	using for work and then upload them to some website. Um, unless where you work for is cool
1504730	1510350	with that, then by all means. Um, and then here we see our IP address. Although, it does
1510350	1515730	look like after six years that IP address has finally died. Um, the last time I did this a
1515730	1519510	couple months ago, it wasn't dead. It was, everything was still completely live. And I was
1519510	1523150	amazed by that because this is a six year old piece of malware. Proving that this stuff
1523150	1530250	never really goes out of style. Like, it still exists and functions and runs. Um, it'll also
1530250	1534630	give us any of the network connections, anything that we saw. Again, if your box isn't
1534630	1540350	completely clean though, you will add in some extra things that could hurt. We can look at
1540350	1548070	some static analysis of that file. So we can look at any compile time or PDB path. Any
1548070	1554670	imports for DLLs, which we saw some of those when we went through strings. Any artifacts
1554670	1558630	that were extracted during that time frame from that file. In this case, there were no
1558630	1564530	other ones. Behavioral analysis. This shows us that process tree. The file itself goes
1564530	1573290	to SVC host. Any network analysis that we have. So we can look at general host connections.
1573450	1577010	You can also pivot to MOLOC. Good shout out to MOLOC, even though I'm not going to cover
1577010	1580290	that because Verizon Media, the company that I work for, makes it and open sources it. So
1580290	1585410	it's a good shout out. Um, but you can pivot right to MOLOC for full packet capture. It'll
1585410	1589310	tell you about any files that potentially dropped. In this case, the dropped file was the file
1589310	1595450	we looked at. Um, process memory. It'll pull as well. So any potential URLs that exist in
1595450	1601650	process memory. Again, all of these might not be related to that file. Um, because this is
1601650	1609120	not quite as clean as I would have liked it when I ran this sample. So you get a kind of a
1609120	1612420	good idea of what you can look at from this perspective. And there's a lot of other tools
1612420	1617220	too. Say you're not a Linux guy, you're a Windows guy. If I hop back into here, which is
1617220	1635910	horribly, horribly infected, and I copy my file back in, there's a tool called, not that one, PE
1635910	1641570	Studio. That's it. So PE Studio essentially does a lot of this from a straight RE
1641570	1646570	perspective. So you can just drag and drop a file for analysis. It'll kick into analysis
1646570	1654180	with said file. Um, it will connect to virus total and look for that hash and give you any
1654180	1657260	indicators. If this thing did connect to virus total, it would light up like a Christmas
1657260	1662960	tree. I think it's like 46 out of 64. Um, it'll give you any potential indicators based by
1662960	1668220	severity. So installation of hooks, blacklisted libraries, different section names being
1668220	1673000	blacklisted. Again, we see some of the same things that we saw from each investigation
1673000	1677440	method and maybe a little bit more as we go through each one of these processes. Um, when
1677440	1681640	you get into that, it'll tell you certain sections, um, string analysis and the strings
1681640	1686120	that it found that were weird. So the string analysis that we did via command line, this
1686120	1692240	does, and it'll call out the things that are blacklisted. So, there's our DLL calls. Very,
1692240	1697960	very convenient tool, also free. Um, but has to be run on Windows, which means you have to
1697960	1701880	drop it from Windows, so make sure it's on a box that you don't mind completely screwing
1701880	1709540	over. So, that's about the course of the demo. So let's kind of loop back in and talk a little
1709540	1718900	bit about this. So, as a security person, all of us blue team-ish, what can we do with the
1718900	1724960	information that we got? So we have a file. We know the hash. We have endpoint detection
1724960	1729380	software, we can block that hash. We can look for that hash across our network. We have
1729380	1733200	call-outs in multiple areas. So we have the initial call-out from the document that
1733200	1737740	downloads the file. We can use that to see if anybody else potentially downloaded the file.
1738240	1745240	We can also use the actual call-out with the semantics cert, the IP call-out, to see if
1745240	1749620	anything went wrong or if anybody is infected with that file. Just because it tried to
1749620	1753400	download doesn't mean it's infected. Something could have stopped that. So we have a whole
1753400	1758260	host of information that we can use in our environment, especially if this came in as an
1758260	1762740	email, it probably went to more than one user. So we can take a whole host of all the
1762740	1767040	information that we pulled and get an idea of what this looks like across the scope of our
1767040	1774960	whole network. Which is super useful in any situation. So, I like to leave this kind of
1774960	1779040	stuff in case anybody wants to take pictures of this kind of stuff. So we have different
1779040	1783680	commands that were run, um, the very specific commands. I'll give everybody a minute on that
1783680	1796620	one. Lot of phones up. Good. Good. I, I keep them up because then we have the picture slide
1796620	1801920	which is links to all different kinds of tools. Virus total is an amazing tool for seeing
1801920	1806980	what AV vendors know about different stuff. URL void and IP void, great for IP and URL
1806980	1813040	reputation. Um, malware.com is a very similar to cuckoo online sandbox that you can upload
1813040	1818300	stuff to. Then there's a bunch of different tips. Um, reverse engineering tips, a lot from
1818300	1823220	Lenny Zeltzer who's fantastic at this. There's great sans courses on the topic and I
1823220	1827460	personally love the malware analyst cookbook and practical reverse engineering. If this is
1827460	1832000	something that you want to get into, these are some of my recommendations. The next
1832000	1838480	recommendation page however is a little bit more dangerous. Links to live malware. And I, I
1838480	1845280	say disclaimer right now, use those at your own risk. Um, I suggest having a separate box.
1845480	1851000	This box is literally the user name is guest and the host name is like malware. There's no
1851000	1855840	identifiable information to me on this box whatsoever. I've never logged into a personal
1855840	1860180	account. I've never done any of that. But again, paranoid. Maybe you don't need to do quite
1860180	1866360	that, but that's my thing. But there you have some links to live malware. End of speech.
1866360	1879560	However, I do have stuff for the three best questions. If anybody has any. So why don't I use
1879560	1884280	process hacker instead of sys internals? Probably just stuck in my ways and I don't do it
1884280	1897450	every day anymore. So easier to use procmon to capture the log and then look through the
1897450	1902250	processes afterward. And I agree, it's more time consuming and harder to show like this
1902250	1922500	though. So, VM aware malware, what method would I use to test that? Right? If it won't run on a
1922500	1928020	virtual machine. Um, so I not only have this box, I have a couple other hard boxes that I can
1928020	1934900	use to test this stuff on. Um, and just a base image, like a base windows image wipe. Um, a lot
1934900	1938400	of stuff will run in virtual machine and it's much easier to teach this because I have both
1938400	1943380	tools in the same place. But I have another laptop specifically with wipeable images that I
1943380	1952440	can use for anything that's VM aware. What's that? For the image wiping? It's some
1952440	1968240	enterprise tool. So, how often do I see something new is the question. And admittedly I don't do
1968240	1975180	this every day anymore. But I will say that when I did IR it was in waves. So, you would see
1975180	1980540	essentially the same thing a lot for a little while and then something new a lot for a little
1980540	1985640	while and then something new a lot for a little while. Um, crypto miners when I was rolling out
1985640	1991020	of IR and into management were the big thing. And just personal opinion, if somebody is going
1991020	1995360	to hit you with that, like that's, it couldn't be better than that. Like there's not a lot of
1995360	2000360	damage there. But it's waves. But eventually, I just talked to one of my IR buddies who was
2000360	2004540	here the other day and he said, uh, 10 years he's seen basically the same thing over and over
2004540	2021560	again. It doesn't change that much. So, when it comes to malware that's reaching out to CNC,
2021560	2027340	what do you use to spoof the connections? Typically, I don't. Um, I log into a VPN and I let
2027340	2031740	it make connections. I think you get a much more full picture of what happens when you let
2031740	2051150	communication happen. What's that? Why attach it to an email instead of Google docs? Oh, so why
2051150	2055430	not, from an attack perspective, not upload the PDF to Google docs instead of attaching it to
2055430	2060210	an email? And that happens a lot more now. But it was just a setup scenario to start the
2060210	2093800	conversation. Oh, why didn't I just upload the PDF? I don't know. Go ahead. I have and I actually
2093800	2099400	have a sample of it sitting on this box, too. Um, Emotet V4, actually, I believe. I worked a
2099400	2106060	big case with that. Um, you find certain things. So, like, polymorphic malware, for anybody not
2106060	2110600	familiar, is malware that can change enough to change its hash to make it harder to detect,
2110600	2115920	essentially. Um, and a couple other attributes. So, Emotet V4 is a module-based piece of
2115920	2119340	malware that can call out and download different things and it's constantly changing itself on
2119340	2124920	the system. So, in one of the cases that I used for that, I found common identifiers of the
2124920	2133560	type, which specifically in this case, it was unsigned binaries under or between 60 and 74
2133560	2140060	kilobytes. And I tracked it down that way and got probably 150 different hashes until we could
2140060	2164550	get Navy Vendor to do stuff. You come here, you get a gift. Yeah. So, did you say static
2164550	2177310	analysis to intent? Significantly more difficult, um, from that base analysis to go into intent.
2177310	2182250	Um, you're starting to get into real serious reverse engineering to get down into the code of
2182250	2188270	exactly what it does outside of what you see from a dynamic perspective. Um, however, I have
2188270	2192870	found that in many cases, and this is just me, like, I'm a horrible reverse engineer, I'm not
2192870	2197030	going to lie. Because when I did IR, no company wanted to pay for that. They just wanted to
2197030	2210250	know how to find it, how to get rid of it, and make sure it was gone. So, I just run a base
2210250	2216170	VM, but I'm also sitting on a Linux box and I'm only messing with executables in this case. So,
2216170	2232600	I don't do any specific VM isolation for this. What do I use to find different variances other
2232600	2237040	than registry keys of the same malware? That's really interesting. And a really good
2237040	2243000	question. I actually have to think about that. Also, come up here. You get a thing. Um, I
2243000	2248160	mean, registry keys not being the only method of persistence in general either. So, any
2248160	2252420	general auto runs that potentially exist, or any other normal common persistence
2252420	2273490	mechanisms, but man, you're really stumping me with that question. So, the risk of letting
2273490	2278290	network connections happen and what kind of setup I have in a lab and or VPN to accept that
2278290	2284190	risk. And I will start that with a story of the one time I forgot to turn on my VPN and
2284190	2288490	executed something that was terrifying and I thought I was screwed. Like, I thought I was
2288490	2293150	going to get owned after I executed this thing because I completely forgot to turn it on. I was
2293150	2301230	terrified for at least a week or two. I never made that mistake again, though. So, and all the
2301230	2305110	fake DNS and stuff is really good, too, but it doesn't necessarily give you the full
2305110	2309510	picture. So, I used private internet access for a long time and I was pretty happy with it. I
2309510	2314290	switched over to Nord recently and I'm pretty happy with that, too. Um, depending on what I
2314290	2319730	look at, I usually run it on host system, not on VM, so that my host system's coming from that
2319730	2324570	location. I have seen a little bit of malware that's like location specific, so if you VPN,
2324570	2330270	it's not necessarily going to execute anyway. But again, few and far between. Um, I've been
2330270	2334230	pretty happy with standard out of the box VPN service. I haven't had problems in the five or
2334230	2346180	so years that I did this regularly. Uh, I, I don't mind sharing the slides. I have no problem
2346180	2357040	with that. So, is there anywhere that I can share the slides? Perfect. It'll be on
2357040	2374590	blueteamvillage.org. Oh, another one. Go ahead. So, without getting into any of the ones that I
2374590	2379430	can't talk about, um, one of the most interesting ones I've ever seen from a commodity
2379430	2385950	perspective was that Emotet v4 sample. Because the initial payload was not malicious at all.
2386150	2393130	And then it would call out and download modules, including SMB spreaders, um, different
2393130	2397650	ransomware and like banking Trojan stuff. It could install other malware and it changed like
2397650	2402790	every five minutes. So, trying to get a handle and I watched it shut down a company in two
2402790	2408510	hours. Like completely shut down a company in two hours. So, trying to get a handle on what
2408510	2415070	that was to clean it up when it kept changing was one of the most fun and stressful weekends
2415070	2420470	of my life. It was also one of, on my birthday weekend, which was wonderful because I was
2420470	2429470	supposed to be on vacation. Anything else? If not, thank you very much for your time,
2429470	2429870	everybody.
