The White House is firing back at congressional Republicans who are threatening to sue should President Barack Obama use his executive authority to close the Guantánamo Bay, Cuba, terrorist detention center.

As the White House prepares to send Congress a plan to shutter the facility perhaps as soon as Friday, congressional leaders have dubbed it dead on arrival. The Obama administration continued Thursday refusing to rule out another option: Using an executive action to close the prison, citing the president’s war powers under Article II of the Constitution. Asked about Senate Armed Services Committee Chairman John McCain’s declaration Wednesday that such a move would be “unconstitutional,” White House Press Secretary Josh Earnest grinned and replied, “Gives you a sense of what we’re up against — even our friends on this issue are threatening lawsuits.”

Earnest was referring to the Arizona Republican’s status as perhaps the White House’s most prominent congressional ally on shuttering the facility. McCain, a prisoner of war during the Vietnam conflict, has long supporting closing the controversial prison. In fact, during the 2008 presidential campaign, it was one issue on which he agreed with his general election opponent.

Republicans have sued the Obama administration over the president’s executive action on immigration and tried to use litigation to dismantle his health care overhaul. Cases on the former are still pending, and ones on the latter went in favor of the White House — something Earnest used to poke McCain and his colleagues.

WH: Closing Gitmo via Executive Action 'On the Table'

“The are a number of times when Republicans have threatened legal action … where their legal efforts have not at all been successful,” Earnest said. “And we’ve had two Supreme Court rulings now that have overturned significant Republican threats to the Affordable Care Act.

“The track record of House Republicans, in this regard, is not particularly good,” he said, attempting to pin blame for any possible high-profile legal battle squarely on lawmakers’ shoulders.

“If this is an issue that ends up in court, it will be a result of the abject failure of the United States Congress to put the national security interests of the United States first,” Earnest said, ticking off a list of former senior national security officials who support closing Guantánamo.

Notably, he included former CIA Director David Petraeus, who also led U.S. forces in Iraq and later Afghanistan as a four-star Army general, calling him “someone Sen. McCain looks up to.”

Two former White House officials, Gregory Craig and Cliff Sloan, penned a detailed op-ed Sunday that many took as a trial balloon for an Article II closure action. Craig was White House counsel from 2009 to 2010. Sloan was Obama’s special envoy for closing the Guantánamo facility from 2013 to 2014.

The pair stated the president has the Constitutional authority to move detainees from any detention center and close it. They also declared “unconstitutional” any lawmaker-passed limitations on using federal dollars to close such a prison.

The White House has spent months crafting its Guantánamo closure plan, with Earnest saying only it will be sent to Capitol Hill “relatively soon.”

He contended there will be "no surprises" in the plan, saying the administration has made its desires known for transferring prisoners from the controversial facility to other countries and maximum security prisons on U.S. soil.

Seven military and federal facilities in Colorado, Kansas and South Carolina are expected to be identified by the White House as potential destinations for those Guantánamo detainees who cannot be released to other countries, congressional aides and other sources say.

But Obama’s plan is expected to die as soon as it arrives on the Hill.

On Tuesday, Senate Majority Leader Mitch McConnell, R-Ky., said Republicans and Democrats have voted for numerous bills that prohibit the president from “moving terrorists into our country."

"The president may not like this bipartisan action, it may conflict with the campaign slogan from eight or nine years ago, but here's how one senator put it: Congress' job is to pass legislation," McConnell said. "The president can veto it or he can sign it. That was then-Senator Obama."

“I strongly believe Obama will use his executive authority to close the prison because it’s a national security risk,” said one defense attorney representing a Guantanamo detainee. “He will use every aspect of his executive authority to close it — and soon.”

Such a case, the defense attorney said, would pit “the president’s constitutional powers to wage war against the legislative branch’s power of the purse.”