FILE - In this June 13, 2017, file photo, Attorney General Jeff Sessions speaks on Capitol Hill in Washington, as he testifies before the Senate Intelligence Committee. (AP Photo/Alex Brandon, File)

WASHINGTON (AP) — President Donald Trump on Tuesday began dismantling the government program protecting hundreds of thousands of young immigrants who were brought into the country illegally as children. Attorney General Jeff Sessions declared the Obama administration’s program “an unconstitutional exercise of authority” that must be revoked.

New applications will be halted for President Barack Obama’s Deferred Action for Childhood Arrivals, or DACA, program, which has provided nearly 800,000 young immigrants a reprieve from deportation and the ability to work legally in the U.S. in the form of two-year, renewable work permits.

“I’m here today to announce that the program known as DACA that was effectuated under the Obama administration is being rescinded,” Sessions announced.

But the administration is giving Congress six months to come up with a legislative fix — “should it choose to,” Sessions said — before the government stops renewing permits for people already covered by the program.

According to Department of Homeland Security officials, people with permits whose renewals are set to expire between now and March 5, 2018, will be able to re-apply — so long as their applications are submitted by Oct. 5, 2017, one month from Tuesday.

Trump had suggested in an earlier tweet that it would be up to Congress to ultimately decide the fate of the young immigrants, dubbed “Dreamers” in a reference to an earlier legislative effort. He tweeted, “Congress, get ready to do your job – DACA!”

“Make no mistake, we are going to put the interest of AMERICAN CITIZENS FIRST!” Trump added in a second, retweeted message. “The forgotten men & women will no longer be forgotten.”

Sessions’ announcement came the same day as a deadline set by a group of Republican state officials who said they would challenge DACA in court unless the Trump administration rescinded the program. Administration officials argued the program might not hold up in court — and said that allowing the lawsuit to proceed would throw the program into chaos.

Trump has spent months wrestling with what to do with DACA, which he slammed during his campaign as illegal “amnesty.” Many of his closest advisers, including Sessions, policy adviser Stephen Miller, and former chief strategist Steve Bannon argue that the program is unconstitutional and have urged Trump to follow through on his campaign promise to end it.

But Trump has repeatedly expressed sympathy for the young people protected by the program, describing the decision as one of the most difficult he’s had to grapple with as president.

“I think the Dreamers are terrific,” Trump said last week, using a term popularized by supporters of the program, which was created in 2012 as a stopgap as the Obama administration pushed unsuccessfully for a broader immigration overhaul in Congress.

All the while, his administration has continued to issue new permits and extensions to immigrants who qualify.

But his approach — essentially kicking the can down the road and letting Congress deal with it— is fraught with uncertainty and political perils for his own party. Trump’s decision to take a harder line on young immigrants unless Congress intervenes threatens to emphasize deep divisions among Republicans who have long struggled with the issue.

The Obama administration created the DACA program in 2012 as a stopgap as it pushed unsuccessfully for a broader immigration overhaul in Congress,

House Speaker Paul Ryan said in a statement he hoped the “House and Senate, with the president’s leadership, will be able to find consensus on a permanent legislative solution that includes ensuring that those who have done nothing wrong can still contribute as a valued part of this great country.”

“Congress writes laws, not the president, and ending this program fulfills a promise that President Trump made to restore the proper role of the executive and legislative branches. But now there is more to do, and the president has called on Congress to act,” he said.

But Congress has repeatedly tried — and failed — to come together on immigration overhaul legislation, and it remains uncertain whether the House would succeed in passing anything on the divisive topic.

House Democratic Leader Nancy Pelosi called Trump’s decision “a deeply shameful act of political cowardice and a despicable assault on innocent young people in communities across America.”

“The president’s cruel and heartless decision to start deporting DREAMers in six months demands an immediate response from the Republican Congress,” she added, calling on Ryan and other Republican leaders to bring legislation to protect the young immigrants to a vote.

One bill addressing the issue that has received the most attention, introduced by Sens. Lindsey Graham, R-S.C., and Dick Durbin, D-Ill., would grant permanent legal status to more than 1 million young people who arrived in the United States before they turned 18, passed security checks and met other criteria, including enrolling in college, joining the military or finding jobs.

It’s unclear, however, whether the president would support that or any other existing legislation. He could encourage the writing of a new bill — tied, perhaps, to funding for his promised border wall or other concessions like a reduction in legal immigration levels.

But it’s unclear how much political capital the president would want to put on the line given his base’s strong opposition to illegal immigration, his campaign rhetoric blasting DACA as illegal “amnesty” and his reluctance to campaign hard for other priorities, like health care overhaul.

Trump’s expected move has sparked protests, phone banks, letter-writing campaigns and other efforts across the country urging him not to act.