start	end	text
0	5740	We have a new speaker today, so please give him a big round of applause.
6280	10520	The guy's name is called Ben Bolland.
10520	14080	He's from England, across the pond.
14360	20540	The talk we're giving today is called, Man in the Malware, Intercepting Adversarial Communications.
21280	22920	So, it's his first time.
22920	24220	Make him feel welcome.
24480	25660	And thanks for coming today, guys.
25660	26380	All right?
27560	29000	There you go.
31280	33040	Thank you, thank you, thank you.
35240	36360	And welcome.
36720	40220	As he mentioned there, yeah, this is my first DEF CON talk.
40220	42240	This is actually the second time I've been in the States.
42240	43620	The first was last week.
43700	44700	I'm loving it.
44700	47260	It's been an incredible event so far.
47440	52380	And before I get started, I just want to say a massive thank you to everybody who's chosen to come to this talk.
52380	56180	I know you've got super busy days, so I appreciate that.
57380	59580	So yeah, without further ado, let's begin.
59580	60880	Let's jump in.
61500	62860	So, quick agenda.
62860	65080	I'm going to start off with an obligatory, who am I?
65080	67600	I'm going to talk about myself, what I do, where I'm from.
67680	72060	And then we're going to make sure we're all have a similar level of understanding.
72060	77080	We've covered the baseline knowledge surrounding info-stealers, malware, command and control.
77360	83660	And we're going to look about different ways malware can achieve command and control and can exfiltrate data.
83660	85960	And we're going to look at Telegram as an example.
85960	90180	And we're going to look at the OPSEC issues this may cause.
90480	104480	And then finally, we're going to finish off with a case study where we intercept some communications from a threat actor and there are some major, major OPSEC failures which lead to some awesome intelligence wins for us.
104780	106260	So yeah, who am I?
106260	107100	I'm Ben.
107100	109300	I go by the online handle PolygonBen.
109300	112540	I'm extremely fortunate to work at Huntress.
112540	113640	I'm an analyst there.
113640	115220	Um, in the UK team.
115580	118480	Um, and I just want to take a chance to, to thank Huntress.
118620	121140	Um, I wouldn't be here if it wasn't for them.
121200	122780	Um, so thanks a lot.
122780	124780	Um, and I love threat hunting.
124780	125840	I love malware analysis.
125840	127500	Um, I'm a big blue teamer.
127660	129980	Um, I've got a blog, a YouTube channel.
129980	134260	I got into security by doing CTFs when I was, um, a bit younger.
134260	135560	But enough about me.
135560	137440	Um, let's get to the interesting part .
137440	139280	Um, so what's ahead, right?
139280	141740	We're going to be looking at real malware, real info-stealers.
141740	143600	I'm going to be doing some live malware analysis.
144060	149640	Um, and we're going to look at this malware and figure, um, some mistakes that the threat actor made.
149640	152220	And we're going to exploit these mistakes for intelligence wins.
152560	160400	And as a result of these intelligence wins, we're going to be able to look at a whole cyber crime operation from the cyber criminal's own hacking machine.
160760	161760	Um, so yeah.
161980	162880	Let's get on with it.
162880	163800	Let's take a step back.
163800	165200	That sounds super exciting.
165320	167980	Um, super interesting, but we need to cover the foundations.
168440	174220	Um, so info-stealers, command and control, threat intelligence, OPSEC or operational security, malware analysis.
174220	176640	We're going to go through the basics to begin with.
176940	178380	Um, so info-stealers.
178380	180760	Info-stealers is just a type of malware.
180760	188080	They're, um, a specific type of malware which will exfiltrate data and steal, uh, credentials and sensitive documents.
188080	192480	And it will send it back to an attacker owned location or an attacker controlled location.
192480	194540	This could be an FTP server.
194580	197220	Um, they could be exfiltrating data over DNS.
197220	202380	There are multiple ways, um, uh, information can be exfiltrated.
202720	207240	Um, and in terms of the malware we're seeing most in the wild, it's info-stealers.
207240	212240	Um, we're particularly seeing a lot of info-stealers getting deployed via click fix and fake capture.
212240	225920	This is the, uh, sort of new malware delivery technique which came around, uh, September last year and it's sort of blown up in prevalence where you just sort of trick a user to pasting a command into run box or Windows PowerShell or something like that.
225920	230720	It's really simple but it's effective and we're seeing a lot of info-stealers get deployed as a result of this.
231180	235460	Um, so command and control, um, all malware will communicate for the most part.
235460	242240	It has to either receive commands from some threat actor and server or it needs to exfiltrate data or send data back to some server.
242240	244540	So malware will typically communicate.
244540	254460	There are some exceptions where there is no malware communi- there's no communication, there's no network traffic but for the most part, malware will communicate and there are multiple ways they can do this.
254540	266040	Um, if we look at command and control, this just command and control describes the techniques by which malware or threat actors can communicate with a victim machine and a threat actor in location.
266520	269200	Um, so how does this communication occur ?
269200	277800	Um, traditionally we saw, uh, malware CTU over regular network protocols like HTTP, HTTPS, DNS, SMTP.
277800	284940	This sort of blends in with regular traffic and you're not seeing let's say a network connection to port 31337 which is super dodgy.
284940	289400	Um, but even this traditional CTU, it's not perfect and it has its issues.
289880	294760	Um, so for example if you did want to do this, a threat actor or cyber criminal would have to buy their own domain.
294760	297560	They would have to set up some hosting in the cloud.
297640	300580	They would configure their CTU server, set up their firewall.
300740	304240	Um, and this takes a lot of effort and there's, um, issues with this.
304240	319620	You have to obviously buy the infrastructure and host that and that may cause OPSEC issues depending on how you're paying for the infrastructure and it's going to get burnt eventually and you're going to have to rebuild this and it's sort of a cycle for these cyber criminals of rebuilding new infrastructure after old ones get burnt,
319620	320660	um, and so on and so forth.
320660	322160	And this is hassle.
322280	332200	Um, so we're seeing a shift in threat actors moving from this sort of traditional method for command and control where you buy your infrastructure and you set it up to using trusted infrastructure.
332200	341940	Um, so living off the land, um, so adversaries use free trusted platforms for command and control and there is a massive variation of platforms you could use.
341940	344380	So, um, we can see up there Telegram.
344380	347740	Um, you can even see CloudFlare, CounterStrike 1.6.
347740	350120	I believe you can proxy C2 communications.
350140	366220	Um, there are loads of different trusted platforms which you can proxy your C2 communications through and instead of, let's say when the malware executes, it, uh, makes a network connection to a newly registered suspicious dot X, Y, Z domain, it would make a network connection to a trusted,
366220	375140	uh, Gmail API domain or Telegram API domain and this is less likely to, uh, raise flags for the network defenders.
375420	392220	Um, so if you are a cyber criminal, you're a threat actor and you want a cheap way to host your command and control which is high availability , it's free, it's quick, it's serverless, it's encrypted , um, it's trusted and it's relatively anonymous.
392220	393520	What would you choose?
393980	398120	Um, for a lot of cyber criminals, the answer to this question is Telegram.
398260	409840	And instead of let's say buying a domain and setting it up, they will create a Telegram account and create a Telegram bot and use the Telegram API to send data and receive commands and so on and so forth.
409840	419240	Um, and there is a massive variation of malware, everything from rats, um, developed by nation states to info stealers, um, which use Telegram as a way to communicate.
419240	422000	Um, however, it comes with its issues.
422000	432480	Um, so in order to actually, um, use C2 over Telegram and to proxy your sort of command and control communications, you need a, a bot.
432480	436600	This is like an automated account and anyone can easily create a bot.
436600	448840	You just need to go on Telegram on your phone or on your computer and message the person bot father and you can just use the commands new bot and it asks for your username and it asks for, um, and then it will give you a bot token.
448840	460920	This is your credential, your API key, your authentication material and you can see there, um, after it generates your token, it gives the message keep your token secure and store it safely.
460920	463700	So this is really important, really important.
463700	469980	If somebody else gets the hand of my bot token, they can control my account basically.
470100	482560	And, um, for malware to communicate with the Telegram API, um, it has to use, it has to be embedded with some sort of API keys and Telegram authentication material for a particular bot account.
483080	484980	Um, so how does this work?
484980	491940	Um, the malware developer will hard code within the malware, sometimes encrypted, sometimes obfuscated the Telegram API key.
491940	509660	And then when the malware is run and it's executed, um, instead of making a network connection to, um, uh, suspicious IP address or a domain name, it will send a DNS request to api.telegram.org and then starts sending HTTP requests to, um, the Telegram API.
509680	515440	Uh, but what API methods would be useful for a threat actor or a cyber criminal who is developing malware?
515460	519580	And particularly if you're interested in developing info-stealers which exfiltrate data.
519840	522820	So first of all, we can use the send message API.
522820	523860	This is really simple.
523860	530940	It allows us to send mess- uh, send a message as a bot to a group chat or a channel or a private DM.
531180	533260	And all it requires is a chat ID.
533260	537840	This is a unique identifier of a chat and it requires some text to send.
538020	541700	Um, so once you've got the chat ID, you can send whatever message.
541700	559960	If you were a malware developer, um, maybe once you've harvested the credentials during the malware's execution and you want to send this to a location, where you would use the send message API, um, and provide the chat ID being the, the cyber criminal's Telegram chat and the text being what you want to exfiltrate,
559960	561480	maybe the stolen credentials.
561740	565020	Um, another important, uh, API method is get me.
565020	568760	This will allow us to validate whether a Telegram bot token is valid.
568760	574100	If it, the, the token still exists, um, and it can also tell us a bit more about the privileges.
574120	578880	Like, can we add this particular bot to a group or can we, um, add it to a chat?
578880	579840	Can we message it?
579840	586760	Um, and sometimes it has extra capabilities like webhooks, um, which we can be made aware of from this get me function.
586760	590820	This can help us enumerate the capabilities of a particular bot account .
591360	594680	Um, oh, that's not working.
594820	596740	Let me, there we go.
596740	600420	And finally, we've got the get updates, uh, method.
600420	604480	This will allow us to, uh, figure out changes which has happened to a bot .
604480	608420	So let's say you've got a bot account and you add it to a new group or a new chat.
608420	613520	When you call the get updates method, it will tell us the ID of the chat it is a member of.
613520	618840	And if there's been any new messages received, um, if there's been any new members , um, so on and so forth.
618840	627720	So we can use this, um, get updates method to enumerate what chats, what groups this particular bot is a part of.
627720	633740	And if this is a cyber criminal's bot, we can see who else this bot is part of, what other chats are it in.
633920	635460	And this is a really useful one.
635460	639140	Um, and we use this mainly just to find those chat IDs.
639140	646240	So for example, um, in the screenshot there, we can see this bot is a member of two particular distinct, uh, group chats.
646600	650840	Um, and what we can then do is forward messages from one group to another.
651280	654380	And we can use the forward message, uh, method to do this.
654520	660460	And we need to provide the two chat IDs, the source chat and the destination chat.
660460	664100	And a chat like a, an ID for a message, a message ID.
664100	672300	Um, we don't know, we don't always know what the message IDs are so we can sort of enumerate through all possible integers and forward all messages across.
673120	679160	Um, so for actor OPSEC failures, um, I talked about OPSEC earlier.
679160	684620	Um, we're going to talk about a big OPSEC failure in a minute but I just want to, um, go over this to begin with.
684620	688640	Um, so operational security, we hear it, uh, in the security community quite a lot.
688640	697720	Maybe we're talking about an individual who is over sharing at a pub or maybe they've got too much on their social media or maybe they use the same password across all their different accounts.
697720	701120	All of these things would constitute poor operational security.
701440	710480	Um, and we often forget, like any individual in this room, cyber criminals and threat actors also have some level of operational security.
710580	717920	Um, and I'm going to go over a few operational security failures that threat actors can make and we see them make quite often.
717920	729140	Um, so for example, like, um, your IT infrastructure or your own network, if you have weak or default credentials or it's vulnerable, um, this would all constitute poor OPSEC.
729320	734560	Um, having open directories, um, containing malware and your toolkit exposed.
734560	742640	Um, often times when we're analyzing malware or we're looking at some execution chain, um, additional payloads will be pulled down from a web server.
742700	743240	Okay?
743240	751900	And when the threat actor sets up this web server, they may accidentally share the whole entire directory rather than the one payload they were, uh, aiming to share.
751900	758580	And this means when we visit this open directory, we can see the whole entire file system and, uh, move through it.
758580	768840	If this was, let's say, on a Linux machine on the home folder, uh, the threat actor may expose their bash history, uh, file which would, uh, leak all the commands the cyber criminal has run.
769220	774160	And then I've highlighted their embedded malware with important API keys and credentials.
774360	776900	Um, I don't really need to explain why this is an OPSEC failure.
776900	782500	If we've got our hands on cyber criminals, um, passwords and credentials, they're doing something wrong.
782880	798900	Um, reusing online handles across campaigns in real life, we see this quite a lot in law enforcement wins, um, whether it's an individual on a cyber crime forum who uses, um, the same online handle that they use, let's say, on Twitter or on some normal clear web forum from years ago.
798900	804400	Um, we sometimes see this used in, um, arrests and takedowns and so on and so forth.
804400	806480	Um, command and control not encrypted.
806480	819340	So, um, if you've got your command and control communications, um, not encrypted as it's being sent through the network, network defenders may be able to look at this and, uh, find interesting information which is being sent or received.
819340	821620	Um, and they could potentially use this in detections.
821660	824540	Um, I'm not going to go through and explain all of these OPSEC failures.
824540	826520	Um, a lot of them are pretty obvious.
826520	828180	Um, I just wanted to highlight these.
828280	832720	Um, so, uh, let me, there we go.
832800	833500	Awesome.
833500	836840	So, yeah, we can exploit these failures for intelligence wins, right?
836840	841940	It's, it's fun to do this and I'm not saying go out there and start pwning threat actor infrastructure, that's illegal.
841980	857060	Um, but what we can do in some cases may fall under sort of OSINT, whether it's like open directories that accidentally leaving their front doors open and sharing all their malware and their interesting files or whether it's them using the same domains and infrastructure across multiple attacks.
857100	859200	Um, these will constitute OPSEC failures.
859240	863480	Um, and we can all use these in the SOC, in the blue team, uh, to help our detections.
863480	868120	Um, I gave an example here which is a, a really, really effective one we use at Huntress.
868260	872560	Um, and that's the threat actors rarely change the host names of their machines.
872560	879220	So, um, let's say they've got a, a, they've spun up a, a VPS somewhere and this is where they're initiating their attacks from.
879220	892000	They may use the same image and share that across, um, uh, multiple intrusions and they use the same sort of, uh, VM image and we see the same host name popping up in the logs across multiple intrusions.
892000	895760	Um, so we know this is a super, super high fidelity indicator of compromise.
895760	901800	If we see this weird desktop unique username, I know for certain it's linked to XYZ threat actor.
901800	903400	Um, and this is an OPSEC failure.
903400	906520	If they changed up every time, we wouldn't be able to use this for detection.
906680	911960	Um, so we're going to actually go on to the technical part now where we're going to be doing some live malware analysis.
911960	914160	Everything I'm going to show is real.
914160	919680	Um, it was found in the wild and I am going to show fake, uh, I'm going to show InfoStealer log data.
919680	924540	Um, however all screenshots, um, and all images shown are of the cyber criminal's own desktop.
924540	926220	No victim data is shown.
926540	932000	Um, so we've got some malware analysis and like a lot of malware, it was delivered via phishing.
933680	937300	And here we've got a DHL phishing campaign.
937300	941780	We can see it's sent from no reply DHL at wind HYM dot site.
941800	944320	Uh, remember this domain, it will come up later.
944620	947540	And we can see everyone in this room would obviously be able to see this is phishing.
947540	954080	There's this weird dot seven, uh, seven Z attachment, um, relating to some sort of shipment arrival.
954080	958940	So, um, as a malware analysis, we'll download this attachment, we'll rip it apart and we'll see what's going on.
959200	960840	So we can do exactly that.
960840	965520	Um, we can unzip it and we can see, um, this doesn't contain, um, some DHL document.
965520	967740	This actually contains a JavaScript file.
968140	971520	And I've trimmed it down a little bit and only included the important parts.
971520	979300	But what we can see is going on is when this JavaScript file is double clicked, uh, a secondary PowerShell script is then downloaded.
979860	984760	Um, and this is written to disk in the temp directory named D D D D D dot PS1.
984760	985840	So this is obviously dodgy.
985840	987260	Um, but what do we do now?
987260	990460	We download this secondary PowerShell script and now we analyze this one.
990660	996900	This one looks a lot smaller, um, but it actually contains a massive chunk of base 64 encoded text.
997520	999620	Uh, so what we can do, we can regex that out.
999620	1006060	We can basically just cut open this PowerShell script, regex out the base 64 encoded blob and then decode that.
1006260	1016660	What this PowerShell script is actually doing is it's just writing an executable X dot EXE to disk and the contents of the executable is the base 64 decoded blob.
1016700	1021560	Um, so we can manually decode that and run the file command on Linux and say, yeah, look, this is a binary.
1021560	1024680	This is an executable, which we were expecting to see.
1024800	1028140	Um, and we can also see this is a dot net binary, a dot net executable.
1028140	1031600	So, um, this is important and it's useful for me.
1031600	1045240	I'm not a reverse engineer, but when we come across dot net binaries in the world, we can easily decompile them, uh, maybe using DN spy and get basically the full plain text source code, um , compared to let's say if I was analyzing a C compiled binary ,
1045240	1047880	I may have to open up in Ghidra and I don't know how to do that.
1048040	1050180	Um, so I can look at the source code.
1050180	1057960	I can do some analysis of this X dot AXC file, which was written to disk and we can see, yeah, look, this was, um, C sharp compiled dot net.
1057960	1061540	And we can use the capital to enumerate the capabilities of the binary.
1061540	1065420	And we can see some signs that maybe some process injection is going on.
1065420	1075080	We see areas of memory being allocated, um, uh, permissions on memory change, all this stuff sort of hints towards process injection.
1075080	1080440	Um, but we can see the full source code and we can analyze this and we can validate that this is actually the case.
1080440	1087700	So this X dot AXC binary, when it is run, it will actually spawn a new process, reg asm dot AXC.
1087700	1089780	And reg asm dot AXC is legitimate.
1089780	1092260	This is signed, um, this is native to Windows.
1092260	1094060	This doesn't raise concerns.
1094080	1097840	But X dot AXC doesn't just spawn reg asm dot AXC.
1097840	1099040	It suspends it.
1099040	1100760	And then it carves its memory out.
1100760	1108140	And then it dynamically decrypts and injects a final payload into the memory space of reg asm dot AXC.
1108140	1112820	And then it resumes the process and runs the malicious pay, payload.
1112820	1120240	Um, so we can dynamically sort of extract this final payload which is the stage 4 and this is what is injected into reg asm.
1120240	1124220	And we can run strings on this and instantly we get sort of big wins down there.
1124220	1127540	Keylogger dot AXC, username value, password value.
1127540	1133280	And then we see some file paths to common chromium, um, browser locations.
1133320	1139160	Um, so we can look into this a bit deeper and we can actually identify this is a sample of malware called Nova.
1139160	1140600	Nova Info Stealer.
1140600	1145100	And this was initially found in December, uh, 2024 by Anyron.
1145180	1150900	Um, it was a fork of Snake Keylogger, um, which is also dot net based, um, Info Stealer and Keylogger.
1150900	1163160	Um, Nova has the capability to, uh, take all the stolen information, credentials, files, everything gets gathered and it can either exfiltrate over Telegram, FTP or SMTP.
1163320	1167260	Um, and you can control this in the configuration when you build Nova Info Stealer.
1167660	1174360	Um, and as I mentioned, we can view that plain text source code of the dot net binaries, um, using DN spy.
1174360	1178600	And, um, we can see at the bottom there that there's a Telegram bot token.
1178600	1181380	And, um, this wasn't encrypted, it wasn't obfuscated.
1181380	1186540	Obviously there was multiple layers of obfuscation and encryption that we unraveled during the analysis.
1186540	1193460	But during this final, uh, payload we can see, um, down there the bot token and chat ID.
1193460	1196340	So this is the cyber criminals bot token.
1196340	1199040	And the chat where the data will be sent to.
1199060	1200120	So now what?
1200120	1202740	We've got the token, we've got the chat ID.
1202960	1206600	If you recall, there was that forward message API.
1207320	1216480	And, um, we can use some scripts to help us, um, basically intercept and copy the whole entire Telegram chat.
1216480	1221920	Um, compromise their, their C2, uh , channel and take a copy of it.
1222180	1228740	And we can do that using scripts, um, generate, developed by any run or just using the API functions in curl.
1228740	1230120	That's a hassle, that's fiddly.
1230120	1231920	Um, any run of develop some awesome scripts.
1231920	1235000	So we can use the prepare bot scripts to get the chat ID.
1235000	1242400	What this basically does in the back end is we add the fret actors bot, which we've, uh, got the bot token for.
1242400	1251840	We add it to our own Telegram chat and then we get that get updates method and that will give us the ID of our Telegram chat with the fret actors bot.
1251840	1263780	We already have the ID of the fret actors Telegram chat from the malware analysis and then we can start forwarding messages from the Telegram's chat, from the fret actors chat to my chat.
1263880	1271460	And then as a result of this, over time, as it iterates through all the messages, we'll get a complete copy of the whole C2 channel.
1272140	1277020	Um, and let me, we can, this is the prepare bot script.
1277020	1282140	So we will run the prepare bot script, provide the bot token and it will tell us the username of the bot.
1282380	1286400	Um, and then we add that username to a group.
1286920	1292400	Um, and then once we've done that, we've now, we'll get given the chat ID of our chat.
1292400	1295100	And here we can see we're running the forward messages script.
1295100	1300160	We provide the bot token and we provide the source chat and the destination chat.
1300180	1305140	And then it will start through iterating through the message IDs and forwarding all the communications.
1305460	1308660	And, um, this is what it looks like here.
1308720	1311680	Um, if you scroll down through the chat, you can see screenshots.
1311860	1314480	Um, there's metadata surrounding the IP addresses.
1314480	1315860	There's key log files.
1316040	1319360	Um, and there's thousands and thousands of messages.
1319420	1322920	And when I was doing this, I was expecting this to be victim data.
1322920	1326480	We can see there loads of key log files and there's so much to go through.
1326480	1333160	Um, so we've got hundreds of stolen screenshots and key log files from a threat actor's telegram.
1333160	1334360	What do we do now?
1334440	1341720	Um, so I downloaded all of the screenshots and just sort of sorted by time and looked what is the first screenshot which was uploaded.
1342120	1345960	Um, and this is the first screenshot.
1346280	1352280	And if we look at this, we can see it looks like they're writing some source code.
1352280	1354180	Maybe there's some PHP going on there.
1354180	1356140	But we can see this isn't legitimate source code.
1356140	1361180	This looks like, um, the back end development of maybe a phishing web page.
1361200	1363640	So this raises my concern straight away.
1363640	1368920	And I was thinking, huh, maybe another cyber criminal has accidentally got infected by malware.
1369000	1371560	So, uh, this infosealer somehow.
1371560	1375640	Um, but I go through the screenshots and this is the second screenshot I see.
1376300	1379620	This is the DHL email which we saw earlier.
1379620	1387400	And we can see it's got the same subject and we can see information relating to the malware we analyzed within the telegrams chat.
1387760	1402460	So I'm beginning to think to myself now that I've just compromised this threat actors telegram chat and I'm looking through all of what I was expecting to see victim data and I can only see so far screenshots from the cyber criminal's own desktop.
1402580	1420120	Um, but we can go through again and we can see, look, there's that email using the Nova campaign and eventually we can see on Namecheap the cyber criminal buying the domain windhm.site which was then used in the future to deliver emails that I analyzed and then copied the chat and got this.
1420120	1421400	It's, it's kind of weird.
1421440	1422740	Um, but what has happened here?
1422740	1428780	Why are we seeing screenshots of the threat actors computer when we were expecting to see victim data?
1428800	1437500	Well, imagine you are a cyber criminal and you, you're doing these mouse spam campaigns and you're buying these domains, you're setting up this infrastructure and a lot of effort goes into this.
1437540	1442100	And maybe you're sending mass emails to 30,000 people at a time.
1442180	1444380	Um, you want to make sure your payload works right.
1444380	1452180	You want to make sure after you've sent this 30,000 people that if they run it, that images and key logs and credentials are going to start being sent to the telegram chat.
1452180	1455520	So we obviously just tested it locally but not on like a test machine.
1455620	1460720	He tested it on his own production hacking machine and just compromised his whole operation.
1460720	1462660	But, uh, we'll carry on going through.
1462660	1470820	Um, I also had a look at the key log files and I want to, I saw that one domains, like if I pivot on that domain we saw within the key log files, what else can I find?
1470820	1477840	And then I found an IP address which linked that main and I can also find an email address, Aaron Diskubrick at Hotmail.com.
1477840	1483100	I'm hoping that's not his real name because I didn't want to dox him but if it is, hey ho.
1483100	1491940	Um, but, um, and we can go and see more screenshots and this is him logging into his Cloudflare dashboard panel.
1491940	1498400	And we can see that wind HYM domain or, I'm not sure if we can, but what we can see is additional domains.
1498400	1503880	So these are other domains the cyber criminals bought, set up for other cyber crime operations.
1503880	1509520	So it's not just this DHL one, we've now identified all this additional infrastructure and I can go pivot on this.
1509520	1511560	I can start looking at biocon.com.
1511560	1516360	I can see this first domain was used for DHL mouse spam, similar to what we saw originally.
1516360	1521140	The second one looks to be for credential harvesting and so on and so forth.
1521140	1524560	We can see this cyber criminal is trying all different variations of malware.
1524560	1531100	He's not just sticking to Info Stealers and getting those logs and selling those, he's also doing phishing campaigns, credential harvesting campaigns.
1531120	1535800	And it's interesting to see this from the Fratactazome, uh, computer.
1536340	1538000	As I mentioned, I work in a SOC.
1538000	1539860	Day in, day out, I deal with cyber attacks.
1540260	1547240	Um, and when I deal with these, we deal from it from the perspective of our telemetry, our detections.
1547360	1556400	It's extremely rare we see the adversarial activity from the own, like, initiating workstation, the Fratactazome machine.
1556400	1557680	So it's pretty interesting.
1557680	1570500	Um, but we can go through and look at the more domains he owns and link these to other campaigns and start building up a picture of this individual, um, and the activity he gets up to, um, in the cyber crime world.
1570500	1577560	But so on and so forth, um, we can go through and there's, there's hundreds and hundreds and haven't included all, but we can start getting his root credentials for SSH.
1577560	1580020	So he's just bought a VPS and set it up.
1580040	1583920	He's probably going to use this in a few hours to start sending out mass phishing emails.
1583920	1585400	But look, we've got his root credentials.
1585400	1586200	We can log in.
1586200	1589100	Oh, and by the way, uh, I was looking at this two weeks late.
1589200	1593220	So, um, when I copied the telegram chat, I was looking back retrospectively.
1593640	1596660	Um, I'm not looking at this in real time.
1597020	1606620	Um, but so forth, we can go through and see like they're setting up fast panel, um, and we can see like even more credentials being set up and then they're not using a password manager.
1606620	1607240	Come on.
1607240	1612760	Um, they've got notepad TXT up with all their plain text credentials right there for me to read.
1612820	1615500	Um, including the URLs for some when I need it.
1615500	1616900	Um, so super useful.
1617040	1619040	Um, and they're configuring DNS.
1619040	1619820	They're setting it up.
1619820	1621000	They've got issues.
1621000	1622680	Here's quite an interesting one.
1622680	1626140	Um, they're using, it's called mail dime or gamma mail dime.
1626140	1628360	I can't remember and I can't see it on the screen.
1628540	1631860	Um, but this is their software they use to send out mass phishing emails.
1631860	1636780	And I think we can see, um, something like 35,000 emails being sent out at a time .
1636780	1641220	And we can look at that particular attachment which is like a PO update.
1641220	1643460	This is a different campaign to the one I analyzed.
1643460	1648320	Um, but what we can see here is emails being sent out at mass.
1648440	1651620	Um, and this one I believe is for the biocon domain we saw.
1651860	1655480	Um, and then we can go again and go through and through.
1655480	1657120	And I don't want to bore you with all of this.
1657140	1664260	Um, but we seriously got so much information which we could go to fast panel, name cheap, um, cloud flare, so on and so forth and report this.
1664280	1665940	And they probably did nothing about it.
1665960	1672900	Um, so we can see even more credentials and we can see even more, um, sort of VPSs that this threat actor is using.
1672900	1678480	We can see more email addresses, uh, more usernames, um, and so on and so forth.
1678860	1682020	Here we see they've got SMTP issues which is lovely to see.
1682020	1683580	They're doing some troubleshooting.
1683680	1685600	They're checking if DNS is broken again.
1686380	1694500	Um, so it's, it, I, I find it interesting to see them troubleshooting and, and doing all this stuff from the, the, uh, the cyber criminals own, own screen.
1694520	1696700	Um, but yeah, so on and so forth.
1696700	1697920	We can see DocuSign.
1697920	1702220	This is, I can imagine, uh, credential harvesting AITM sort of campaigns.
1702220	1703540	We see this a lot in the wild.
1703540	1706620	Um, but it's interesting to see the threat actor trying to set it up.
1706620	1708460	And we often see him testing this locally.
1708540	1715120	So like sending it to test Gmail accounts to see if, um, they get flagged and also flagged up by spam, um, or not.
1715120	1721020	And it's interesting to see all which, everything which goes into just like a basic boring sort of phishing campaign.
1721160	1727900	Um, but like I could go on and on and on with all the credentials and everything we see.
1727940	1739420	Um, it looked like he was doing some social engineering and some maybe, uh, emailing just people who've replied to his phishing and trying carrying them on and getting information and credit card information.
1739420	1741600	Um, so it's interesting to see.
1741620	1744440	Um, but yeah, there's a lot there.
1744440	1746100	Let's take a, let's take a recap .
1746100	1749200	So we started off with one email file, one email file.
1749600	1754920	And from that we saw the email file had an attachment and it was a JavaScript file.
1754960	1761420	And when that JavaScript file was run, it will download a PowerShell script and the PowerShell script write an executable to disk.
1761420	1772420	And when the executable, uh, was written to disk and run, it will spawn a new legitimate process, regasm.exe, inject the info sealer code into regasm.exe and then run it.
1772480	1777540	And then from that point on, uh, data will be exfiltrated over telegram.
1777540	1779160	And we did that analysis.
1779160	1780660	We were able to find that bot token.
1780660	1787840	And from that one bot token, we were able to copy the whole chat and basically reveal a whole entire cybercrime operation.
1788220	1797120	Um, from one OPSEC mistake, um, which then led on to discover more OPSEC mistakes like storing all your passwords in notepad.
1797420	1799220	Um, so yeah.
1799320	1801280	Um, how could you do this at home, right?
1801280	1806420	If you wanted to go home and look for malware which is communicating over telegram, um, there are multiple ways to do this.
1806420	1813220	If you've got a VirusTotal enterprise account which has the capability to maybe use the retro hunt or live hunt features, you could use a rule like this.
1813220	1814120	Um, here's an example.
1814120	1821580	We're just looking for, um, PowerShell files which have been tagged as malicious by VirusTotal which just communicating with API telegram dot org.
1821980	1841380	Um, alternatively, you could do some Google dorking and go look for the domain or the string API dot telegram dot org and Google that alongside Joe's sandbox or any run or common other sandboxes, um, or even VirusTotal and you may be able to just by Googling find samples of malware which have,
1841380	1848960	um, these API keys embedded within them and you can then use these to, uh, intercept communications.
1849280	1856020	Um, so this is the example, um, this is actually how I identified the sample this talk is based on.
1856180	1864600	And I was looking for PowerShell scripts and we can see on VirusTotal we didn't need to do all that fancy malware analysis and rip it all apart.
1864600	1868860	On VirusTotal it gives us that chat ID and that bot token straight away.
1868860	1869900	So you didn't need to do that.
1869900	1870980	It's really, really easy.
1870980	1889160	If I wanted to, I could have gone on VirusTotal, found this sample, gone on the relations tab and the, VirusTotal when it's running its sandbox and it collects its telemetry, it realizes there is a HTTP request made to telegram dot API dot org and then within that is the bot token chat ID which we can use.
1889160	1891060	Um, so that's how I found this sample.
1891060	1897780	And then once I found the sample I worked backwards and then I realized actually this came from a JavaScript file which came from an email.
1898020	1902300	And then after the PowerShell, PowerShell file it, rip X dot AXC.
1902300	1908080	So that's what I found initially and then after that I built up the whole picture and then intercepted the communications.
1908700	1913920	So, yeah, to finish up, to conclude, for actors make mistakes, let's exploit them.
1914280	1917120	Um, being really careful with that first point there.
1917160	1920960	Um, you have to do, yeah, be careful.
1920960	1928980	Um, so yeah, intelligence gains like these, uh, from OPSEC failures, uh, the massive, right, we found so much about, about this, this cyber criminal.
1928980	1932100	We found out all the infrastructure they used to host out their attacks.
1932460	1934840	Um, so, yeah.
1934840	1939300	And it's not just this, um, and I did want to note this isn't a novel technique.
1939300	1941400	This malware wasn't found by me.
1941400	1943000	This isn't sophisticated or advanced.
1943000	1944160	This is pretty simple stuff.
1944160	1946320	This is just two API methods.
1946320	1954640	Forwarding messages from one telegram to a telegram chat to another and then using the get updates, uh, um, API request just to find the chat ID.
1954640	1959220	This is simple stuff but in this particular case study there was a really interesting finding.
1959240	1964520	Um, and this stuff is done in the wild, in the CTI community, in the security industry already.
1964560	1966600	Um, so it's nothing novel.
1966700	1973880	Um, but the intelligence wins from this massive and we can use these in our detection enduring teams or for hunting teams.
1973980	1976340	Um, so I believe that's it from me.
1976340	1977680	I hope everyone enjoyed this.
1977680	1979860	Um, I'm open up for questions I believe now.
1979860	1981980	So, um, thank you.
