It’s not often you find yourself rooting for the weaselly masked character picking dog meat out of its teeth. But in the case of the endangered black-footed ferret, conservation scientists have rallied behind the tiny predator—thought to be extinct twice over the past century—by attempting to unleash a fleet of M&M-shooting drones over 1,200 acres of its grassland habitat in Montana.

Yes, you read that right. That magnificent, nightmarish plan is actually the best shot the 300 remainingwild ferrets have at surviving. The flea-borne sylvatic plague has wiped out most of the ferret’s favorite snack—prairie dogs—and when the dogs die, so do the ferrets. So the US Fish and Wildlife Service wants to use drones to sprinkle peanut butter-flavored plague vaccines over the prairie dog’s habitat.

The plan has to get through a public comment period and a few other assessments before it’s a reality. If it gets approved, the agency wants to start testing the method in UL Bend National Wildlife Refuge in eastern Montana, where they’ve been trying to reestablish a ferret population for more than two decades.

“It’s a good year if it takes more than two hands to count them all,” says USFW biologist Randy Matchett. “As of a month ago, there were seven ferrets on the site and many, many thousands of prairie dogs.” It takes 100 acres of prairie dogs to support a female ferret and her litter for a year. On a 1,200-acre lot like UL Bend, 12 ferret families could flourish—once the USFW gets rid of the darn plague, that is.

It hasn’t been for lack of trying. For over a decade, wildlife managers have blasted prairie dog burrows with pesticides to kill infected fleas. But fleas develop resistance to the spray after a couple of years. And spraying pesticides is labor-intensive and time-consuming, not to mention sketchy for the other insects and animals exposed to it.

That’s why US Geological Survey epizootiologist Tonie Rocke and a team of scientists at the University of Wisconsin concocted the world’s first prairie dog vaccine back in the early 2000s. You wish you got these vaccines as a kid: They’re delivered orally, via delicious, peanut butter-smothered bait. (“It’s organic,” adds Rocke.) And while they don't have the hard coating of an M&M, they're roughly the same size and shape, with the texture of a chewy energy bar. Prairie dogs are big fans, eating up to 90 percent of the goodies in field tests.

But test sites are small, and if wildlife managers want to make a real dent in the plague, they’ll have to make thousands of baits for hundreds of acres. That’s tough when you’re rolling them by hand onto cookie sheets, like Rocke and her team were doing. So a couple months ago, Matchett found a guy in Lithuania selling carp bait-making machines for about $2,000. “My wife calls it ‘that damn gum-ball machine,’” he says.

Mass-producing an effective vaccine is just one part of the challenge; distribution is a whole other animal. “We have to drop one bait every 30 feet,” says Matchett. “If we don’t spread them out uniformly, one big, fat prairie dog could eat them all.” So far, ecologists have placed baits by hand—but Matchett’s team has to dole out 350,000 doses between now and August.

Enter the drone. With his (yet-to-be-built) design, Matchett says a single drone could dispense three baits at a time. A GPS-controlled trigger would launch a mini catapult every 30 feet. With an automatic reloader and a payload of 5,000 doses, a drone might be able to treat 400 acres in an hour—about 50 times faster than a human can dole out baits.

UL Bend is a great test zone for the tech: It sprawls over remote sage-grasslands, far from any other aircraft. And so far, the public hasn’t seemed too concerned about the drone idea. The National Park Service has even softened its drone ban in the name of conservation (they recently allowed USGS to use drones to monitor and map coastal hazards off Cape Cod.)

The major challenge for Matchett and his team will be developing the bait-shooting technology. And while it’s still in the noodling phase, Matchett “fully intends” to have a proof of concept ready for August, regardless of which way the decision sways. "I’ve been at this 20 years," he says. "I’m used to banging my head against a wall." Until then, drones raining delicious peanut butter treats will have to live in your dreams.