Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can a virus exist in an image?

I have recently watched this video of a Finnish internet security expert. Somewhere around eleventh minute, he talks about a virus which is hidden in an image and executes when the image is about to be displayed.

I am wondering how do they technically do such a thing, I mean how come the virus is executed, when the picture should be displayed and how come the picture is not compromised in some way. I thought the computer first looks at the extension, then opens it with appropriate program and lets the program work itself (and I don't expect regular image viewer to be able to run a virus within itself). Obviously it doesn't work like that, but no one I asked could help me out with this.

So does anyone know how do they do this, the principle? Thank you very much.

like image 744
JoeSlotsky Avatar asked Mar 12 '12 22:03

JoeSlotsky


People also ask

Can COVID-19 be detected by CT scan?

Along with laboratory testing, chest CT scans may be helpful to diagnose COVID-19 in individuals with a high clinical suspicion of infection.

Where did COVID-19 origin?

The first known infections from SARS‑CoV‑2 were discovered in Wuhan, China.[17] The original source of viral transmission to humans remains unclear, as does whether the virus became pathogenic before or after the spillover event.[19][75][9] Because many of the early infectees were workers at the Huanan Seafood Market,[76][77] it has been suggested that the virus might have originated from the market.[9][78] However, other research indicates that visitors may have introduced the virus to the market, which then facilitated rapid expansion of the infections.

Can COVID-19 spread through water while swimming?

Fact: Water or swimming does not transmit the COVID-19 virusThe COVID-19 virus does not transmit through water while swimming. However, the virus spreads between people when someone has close contact with an infected person. WHAT YOU CAN DO: Avoid crowds and maintain at least a 1-metre distance from others, even when you are swimming or at swimming areas. Wear a mask when you’re not in the water and you can’t stay distant. Clean your hands frequently, cover a cough or sneeze with a tissue or bent elbow, and stay home if you’re unwell.

How long does the virus that causes COVID-19 last on surfaces?

Recent research evaluated the survival of the COVID-19 virus on different surfaces and reported that the virus can remain viable for up to 72 hours on plastic and stainless steel, up to four hours on copper, and up to 24 hours on cardboard.


1 Answers

You're correct that your OS will pick a program and ask it to open the image. The OS will not ask the program to execute the image — that would be nonsense.

However, images are complex formats and often contain meta data (like the date and time when the picture was taken) and other parts that are not directly shown — you can hide stuff in there without affecting the image on the screen. So there might be hostile data lurking inside the image file.

Furthermore, program can have bugs, in particular buffer overflows. Briefly, a virus can exploit this by putting too large data into the meta data sections — larger than the program that decodes the image expects. The internal buffers overflow and with enough skill, a virus writer is able to put executable code into the right place in memory so that the program that decodes the image will end up executing the code. That way an innocent and "dead" file like an image can host an exploit.

like image 115
Martin Geisler Avatar answered Oct 06 '22 00:10

Martin Geisler