The House of Representatives has passed by a landslide an amendment to the Defense Appropriations bill that will cut off funding to National Security Agency’s “backdoor” surveillance. The act, which places limits on how the NSA can gain access to communication, including email, online browsing, and chat histories, still has to gain Senate approval, but it represents a significant coup for opponents of the NSA. The act had strong bipartisan support, with 293 ayes, 123 nays, and one present.

Details of the NSA’s surveillance program were revealed by former contractor Edward Snowden last year. “Backdoor” surveillance searches conducted without a warrant. The bill, led by Representatives Zoe Lefgren and Thomas Massie, would prevent the NSA from using funding from the Defense Appropriations Bill to conduct these types of searches.

The amendment followed a bill proposed in March by President Barack Obama that would put an end to the NSA’s ability to collect call data in bulk. If it is approved by Congress, the bill means that bulk records would only be retained by phone companies for as long as they usually would, instead of being saved for the NSA, and that the NSA would only be able to obtain specific records after a court order.