The House of Representatives late Thursday voted to bar the National Security Agency from looking for Americans’ communications without a warrant within a database of e-mails and phone calls it gathers while targeting foreigners, a technique that critics have labeled a “backdoor search loophole.”

The House approved the ban by a 293-123 vote.

The proposal has drawn opposition from security agencies and still has a long way to go before it would become law. But chief sponsors of the provision celebrated the lopsided vote.

“Americans have become increasingly alarmed with the breadth of unwarranted government surveillance,” they said in a statement. “By adopting this amendment, Congress can take a sure step toward shutting the back door on mass surveillance.”

New York Times