So, anyway, I was examining some new firmware uploads this weekend (yes, when you work in the anitmalware space, you are like Inspector Gadget ... always on duty), and my program detected some similarities to a certain POC (Proof of concept) rootkit from a few years ago. (I call it a POC because when you look at the code, it has comments in it, paraphrasing, "This is empty, but is where the payload would go")br>
As I said, it's a few years old now, but it is very unusual for my scanner to detect any similar code, so, naturally, I had to look deeper.
After researching it a bit, it seems likely that this new one, too, was a POC, from 2019, but the interesting things were ...
(1) No major antimalware product detects either of these (one scanner from Russia that I'd never heard of detected one of them, but that was all), and...
(2) When I tweaked my detectors (in this case, an ssdeep sig) a bit, I suddenly found multiple other detections in my collection, with 80% to as high as 97% code match.
These may well turn out to be simple, and innocent, false positives, but ... they must be investigated... we shall see.
And of course, one wonders how many other things like this are waiting to be discovered.
Sunday, October 17, 2021
Thursday, October 7, 2021
A couple of thoughts about the recent UEFI bootkit discoveries
So, anyway, you've probably noticed that two "new" UEFI bootkits were announced in the last couple of weeks. One is ESPector (so named by our friends at ESET), and the other is FinSpy.
ESPector has roots that go back to 2014-ish, but the main difference here is that they've found a way to bypass signature checking, and to gain persistence in the system partition... not quite in the firmware, but a separate partition on disk that is not easy to look at.
Whenever I see something like that, I think, "Wait ... if this gang has found a way to bypass signature checking, how do we know that this is the only version of the bootkit?" After all, they've had six or seven years to work on this.
The answer to this question, of course, is that we don't know. Not many people/products look at the system partition.
FinSpy is interesting from another angle.
FinSpy was originally developed by the Hacking Team, which was dox'd in 2016. Among the documents leaked was the source code to their VectorEdk UEFI rootkit (the product known as FinSpy). The Hacking Team's business model was to sell their product to law enforcement, and governmenrt bodies, ala NSO with Pegasus. This doxing effectively killed the Hack Team business, but it has now resurfaced, with a new, and improved, FinSpy, which was what the guys at Kaspersky found.
Now, that's all very well, but the thing that concerns me is that the source code to VectorEdk/FinSpy is still freely available for download on GitHub.
Does anyone really believe that this single company/group will be the only one to have developed new versions of this rootkit?
If anyone does believe that, I would like to sell you some ocean front property in Arizona. It's very cheap, and a bargain. ;)
Heads up, folks. Something evil, this way comes.
Please pay attention to your firmware.
ESPector has roots that go back to 2014-ish, but the main difference here is that they've found a way to bypass signature checking, and to gain persistence in the system partition... not quite in the firmware, but a separate partition on disk that is not easy to look at.
Whenever I see something like that, I think, "Wait ... if this gang has found a way to bypass signature checking, how do we know that this is the only version of the bootkit?" After all, they've had six or seven years to work on this.
The answer to this question, of course, is that we don't know. Not many people/products look at the system partition.
FinSpy is interesting from another angle.
FinSpy was originally developed by the Hacking Team, which was dox'd in 2016. Among the documents leaked was the source code to their VectorEdk UEFI rootkit (the product known as FinSpy). The Hacking Team's business model was to sell their product to law enforcement, and governmenrt bodies, ala NSO with Pegasus. This doxing effectively killed the Hack Team business, but it has now resurfaced, with a new, and improved, FinSpy, which was what the guys at Kaspersky found.
Now, that's all very well, but the thing that concerns me is that the source code to VectorEdk/FinSpy is still freely available for download on GitHub.
Does anyone really believe that this single company/group will be the only one to have developed new versions of this rootkit?
If anyone does believe that, I would like to sell you some ocean front property in Arizona. It's very cheap, and a bargain. ;)
Heads up, folks. Something evil, this way comes.
Please pay attention to your firmware.
Friday, July 2, 2021
Scary, funny, and then scary again
So, anyway, I recently noticed that a firmware update seemingly had support for RTSP (Real Time Streaming Protocol), and my initial thought was, "Why the hell would firmware want to be able to stream media?". Further investigation showed that the same module seemingly had Gopher (Yes, Gopher) support, and SMTP support, and RTMP (Real Time Messaging Protocol) as well as HTTP, and FTP.
I was starting to get a bit nervious about this, and then the funny bit happened. I noticed a reference to LibCurl.
Wait ... so this is using LibCurl?
That probably explains why this has exotic capabilities such as RTSP. These capabilities are there, but probably not being used.
But then it got scary again...
The LibCurl version seems to be 7.56.1.
That's kind of old, and there have been a lot of vulnerabilities patched since that version was released.
I hope I'm wrong about that version number, because if I'm not wrong, that's a pretty good attack surface.
Investigation continues. Stay tuned.
Firmware is fun.
I was starting to get a bit nervious about this, and then the funny bit happened. I noticed a reference to LibCurl.
Wait ... so this is using LibCurl?
That probably explains why this has exotic capabilities such as RTSP. These capabilities are there, but probably not being used.
But then it got scary again...
The LibCurl version seems to be 7.56.1.
That's kind of old, and there have been a lot of vulnerabilities patched since that version was released.
I hope I'm wrong about that version number, because if I'm not wrong, that's a pretty good attack surface.
Investigation continues. Stay tuned.
Firmware is fun.
Thursday, June 24, 2021
Far be it for me to say I told you so... but ...
So, anyway, our colleages at Eclypsium recently announced some bugs they found in Dell BiosConnect which could allow attackers to remotely implant code in firmware. You can read about it here.
Dell has apparently released firmware upgrades which fix the bugs, and it is not thought to be under active attack, so all should be well, but there are still two problems.
The first is that people tend to not be good at applying firmware updates. Unlike the monthly OS patches, there is rarely a mechanism for letting folks know they have a firmware patch to apply, and even if there is a patch, most people are not good at flashing firmware. As an example, we routinely still see Lenovo firmware that has the so-called "Lenovo rootkit" (which, btw, ain't that different from BiosConnect) from 2015 in it, and it should have been extinct since 2016.
The second problem is, who knows how many other problems like this exist? Another six, (at least) manufacturers have firmware with similar capabilties to BiosConnect, and no one knows who has similar problems. Maybe none. Maybe some. I guess time will tell.
Oh, and functionality keeps getting added. When I blogged about BiosConnect well over a year ago, one thing I noticed was that this particular firmware upgrade moved from 8 mb to 16 mb, and the number of programs in it grew from 320 to 575, and we now routinely see firmware (not just Dell) with nearly 1,000 executables. That's a lot of extra functionality, and therefore a lot of potential vulnerabilities.
As I recently wrote, you cannot protect your organization properly if you don't know what's in your firmware, especially the upgrades. We have recently done some "before and after" comparisons, that are highly instructive, and hopefully I'll get to disclose them here soon.
And, if you would like some help in checking your firmware, please feel free to reach us at labs at armor.ai.
So, far be it for me to say I told you so, but ... I told you so... This stuff is coming.
Dell has apparently released firmware upgrades which fix the bugs, and it is not thought to be under active attack, so all should be well, but there are still two problems.
The first is that people tend to not be good at applying firmware updates. Unlike the monthly OS patches, there is rarely a mechanism for letting folks know they have a firmware patch to apply, and even if there is a patch, most people are not good at flashing firmware. As an example, we routinely still see Lenovo firmware that has the so-called "Lenovo rootkit" (which, btw, ain't that different from BiosConnect) from 2015 in it, and it should have been extinct since 2016.
The second problem is, who knows how many other problems like this exist? Another six, (at least) manufacturers have firmware with similar capabilties to BiosConnect, and no one knows who has similar problems. Maybe none. Maybe some. I guess time will tell.
Oh, and functionality keeps getting added. When I blogged about BiosConnect well over a year ago, one thing I noticed was that this particular firmware upgrade moved from 8 mb to 16 mb, and the number of programs in it grew from 320 to 575, and we now routinely see firmware (not just Dell) with nearly 1,000 executables. That's a lot of extra functionality, and therefore a lot of potential vulnerabilities.
As I recently wrote, you cannot protect your organization properly if you don't know what's in your firmware, especially the upgrades. We have recently done some "before and after" comparisons, that are highly instructive, and hopefully I'll get to disclose them here soon.
And, if you would like some help in checking your firmware, please feel free to reach us at labs at armor.ai.
So, far be it for me to say I told you so, but ... I told you so... This stuff is coming.
Thursday, June 10, 2021
How do people know what’s in their firmware?
Here's a quick summary of where we stand wrt firmware security...
Nearly all computers built since 2007 contain UEFI (Unified Extensible Firmware Interface). UEFI contains between two hundred, and a thousand compiled C programs, in Windows format. This is a format well understood, by attackers, and defenders, alike. They are all cryptographically signed, but this signature is only checked at flash time. What this means is that if something can get write access to the firmware, it can change whatever it likes, including by virus-like infection, and probably nothing will detect it. UEFI is immensely powerful, and is an operating system in its own right. It has its own network stack, and can download over the public internet, via HTTP or FTP, and can write anything it likes to the disk. We have even found some that have email capability.
UEFI runs at ring-1, or ring-2, well below ring-0, and is like 64bit, real mode, DOS. (Think about the implications of that for a minute)
Firmware attacks have already happened, viz. LoJax, and ShadowHammer, that we know about, and we know that the TrickBot ransomware gang has been spotted looking for machines with Secure Boot turned off. There will be others, just waiting to be discovered.
If you think ransomware is a problem now, wait until some of them gain persistence in firmware.
Even if you are not concerned about ransomware, consider this. The SolarWinds attackers were obviously technically capable of firmware attacks. They were in networks well long enough, and were clearly cunning enough to cover their tracks.
Given the “high profile” nature of some of their victims, this could be like a hidden bomb, waiting to be detonated.
I think it was the Marines who came up with the expression Left Of Bang. The idea is that when the improvised explosive, or road-side bomb, goes off, that’s “Bang”. Getting Left Of Bang means that you realize that something is not right, and maybe an ambush is coming, and you do whatever you have to do to prevent, or avoid, the Bang.
So how do you get Left Of (this sort of) Bang?
Whether you are using our software, or someone else’s, you have to start dumping, and analyzing, your firmware.
Even if there is nothing overtly malicious in it, you simply have to know what capabilities are in it, or you cannot properly defend your organization.
And, the answer to the opening question of, "How do people know what's in their firmware?" is...
They don't. Nearly everyone is using the Hope Method.
The Hope Method is not a method.
Folks, it’s coming. Please try to get ahead of it.
Nearly all computers built since 2007 contain UEFI (Unified Extensible Firmware Interface). UEFI contains between two hundred, and a thousand compiled C programs, in Windows format. This is a format well understood, by attackers, and defenders, alike. They are all cryptographically signed, but this signature is only checked at flash time. What this means is that if something can get write access to the firmware, it can change whatever it likes, including by virus-like infection, and probably nothing will detect it. UEFI is immensely powerful, and is an operating system in its own right. It has its own network stack, and can download over the public internet, via HTTP or FTP, and can write anything it likes to the disk. We have even found some that have email capability.
UEFI runs at ring-1, or ring-2, well below ring-0, and is like 64bit, real mode, DOS. (Think about the implications of that for a minute)
Firmware attacks have already happened, viz. LoJax, and ShadowHammer, that we know about, and we know that the TrickBot ransomware gang has been spotted looking for machines with Secure Boot turned off. There will be others, just waiting to be discovered.
If you think ransomware is a problem now, wait until some of them gain persistence in firmware.
Even if you are not concerned about ransomware, consider this. The SolarWinds attackers were obviously technically capable of firmware attacks. They were in networks well long enough, and were clearly cunning enough to cover their tracks.
Given the “high profile” nature of some of their victims, this could be like a hidden bomb, waiting to be detonated.
I think it was the Marines who came up with the expression Left Of Bang. The idea is that when the improvised explosive, or road-side bomb, goes off, that’s “Bang”. Getting Left Of Bang means that you realize that something is not right, and maybe an ambush is coming, and you do whatever you have to do to prevent, or avoid, the Bang.
So how do you get Left Of (this sort of) Bang?
Whether you are using our software, or someone else’s, you have to start dumping, and analyzing, your firmware.
Even if there is nothing overtly malicious in it, you simply have to know what capabilities are in it, or you cannot properly defend your organization.
And, the answer to the opening question of, "How do people know what's in their firmware?" is...
They don't. Nearly everyone is using the Hope Method.
The Hope Method is not a method.
Folks, it’s coming. Please try to get ahead of it.
Tuesday, March 30, 2021
Goog blocked my search
So, anyway, today I was out, and waiting for a kid, and just for fun, I decided to google for "push cs pop ds", just to see what popped up.
(Older geeks will remember that back in the day, it all came down to push cs, pop ds. "Why" doesn't really matter any more, but it was important once.)
Google predictive text offered 'push vs pop ds', and just for fun and to see what it showed, I clicked that.
Much to my surprise, it blocked my search thusly...
"unusual traffic from your computer network"
Hmmm... I'm on my cellphone, on cellular data only.
I tried it a couple more times, with the same result.
Knowing that there are some iOS Zero days circulating, and out of an abundance of caution, I powered my phone off, and on, (It's hard for malware to obtain persistance past a reboot on iOS), and the problem went away.
I don't know if it was malware, or just a bug, but it reminded me that it's not a bad idea to power devices off and on periodically, just to remove malware that's in ram. It's by no means a perfect defense, but it doesn't hurt.
As I've said before, I reckon 2021 is saying "Hold my beer, and watch this!"
Folks, stay safe, and keep your guard up.
(Older geeks will remember that back in the day, it all came down to push cs, pop ds. "Why" doesn't really matter any more, but it was important once.)
Google predictive text offered 'push vs pop ds', and just for fun and to see what it showed, I clicked that.
Much to my surprise, it blocked my search thusly...
"unusual traffic from your computer network"
Hmmm... I'm on my cellphone, on cellular data only.
I tried it a couple more times, with the same result.
Knowing that there are some iOS Zero days circulating, and out of an abundance of caution, I powered my phone off, and on, (It's hard for malware to obtain persistance past a reboot on iOS), and the problem went away.
I don't know if it was malware, or just a bug, but it reminded me that it's not a bad idea to power devices off and on periodically, just to remove malware that's in ram. It's by no means a perfect defense, but it doesn't hurt.
As I've said before, I reckon 2021 is saying "Hold my beer, and watch this!"
Folks, stay safe, and keep your guard up.
Sunday, February 7, 2021
Software Supply Chain hmmms
So, anyway, I've been thinking a bit about the SolarWinds hack, and thinking how lucky we were that it was the only event of its kind, (Yes, my tongue is firmly in my cheek), and then a few days ago, I saw this article in the Register.
The headline is partly "What happens when a Chrome extension with 2m+ users changes hands, raises red flags,", but being a little cynical, I think a better question would be, "What happens when a Chrome extension with 2m+ users changes hands, and _doesn't_ raise red flags".
And then, a couple of days ago, I saw an excellent MalwareBytes blog about an Android app with 10m-ish users, that also changed hands, and is now regarded as malicious and has been removed from Google Play. As you can see from the blog, the app was pretty instantly obvious that it was being... uh ... a bit pushy.
I look at things like those two events, and think, "That's a pretty good way to get yourself on millions of devices pretty quickly."
And then I think, "I wonder how many more apps, or browser extensions, have quietly changed hands to someone of hostile intent, and _haven't_ been noticed?"
Yes, it costs the perp some money to get these things, but then they could be on tens of millions of devices, quietly harvesting uids, and pws, to all sorts of services.
Nation States actors would do this. RansomWare dudes would do this. Both adversaries are easily financially capable of this.
The potential RansomWare consequences are instantly clear, and potentially costly if you ignore them. The Nation State level implications are more subtle, but this is exactly how you could end up with more hacks like SolarWinds.
So the question then becomes, how do you handle it, and the short answer is, with great difficulty.
The slightly longer answer is, if you are a builder of products, you have to really think hard about your software supply chain, and maybe not trust everything, and then
(1) Consider what you would do if some open source components, on say, Github, are compromised
(2) Consider how you detect that some of your own source components werer modified, ala SolarWinds
(3) Given the potential for uids and pws to have been harvested by apps that have quietly "changed hands", you should assume that it's a matter of "when" and not "if", the Bad Guys get in your network, or in your supply chain somewhere.
I will try to find some less nebulous answers about what to do.
Oh, but don't get me started about Firmware Supply Chain.
Stay safe, folks. It's tricky out there.
The headline is partly "What happens when a Chrome extension with 2m+ users changes hands, raises red flags,", but being a little cynical, I think a better question would be, "What happens when a Chrome extension with 2m+ users changes hands, and _doesn't_ raise red flags".
And then, a couple of days ago, I saw an excellent MalwareBytes blog about an Android app with 10m-ish users, that also changed hands, and is now regarded as malicious and has been removed from Google Play. As you can see from the blog, the app was pretty instantly obvious that it was being... uh ... a bit pushy.
I look at things like those two events, and think, "That's a pretty good way to get yourself on millions of devices pretty quickly."
And then I think, "I wonder how many more apps, or browser extensions, have quietly changed hands to someone of hostile intent, and _haven't_ been noticed?"
Yes, it costs the perp some money to get these things, but then they could be on tens of millions of devices, quietly harvesting uids, and pws, to all sorts of services.
Nation States actors would do this. RansomWare dudes would do this. Both adversaries are easily financially capable of this.
The potential RansomWare consequences are instantly clear, and potentially costly if you ignore them. The Nation State level implications are more subtle, but this is exactly how you could end up with more hacks like SolarWinds.
So the question then becomes, how do you handle it, and the short answer is, with great difficulty.
The slightly longer answer is, if you are a builder of products, you have to really think hard about your software supply chain, and maybe not trust everything, and then
(1) Consider what you would do if some open source components, on say, Github, are compromised
(2) Consider how you detect that some of your own source components werer modified, ala SolarWinds
(3) Given the potential for uids and pws to have been harvested by apps that have quietly "changed hands", you should assume that it's a matter of "when" and not "if", the Bad Guys get in your network, or in your supply chain somewhere.
I will try to find some less nebulous answers about what to do.
Oh, but don't get me started about Firmware Supply Chain.
Stay safe, folks. It's tricky out there.
Tuesday, January 5, 2021
EMail to SMS. Good idea, right?
So, anyway, a couple of days ago, I got this text message.
The first odd thing was that it was a text message, that clearly came from an email address. (In this case, gmail)
The second odd thing was that it was sent to twenty people.
The third odd thing was that it simply referenced an ip address.
Looking at the "20 people", it showed this...
Twenty consecutive phone numbers. Nothing suspicious about that, right?
I visited the ip address with a neat tool called Silo, from my friends at Authentic8. Silo can hide your ip address, as well as your country of origin, and can also isolate your computer from web-borne malware. The site was a "dating/porn site", and, although it did not seem to throw anything malicious at me, the typical m.o. with this sort of site is that every few visits, it randomly will, so it's one of those places you don't want to ever visit on an unprotected computer.
This was the first time I've received a text from an email address, but a quick bit of googling shows that lots of providers offer such a service. I guess there must be some upside to it, but to me, it just seems like an easy way for the robo callers to send malicious things in bulk.
The moral of the story, in my opinion is that if you get a text or iMessage from an email address that you don't know, don't trust it and simply delete it.
Remember, www stands for World Wild War. Stay safe, folks.
The first odd thing was that it was a text message, that clearly came from an email address. (In this case, gmail)
The second odd thing was that it was sent to twenty people.
The third odd thing was that it simply referenced an ip address.
Looking at the "20 people", it showed this...
Twenty consecutive phone numbers. Nothing suspicious about that, right?
I visited the ip address with a neat tool called Silo, from my friends at Authentic8. Silo can hide your ip address, as well as your country of origin, and can also isolate your computer from web-borne malware. The site was a "dating/porn site", and, although it did not seem to throw anything malicious at me, the typical m.o. with this sort of site is that every few visits, it randomly will, so it's one of those places you don't want to ever visit on an unprotected computer.
This was the first time I've received a text from an email address, but a quick bit of googling shows that lots of providers offer such a service. I guess there must be some upside to it, but to me, it just seems like an easy way for the robo callers to send malicious things in bulk.
The moral of the story, in my opinion is that if you get a text or iMessage from an email address that you don't know, don't trust it and simply delete it.
Remember, www stands for World Wild War. Stay safe, folks.