MEXICO CITY — Mexican authorities are investigating reports that police opened fire on a group of migrants from El Salvador last week, killing a 19-year-old woman and wounding two men.

The confrontation in the Gulf Coast state of Veracruz on Friday comes as Mexico expands immigration enforcement at the behest of the United States, creating new checkpoints and deploying thousands of national guardsmen across the country. Human rights advocates have expressed concern that those actions could lead to violence against migrants.

Reports of the shooting have circulated in local media for days. On Tuesday, the attorney general of Veracruz held a news conference to relate the accounts of the survivors.

Attorney General Jorge Winckler Ortiz said 17 migrants bound for the United States were traveling in a white truck near a checkpoint in the town of Agua Dulce when they heard sirens.

The driver of the truck, who officials said was likely a smuggler, sped up. A police patrol car gave chase and eventually reached the truck, according to the account shared by Winckler Ortiz.

Then people wearing police uniforms “opened fire,” he said.

On Wednesday, Mexico’s secretary of public security said his ministry’s own investigation indicated that the migrants sped through a checkpoint and shot at Mexican officials.

“In this case, the first information indicates that not only did they not stop, but they fired and there were attacks against the personnel of the checkpoint,” Secretary Alfonso Durazo told reporters at a news conference.

He said the investigation is ongoing, but “we would not be surprised if we ended up identifying elements of organized crime or those participating in human trafficking.”

The accounts provided by Durazo and Winckler Ortiz were at odds. Durazo didn’t explain why police who fired in self-defense would have fled the scene after killing the migrant. And it would be unusual in Mexico for a truck full of migrants to attack security officials while passing a checkpoint.

Winckler Ortiz referred to people “wearing police uniforms” and driving “a patrol car.” He did not say they were necessarily police, but other officials in Veracruz said there was no reason to doubt that they were.

A municipal police unit arrived at the scene and found the 19-year-old dead in the passenger seat. Salvadoran authorities said the woman’s father and other close relatives were living in the United States.

Winckler Ortiz said the assailants fled the scene and appear to have taken the driver with them.

Winckler Ortiz’s account was based only on the testimony of the surviving migrants. But other officials in Veracruz, who were not authorized to speak to journalists, said other eyewitnesses have confirmed the migrants’ claims.

Messages seeking comment from state and federal police and the federal immigration agency were not returned.

Photos taken by local journalists of the truck show several bullet holes in the windshield. Two male migrants were found injured and taken to a nearby hospital, where they were later interviewed by authorities. Winckler Ortiz and others in the attorney general’s office said the investigation would continue in the coming weeks.

Mexican President Andrés Manuel López Obrador has said repeatedly that his government will enforce immigration laws while respecting human rights. His government agreed this month to increase enforcement to stop the historic flow of Central American migrants through Mexico to the United States in a deal to avoid tariffs.

“In many cases they are forced into exile by hunger or to save their lives; that is why they deserve all our respect,” he said last week. “We are going to respect the human rights of migrants.”

Mexico is deploying thousands of troops from its national guard to help stop the flow. But the former military and police officers who have been detailed to the new agency have yet to be trained in immigration enforcement.

Critics warn Mexico is responding to a humanitarian crisis with unnecessary — and potentially dangerous — force.

“The killing of a Salvadoran migrant woman by Mexican police is a tragic yet predictable consequence of Mexican security forces’ new role in immigration enforcement,” said Maureen Meyer, the director of the Mexico program at the Washington Office on Latin America. “Unless the Mexican government ensures adequate training for any security force involved in immigration enforcement and works to hold accountable agents accused of wrongdoing, human rights violations and abuses against migrants in Mexico will only worsen as more agents are deployed throughout the country.”

The Salvadoran Consulate in Veracruz said it had reached out to the woman’s family in the United States. Her father has returned to El Salvador, where her body is to be repatriated this week.