Want the best of VICE News straight to your inbox? Sign up here.

Jimmy Morales, a former comedian who rose to Guatemala’s presidency in 2016 on lewd jokes and an anti-corruption platform, now seeks to leave office with what may be his biggest joke of all: a deeply unpopular migration deal with the U.S. that critics say is virtually impossible to implement.

Morales’ government signed a so-called “safe third country” agreement with President Trump on Friday that would require Guatemala to take in tens of thousands of migrants from neighboring Honduras and El Salvador in exchange for avoiding damaging tariffs and taxes on remittances.

Immigration officials and politicians in Guatemala say the country has no capacity to process all their asylum claims — it has just four asylum officers and hasn’t resolved a case in nearly two years — much less guarantee their protection. But Morales may be going for something else entirely: a powerful ally in Trump when he leaves office in January and loses presidential immunity, which has so far shielded him from charges of illegal campaign financing.

“The president has lost legitimacy. We don’t think he is negotiating this in the name of Guatemala. We think he is negotiating impunity for him and his family,” Guatemalan Congresswoman Sandra Durán told VICE News.

Morales' wife is currently under investigation on suspicion of cashing illicit checks made out to her and her husband. Prosecutors, meanwhile, are asking judges to sentence his brother and his son to 11 and seven years, respectively, for alleged fraud and money laundering.

Trump can’t stop Guatemalan prosecutors from bringing charges against Morales. But he could pressure Morales’ successor to not press charges or even harbor Morales and his family in the U.S.

Adriana Beltrán, an expert on Guatemalan politics at the Washington Office on Latin America, said she is among those who believe that Morales agreed to the migration deal out of personal interest.

“We don’t think he is negotiating this in the name of Guatemala. We think he is negotiating impunity for him and his family.”

“Over the last two years, Morales and his allies have sought to undermine the anti-corruption efforts in Guatemala and reverse all the advances that had been made in the fight against impunity. They have repeatedly tried to curry favor with Trump and protect themselves from being held accountable. In return, the administration has remained silent as Morales undermines the rule of law,” she said.

Despite running on an anti-corruption platform, Morales has been dogged by allegations of fraud and graft for the majority of his time in office. In response, he’s waged a war on some of the country’s most well-known anti-corruption institutions. Most notably, he’s shuttered a United Nations-backed anti-corruption commission, which had revealed dozens of criminal networks and brought down Guatemala’s former president. The commission unsuccessfully sought to lift Morales’ presidential immunity in order to investigate charges that he accepted nearly $1 million in illegal campaign funds. Soon after, Morales, who says he is innocent, expelled the commission’s investigators from the country.

Now, critics in Guatemala say this deal is Morales’ last-ditch attempt to avoid prison time for himself and his family.

The agreement says migrants traveling through Guatemala must apply for asylum there first before seeking protection in the U.S. Morales pushed through the accord even though Guatemala’s highest court barred him from doing so without congressional approval. Morales’ rationale appears to be that the deal was not a formal treaty but instead an “agreement of cooperation” that would last two years.

“What we have is a perverse situation without clarity. And that’s the problem,” said Durán, the congresswoman. She said legislators would be convening on Tuesday to review the agreement and decide whether it requires congressional approval.

Even if the agreement is approved, it remains unclear how Guatemala will implement it. The country has just four employees who analyze the asylum claims, said Eduard Woltke, a migrant advocate at the country’s Office of Human Rights. Guatemala received around 270 asylum claims total in 2018, Woltke said. Not a single one was resolved last year or this year, he added.

“We don’t understand what the authorities were thinking. Guatemala isn’t prepared to attend to thousands of people in this situation,” Woltke said, adding that he wondered whether that was the point. “I think the authorities even hope that the people who come will give up their asylum claim so they don’t have to help them.”

Morales has characterized the deal in do or die terms, noting that Trump threatened tariffs on Guatemalan products, and taxes on the roughly $9.3 billion in remittances Guatemalans in the U.S. send home every year. Morales said the agreement would help the country avoid “drastic sanctions.” The U.S. will also increase the number of temporary work visas given to Guatemalans.

“We don’t understand what the authorities were thinking. Guatemala isn’t prepared to attend to thousands of people in this situation”

While the deal has faced widespread criticism, its supporters argue Guatemala had to save relations with the U.S. at any cost. The U.S. is Guatemala’s number one trading partner and remittances from Guatemalans living in the U.S. make up roughly 12 percent of the country’s GDP.

“If Guatemala is a path for illegal immigrants to invade the United States we have the obligation to put a stop to it,” said Congressman Fernando Linares Beltranena. He said he expected Guatemala to set up “refugee camps” with the help of the U.S. to house migrants while their claims are processed, and that those camps could be turned into prisons when the migration flows stopped.

Still, the idea of receiving tens of thousands of asylum seekers seems nothing short of crazy to many in Guatemala. Unrelenting poverty and rampant gang violence have pushed more than 235,000 Guatemalans to flee to the U.S. just this year alone. On Saturday, hundreds of protestors rallied in front of the presidential palace in Guatemala City to protest the deal, many carrying signs calling for Guatemala to maintain its sovereignty.

Samuel Pérez, newly elected to Guatemala’s Congress, said the conditions in Guatemala aren’t adequate for its own citizens, but less migrants seeking protection.

“Migration is a systemic problem,” he said. “You cure it by addressing systemic problems that have to do with unemployment, poverty, inequality, and strong institutions. Jimmy Morales has done the complete opposite during his four years of presidency.”