The U.S. military has a fraught history with food. During the Civil War, soldiers munched on tooth-cracking hardtack and salt pork. By World War II, it was SPAM and M&Ms. During the Cold War, the military introduced the world to survival crackers, a.k.a. Doomsday Biscuits.

But there’s always been one problem with most of the items on the menu: Few tasted very good. Hardtack regularly contained worms. Soldiers liked to call SPAM “ham that failed the physical.” The Chicago Tribune once claimed that survival crackers were “better as weapons.”

The challenge facing battlefield rations—called “Meal, Ready-to-Eat,” or MREs—has always been multifaceted. The Seattle Times explains it nicely: "To qualify for MRE duty, a food item has to be able to survive years of storage in a dank ship’s hold or a sun-baked shipping container, withstand Arctic freezes and tropical monsoons, stave off assaults by insects, and remain intact through a parachute airdrop or a free fall from 100 feet.” Taste, as a result, has been woefully neglected.

In 2002, researchers at the U.S. Army Soldier Systems Center in Natick, Massachusetts took the first tangible steps toward fixing that by concocting the world’s first “Super Sandwich.” Resembling a hot pocket, the prototype—which contained fillings like pepperoni and chicken—could last up to two or three years in temperatures of 78 degrees without spoiling or getting soggy. (At 100 degrees, its shelf life dropped to six months.)

For the food scientists working on the problem, the enemy in the battle to make the Super Sandwich was water—specifically, water activity. Put simply, water activity is a measurement of how easily moisture migrates from one food product to another. The higher a food item's water activity, the more likely it’ll give away moisture. The lower the water activity, the more likely it’ll absorb water.

Water activity is a huge hurdle for foods that contain multiple components. Take Raisin Bran, for example: Raisins are moist and have a relatively high water activity. The flakes, on the other hand, are crunchy and have a low water activity. Under normal circumstances, these two components will trade moisture, with the raisins turning hard and the flakes soggy.

The same problem faced the Super Sandwich. “The water activity of the different sandwich components needs to complement each other,” then-project officer Michelle Richardson told New Scientist in 2002. “If the water activity of the meat is too high you might get soggy bread.”

The trick to stopping the problem is to introduce a humectant, a type of substance that reduces a food item's water activity without reducing the actual water content [PDF]. In the case of Raisin Bran, food scientists solved this problem by dusting the raisins in a fine coat of sugar [PDF]. For the Super Sandwich, military scientists introduced both sugar and salt as humectants that successfully curbed creeping moisture and prevented bacterial growth. To further combat spoilage, they placed packets of iron fillings inside the packaging, which helped absorb unwanted oxygen.

Today, the Super Sandwiches—part of the military’s “First Strike” rations—reportedly come in four flavors: Bacon Cheddar, Pepperoni, Italian, and Honey BBQ Beef. According to the BBC, when Richardson first ate a three-year-old sample, it was declared a ringing success.

Well, relatively speaking. She described the taste as … “OK.”