The students were part of a larger group of young men who were studying to become rural teachers at a college in the village of Ayotzinapa, in the Pacific state of Guerrero.

They had arrived in Iguala on Sept. 26, 2014, to commandeer buses to travel to Mexico City a few days later. But as the five buses left the city, municipal police officers attacked them and three students were killed. The police also attacked a bus carrying teenage soccer players, killing three more people, apparently mistaking their bus for one of the students’ buses.

During a chaotic night, students traveling on two buses disappeared, hauled off by the police and, officials have said, handed over to the local drug gang, Guerreros Unidos.

The government’s account of what happened next rests on a series of confessions from suspected drug hit men who said they had killed the students and burned their bodies on a giant pyre in a remote garbage dump. The next day, they scooped the ashes into plastic bags and threw them into the nearby San Juan River.

Only one student’s remains have been identified from the charred bones found at the riverbank.

But the inspector general’s report describes how six suspects, picked up in different locations in one day, spontaneously confessed with identical wording that they were members of Guerreros Unidos, and admitted to having killed the students and burning the remains.

The subsequent arrests, based only on those statements, were arbitrary and illegal, the review said. Under the Mexican Constitution, an illegal arrest nullifies any evidence obtained as a result.

There were other problems. Dates were muddled, records missing. An investigating prosecutor signed documents in two different places on the same day.