Three controversial provisions of the Patriot Act expired last night, after the Senate was unable to pass legislation renewing them before a midnight deadline. The expiration of the spying authorities occurred in part because of a dramatic filibuster staged two weeks ago by Sen. Rand Paul (R-KY) and several other senators critical of National Security Agency spying. As a result, the Senate was unable to pass legislation extending three provisions of the Patriot Act, including one that the NSA has invoked to justify its controversial phone records program, which were scheduled to expire at midnight.

On Sunday, the Senate returned from a weeklong recess to resume debate on the expiring Patriot Act provisions. And continued opposition from Paul and other privacy advocates forced surveillance hawks to accept compromise legislation supported by most Democrats — but opposed by Paul — called the USA Freedom Act. The USA Freedom Act has already passed the House, but as of a week ago its chances looked dim in the Senate, where Majority Leader Mitch McConnell (R-KY) was against it. But McConnell now believes it is "the only realistic way forward."

Even so, the Senate wasn't able to pass the USA Freedom Act quickly enough to prevent the Patriot Act provisions from temporarily expiring. That would have taken an expedited process that could only happen with the unanimous consent of the Senate. And Paul had no intention of giving his consent.

"Little by little, we've allowed our freedom to slip away," he said on Sunday. "We allow the Fourth Amendment to be diminished."

If the Senate passes the USA Freedom Act without changes, it will go to President Obama's desk for signature. But there's still room for the Senate to make changes to the legislation, which would send the bill back to the House and prolong the debate over NSA spying.

In the end, though, Paul's tactics are likely to end in the passage of legislation both Paul and McConnell opposed — but that the White House and congressional Democrats support.

Three Patriot Act provisions have expired

Three provisions of the Patriot Act expired at midnight on Sunday, May 31.

Most of the debate in recent weeks has focused on Section 215 of the Patriot Act, which allows the government to obtain business records that are relevant to an anti-terrorism investigation. The government has argued that this provision allows it to collect the phone records of every American, since some of those records will eventually prove useful for counterterrorism purposes. Critics, such as Patriot Act author Rep. James Sensenbrenner (R-WI) and the Second Circuit Court of Appeals, say the government is misreading the law and that the NSA's phone records program is illegal.

Also expiring was a "roving wiretap" rule that allows the government to file one application to spy on multiple phone lines owned by the same suspect. And there was a provision that allows the government to ask the secretive FISA courts for warrants to spy on "lone wolf" terrorists who are not associated with any known government or terrorist group.

The government warned that if these programs expire, even temporarily, the consequences for America's national security could be catastrophic. "What you’re doing, essentially, is you’re playing national security Russian roulette," one anonymous White House official said this week.

But civil liberties advocates disagreed. While Section 215 is undoubtedly helpful in counterterrorism investigations, civil liberties groups point out that the government has lots of other ways it can get access to business records in order to spy on terrorists. The same goes, they say, for the roving wiretaps and lone wolf provisions. In fact, the "lone wolf" language has reportedly never been used.

The USA Freedom Act prohibits the bulk collection of phone customer data — but it doesn't go as far as some civil liberties groups want

If, like most Americans, you've never heard of the USA Freedom Act, here's a primer:

The USA Freedom Act has drawn criticism from some of the most ardent privacy advocates, including Paul, who see it as a vehicle for perpetuating, rather than ending, NSA spying. These hard-liners believe it's better to simply allow a controversial Patriot Act provision, known as Section 215, to expire. That would reduce NSA spying authority without granting the agency any new powers.

But advocates of the USA Freedom Act point out that Section 215 isn't the only government spying power that could be subject to abuse. Other powers, such as National Security Letters, are not scheduled to expire at midnight tonight. And so advocates say the USA Freedom Act — which contains a number of procedural and transparency reforms — would be an important step toward holding the NSA accountable.

At the same time, privacy experts say the USA Freedom Act has some flaws. Amie Stepanovich, a legal expert at the pro-privacy group Access, told me two weeks ago that "the bill allows for the collection of information 'two hops out' — records of entities who communicate with or are otherwise connected to a target. This would wrap in sensitive information of potentially millions of non-targets."

Advocates of the USA Freedom Act argued that the imminent expiration of Section 215 gave privacy advocates a strong bargaining position. In their view, Paul's purist stance risked squandering a golden opportunity to achieve reforms that wouldn't be possible otherwise.

Major civil liberties groups such as the Electronic Frontier Foundation and the American Civil Liberties Union have taken an ambivalent stance on this debate. They agree with Paul that the USA Freedom Act doesn't go far enough to rein in NSA spying. But they also haven't rallied behind Paul, who has yet to put forward a constructive alternative.

Paul left the Senate with three options

The Senate had three options. It could pass the USA Freedom Act, which was approved by the House in mid-May and was supported by the White House and many privacy advocates. It could renew the Patriot Act provisions without changing them — this is the choice McConnell preferred. Or it could do nothing and simply let the Patriot Act provisions lapse.

Last weekend, when McConnell brought these first two options to a vote, neither was able to muster the 60 votes required to overcome a filibuster. The USA Freedom Act got 57 votes — including all Democrats and a handful of Republicans. A "clean" reauthorization of the Patriot Act got only 45 votes — mostly from Republicans.

On Sunday, after conferring with his Republican colleagues, McConnell concluded that accepting the limits of the USA Freedom Act was the only way to preserve the Patriot Act powers — albeit in weakened form. With McConnell no longer urging his caucus to vote against it, the Senate voted 77-17 to overcome a filibuster on Sunday.

But the Senate's rules didn't allow debate over the legislation to wrap up quickly enough to forestall the expiration of the Patriot Act powers. And there's still a possibility that the Senate will adopt amendments to the legislation that could prove unacceptable to the House, creating yet another impasse.