(Ricky Carioti/The Washington Post)

The Trump administration on Tuesday asked the Supreme Court to allow it to enforce a new policy of denying asylum to those who illegally cross the U.S.-Mexico border, a change that lower courts have declared likely illegal.

A panel of the U.S. Court of Appeals for the 9th Circuit ruled 2 to 1 Friday that the policy was a way around specific language in federal law that allows all who enter the United States, regardless of where, to apply for asylum. The panel upheld a stay on the new policy that had been entered by a district judge.

“Just as we may not, as we are often reminded, ‘legislate from the bench,’ neither may the Executive legislate from the Oval Office,” wrote Circuit Judge Jay S. Bybee.

Solicitor General Noel Francisco said in an application to Justice Elena Kagan that the presidential proclamation was intended to “address an ongoing crisis at the southern border, with significant implications for ongoing diplomatic negotiations and foreign relations.” Kagan is the justice designated to deal with emergency matters from the 9th Circuit.

Francisco said the policy was intended to “channel legitimate asylum seekers to ports of entry for orderly processing and would facilitate ongoing negotiations with Mexico and other countries regarding unlawful mass migration.”

But lower courts said the law doesn’t allow the president to make such a change.

They pointed to the federal statute that says an asylum application must be accepted from any alien “physically present in the United States or who arrives in the United States whether or not at a designated port of arrival . . . irrespective of such alien’s status.”

Trump’s Nov. 9 proclamation that barred asylum for anyone who crossed the U.S.-Mexico border between official ports of entry was a reaction to the “caravans” of migrants from Central America.

Trump reacted angrily when U.S. District Judge Jon Tigar on Nov. 19 blocked the policy and later refused to immediately reinstate it.

“This was an Obama judge. And I’ll tell you what, it’s not going to happen like this anymore,” Trump told reporters.

Trump’s remarks brought an unusual rebuke from Chief Justice John G. Roberts Jr., who defended the federal judiciary.

“We do not have Obama judges or Trump judges, Bush judges or Clinton judges,” Roberts said in a statement released by the court’s public information office. “What we have is an extraordinary group of dedicated judges doing their level best to do equal right to those appearing before them.”

Trump responded in a tweet: “Sorry Chief Justice John Roberts, but you do indeed have ‘Obama judges,’ and they have a much different point of view than the people who are charged with the safety of our country. It would be great if the 9th Circuit was indeed an ‘independent judiciary’ . . .”

But Friday’s 9th Circuit ruling does not fit Trump’s criticism. Bybee was nominated by President George W. Bush, and is considered one of the circuit’s conservative members.

In his 65-page ruling, Bybee wrote it was “the hollowest of rights that an alien must be allowed to apply for asylum regardless of whether she arrived through a port of entry if another rule makes her categorically ineligible for asylum based on precisely that fact.”

The case is Trump v. East Bay Sanctuary Covenant.