On Thursday afternoon, the US Senate voted in favor of the FISA Amendments Reauthorization Act of 2017, a bill that will expand the warrantless surveillance of US citizens. The bill passed by a vote of 65-34, with 43 Republicans and 21 Democrats voting in its favor.

The bill will now go to the White House to be signed into law by President Trump. It reauthorizes FISA Section 702 until 2024.

The bill was discussed Tuesday and Wednesday afternoon in the Senate. A bipartisan group of five senators led by Republican Rand Paul and Democrat Ron Wyden attempted to filibuster the bill in order to foster actual debate about its implications. The filibuster lasted only two-and-a-half hours, however, after the senate voted by a narrow margin to limit the debate to just 30 hours.

The FISA Amendment Reauthorization Act of 2017 passed by the Senate is nearly identical to a bill of the same name that was passed by the House of Representatives last week. It deals with the reauthorization of Section 702 of the Foreign Intelligence Surveillance Act, an amendment enacted in 2008 that allows US intelligence agencies to spy on foreigners without a warrant.

The problem, however, is that Section 702 has also been abused to spy on American citizens without a warrant, too. This is the result of two loopholes known as “backdoor search” and “about collection.”

Read More: Why the Vote on FISA Section 702 Matters

With backdoor search, intelligence agencies can monitor the communications of any American that has been in touch with any foreigner the agency deems a target. About collection allows intelligence agencies to monitor the electronic communications of any American that mentions information, such as a phone number or email address, about a foreign target, even if they have never communicated with that foreigner.

The practice of about collection was voluntarily abandoned by the NSA in early 2017 after it came under increasing scrutiny by the Foreign Intelligence Surveillance Court. The bills passed by the House and Senate, soon to become law, will effectively reverse the NSA’s decision and codify the practice of about collection.

Prior to the Senate vote in favor of this bill, senators Paul and Wyden co-sponsored an alternative FISA reauthorization bill called the USA Rights Act. This version would officially make about collection illegal, require a warrant for backdoor searches, and require strict oversight of intelligence agencies by an independent agency. It was widely supported by civil rights groups, but was never able to be debated on the Senate floor.