A study of bacterial defense systems could lead to the development of new antibiotics, say US researchers.
The study could also help industries that rely on bacteria, for instance to clean up pollution or manufacture chemicals or medical products.
A team of scientists led by researchers at the University of Georgia has investigated how bugs ward off viruses that kill half the bacteria on Earth every two days.
The system involves two components - an RNA genetic molecule that targets attacking viruses and proteins that neutralize them.
"You can look at one as a police dog that tracks down and latches on to an invader, and the other as a police officer that follows along and 'silences' the offender," said Dr Rebecca Terns.
"It functions like our own immune system, constantly watching for and neutralizing intruders."
Knowing how the mechanism worked opened up opportunities to exploit it, said the researchers.
Professor Michael Terns said: "Understanding how bacteria defend themselves gives us important information that can be used to weaken bacteria that are harmful and strengthen bacteria that are helpful," said.
"We also hope to exploit this knowledge to develop new tools to speed research on micro-organisms."
The findings are reported in the journal Cell.