MAIDUGURI, Nigeria — A wheelbarrow saved his life.

Sprawled across it, Babagana felt every bump, moaning in pain from four bullet wounds. Covered in his blood, his pregnant wife helped roll him across the Nigerian countryside to a hospital.

Somehow, Babagana survived the makeshift ambulance ride. More than 80 men from his village had been shot to death, he said, all of them forced to strip to the waist and lie face down. The gunmen then burned their small farming village before speeding away.

The attack fit the pattern of rampages by Boko Haram, the terrorist group that has killed poor people in this region for years. But Babagana and multiple witnesses to the attack in June, as well as another one days before in a neighboring village, say the radicals were not to blame this time.

Instead, they say, the massacres were carried out by the Nigerian military.

“They told us they were here to help us,” said a resident, Falmata, 20, adding that soldiers in uniform shouted for villagers to point out the Boko Haram members among them. When none were identified, the killings began, she and other witnesses said.