A former defense minister for El Salvador, who was implicated in the torture and deaths of thousands of Salvadorans during the country’s civil war more than 25 years ago, lost his appeal this week against an order of deportation from the United States. He had been living in the U.S. since 1989.

The Board of Immigration Appeals, the U.S.’s highest immigration panel, oversaw the appeals case and upheld a deportation order for Carlos Eugenio Vides Casanova, 81, on Wednesday. The case marks a significant precedent for high-ranking foreign officers to be removed from the U.S. on account of human rights abuses.

Vides Casanova, who was also formerly head of El Salvador’s National Guard, had been trying to overturn a 2012 deportation order from a Florida immigration judge. Although he legally immigrated to Florida and 1989 and was granted permanent residency, the U.S. passed a law in 2004 that allowed the government to deport U.S. residents if they had committed human rights atrocities prior to arriving in the country.

The Florida deportation order was based on that law. The judge ruled that Vides Casanova could be removed from the U.S. based on his role in six human-rights abuse cases, one of which included the abduction, rape and shootings of four American churchwomen by National Guard soldiers in 1980, which occurred under his watch as head of the guard. The deportation order also pointed to extrajudicial killings and torture committed by the guard under Vides Casanova’s command.

Vides Casanova’s lawyer had argued that the former defense minister was upholding U.S. policy when he oversaw the killings, noting that the U.S. backed El Salvador’s government during the civil war.

Before the deportation proceedings began, Vides Casanova was cleared of wrongdoing in a lawsuit over the 1980 churchwomen killings. But in a separate lawsuit in 2006, he and Jose Guillermo Garcia, another former defense minister for El Salvador, were ordered to pay $54 million in damages to three Salvadoran plaintiffs who were tortured during the civil war.

Vides Casanova can still take his case to a federal court. But if he eventually returns to El Salvador, it’s not clear where his fate lies. El Salvador’s Supreme Court is reviewing a case that could potentially overturn Vides Casanova’s prosecutorial immunity, which was granted in 1993. It’s also asked the attorney general’s office to reopen an investigation into a massacre perpetrated by military officers in 1981, which could open a pathway for legal action against Vides Casanova in his home country.