President Donald Trump on Thursday offered whiplash condemnation and then support for a White House-backed bill to renew controversial online surveillance efforts, sparking confusion just hours before the House approved the measure amid resistance from civil libertarians.

The remarks, which came via two early morning tweets, were made as Republican House leaders scrambled on Capitol Hill to secure the last-minute support needed to pass legislation to retain powerful overseas spying tools that national security leaders say are vital to the country's fight against terrorism.

Story Continued Below

At 7:30 a.m., Trump first tweeted: "'House votes on controversial FISA ACT today.' This is the act that may have been used, with the help of the discredited and phony Dossier, to so badly surveil and abuse the Trump Campaign by the previous administration and others?" referring to the so-called Steele dossier, a compilation of alleged and unverified ties between Trump and Russia.

As national security experts lambasted the tweet and surveillance critics jumped on it to stump for their cause, some of the bill's backers started to worry that Trump's comments could convince on-the-fence Republicans to withhold their vote.

Two hours later, Trump issued a second tweet, appearing to reverse course: "With that being said, I have personally directed the fix to the unmasking process since taking office and today’s vote is about foreign surveillance of foreign bad guys on foreign land. We need it! Get smart!"

POLITICO Playbook newsletter

Sign up today to receive the #1-rated newsletter in politics

Email

By signing up you agree to receive email newsletters or alerts from POLITICO. You can unsubscribe at any time.

The back-and-forth messaging undercut the administration's own talking points on legislation to extend the digital spying tools authorized under Section 702 of the Foreign Intelligence Surveillance Act, which intelligence agencies use to hoover up the digital chatter of non-U.S. citizens located overseas.

The president’s tweets also lit up the House GOP conference Thursday morning before the vote. Republicans fretted about backing legislation that the president opposed, pointing to Trump's initial tweet blaming the legislation for what he’s dubbed the Russia probe “witch-hunt.”

At one point, Majority Leader Kevin McCarthy pulled up the president’s Twitter posts on his phone, handed his phone to House Intelligence Chairman Devin Nunes, and had the California Republican read the second tweet, in which Trump clarified his support for the FISA bill. Earlier that morning, after the first tweet, House GOP leaders phoned Trump and the White House to ask him to clarify his comments and find out if he had any objections.

“I think [House Republicans] just needed more clarification. Was there support? What was the concern? What were his issues?” said House Republican Study Committee Chairman Mark Walker (R-N.C.). "For members who were somewhat undecided or lean-no or lean-yes, if the president comes in and weighs in on something, I think that is impactful. And that’s why they wanted to make sure that at the end of the day, or at the end of this conversation, that he is supportive overall of this bill.”

The House on Thursday voted on two significantly different approaches to retaining the 702 statute. And until Thursday morning, the White House had been relatively consistent in signaling support for one approach and opposition to the other.

The bill that passed — favored by Republican leadership, and which the White House has said Trump would sign — leaves the 702 programs relatively untouched. Trump's national security leaders have lobbied hard for months to get such a bill passed, arguing the without the tools have been used to thwart terrorist plots and fight hackers.

The competing measure was a libertarian- and privacy advocate-favored proposal that would rein in the snooping efforts significantly. Critics of the 702 statute say it allows the government to spy on Americans without a warrant, since some personal information on U.S. citizens is incidentally collected during the foreign-focused snooping efforts.

Trump's first tweet was received as a signal of support for the proposal to overhaul the 702 statute, with even Democratic surveillance critics using his comments to champion their cause.

The initial tweet also seemingly ran in opposition to a White House statement Wednesday night saying the administration "strongly opposes" the bill to heavily revise the 702 surveillance efforts.

The revisionist bill, offered as an amendment Thursday, would have placed a stringent warrant requirement on federal agencies seeking to access Americans' data contained in the NSA's vast database of communications collected under the 702 programs, as well as other policies aimed at reining in the online tools.

"This amendment would re-establish the walls between intelligence and law enforcement that our country knocked down following the attacks of 9/11 in order to increase information sharing and improve our national security," White House press secretary Sarah Huckabee Sanders said Wednesday. "The administration urges the House to reject this amendment and preserve the useful role FISA’s Section 702 authority plays in protecting American lives."

But Trump's second tweet appeared to be back in line with White House messaging on the subject, addressing a subject — the "unmasking" process by which Americans' identities can be exposed in intelligence reports — that has been conflated with the 702 renewal fight, even though many argue it is only tangentially related.

Normally, Americans have their identity protected in foreign intelligence reports, but certain senior officials can request to have the names "unmasked" if it is essential to understanding the intelligence value of the report. Trump and his allies have alleged that the Obama administration abused this process to spy on Trump aides during and after the campaign. Trump on Tuesday ordered the intelligence community to develop new guidelines for handling unmasking requests.

The president's tweets Thursday aren't the first time his rhetoric has undermined his own administration's push for a so-called clean reauthorization of the 702 statute, without changes.

That includes a tweet last March claiming that “[former President Barack] Obama had my ‘wires tapped’ in Trump Tower,” which provided an early public relations victory for privacy-minded Democrats and civil libertarian-oriented Republicans who want to curb the federal government’s ability to eavesdrop on digital communications.

And Trump’s complaints often haven't related directly to the 702 programs. Similarly, on Thursday, Trump appeared to tie together several connected but disparate issues — FISA wiretaps of Americans, the unmasking process and the foreign-focused 702 programs.

National security experts and 702 supporters on Capitol Hill expressed fears the confusing remarks would further muddy the waters ahead of Thursday's critical votes, misleading members who aren't intimately familiar with the statute's technical aspects.

"This is the single most dangerous and irresponsible thing the President has ever tweeted," tweeted Susan Hennessey, a former NSA attorney who now serves as executive editor of the blog Lawfare.

"This is irresponsible, untrue, and frankly it endangers our national security," tweeted Virginia Sen. Mark Warner, the top Democrat on the Intelligence Committee. "FISA is something the President should have known about long before he turned on Fox this morning."

Indeed, Trump's tweet was leveraged by those backing the alternative renewal measure — which has already been applauded by privacy and civil liberty groups and the libertarian House Freedom Caucus — even as they distanced themselves from the technical details.

Rep. Ted Lieu (D-Calif.), who has a computer science degree, tweeted: "While I don't agree with the specifics of what @realDonaldTrump said, I agree with the overall point: the FISA ACT & warrantless spying on Americans have gotten out of control. Republicans & Dems should vote NO on [House Intelligence Chairman Devin Nunes'] harmful FISA Reauthorization bill."