WASHINGTON (AP) — The Trump administration on Monday moved to end asylum protections for most Central American migrants in a major escalation of the president’s battle to tamp down the number of people crossing the U.S.-Mexico border.

According to a new rule published in the Federal Register, asylum seekers who pass through another country first will be ineligible for asylum at the U.S. southern border. The rule, expected to go into effect on Tuesday, also applies to children who have crossed the border alone.

There are some exceptions: If someone has been trafficked, if the country the migrant passed through did not sign one of the major international treaties that govern how refugees are managed (though most Western countries have signed them) or if an asylum-seeker sought protection in a country but was denied, then a migrant could still apply for U.S. asylum.

But the move by President Donald Trump’s administration was meant to essentially end asylum protections as they now are on the southern border.

READ MORE: Who is affected by Trump’s new rule for claiming asylum

The policy is almost certain to face a legal challenge. U.S. law allows refugees to request asylum when they arrive at the U.S. regardless of how they did so, but there is an exception for those who have come through a country considered to be “safe.” But the Immigration and Nationality Act, which governs asylum law, is vague on how a country is determined “safe”; it says “pursuant to a bilateral or multilateral agreement.”

Right now, the U.S. has such an agreement, known as a “safe third country,” only with Canada. Under a recent agreement with Mexico, Central American countries were considering a regional compact on the issue, but nothing has been decided. Guatemalan officials were expected in Washington on Monday, but apparently a meeting between Trump and Guatemalan President Jimmy Morales was canceled amid a court challenge in Guatemala over whether the country could agree to a safe third with the U.S.

WATCH: Asylum-seeker tells House she came to U.S. seeking safety, but watched her daughter die

The new rule also will apply to the initial asylum screening, known as a “credible fear” interview, at which migrants must prove they have credible fears of returning to their home country. It applies to migrants who are arriving to the U.S., not those who are already in the country.

Trump administration officials say the changes are meant to close the gap between the initial asylum screening that most people pass and the final decision on asylum that most people do not win. But immigrant rights groups, religious leaders and humanitarian groups have said the Republican administration’s policies amount to a cruel and calloused effort to keep immigrants out of the country. Guatemala, Honduras and El Salvador are poor countries suffering from violence.

Along with the administration’s recent effort to send asylum seekers back over the border, Trump has tried to deny asylum to anyone crossing the border illegally and restrict who can claim asylum, and Attorney General William Barr recently tried to keep thousands of asylum seekers detained while their cases play out.

Nearly all of those efforts have been blocked by courts.

Meanwhile, conditions have worsened for migrants who make it over the border seeking better lives. Tens of thousands of Central American migrant families cross the border each month, many claiming asylum. The numbers have increased despite Trump’s derisive rhetoric and hard-line immigration policies. Border facilities have been dangerously cramped and crowded well beyond capacity. The Department of Homeland Security’s watchdog found fetid, filthy conditions for many children. And lawmakers who traveled there recently decried conditions .

Immigration courts are backlogged by more than 800,000 cases, meaning many people won’t have their asylum claims heard for years despite move judges being hired.

People are generally eligible for asylum in the U.S. if they feared return to their home country because they would be persecuted based on race, religion, nationality or membership in a particular social group.

During the budget year for 2009, there were 35,811 asylum claims, and 8,384 were granted. During 2018 budget year, there were 162,060 claims filed, and 13,168 were granted.

Associated Press writer Michael Balsamo contributed to this report.

READ MORE: Rep. Castro secretly recorded a migrant facility in Texas. Here’s what he found