WASHINGTON — House leaders on Tuesday struck a bipartisan deal to overhaul surveillance laws just days before a trio of F.B.I. investigative tools expires, raising the possibility of a last-minute breakthrough in a politically complex debate over civil liberties and national security.

The changes would install new privacy protections — including adding a skeptical voice to secret court deliberations when the F.B.I. wants to eavesdrop on Americans under certain circumstances — but stop short of more sweeping limits favored by some civil libertarians in both parties that are viewed skeptically by national security officials and centrist lawmakers.

If it becomes law, the bill would represent Congress’s response to a damning inspector general report that uncovered numerous errors and omissions by the F.B.I. in applications under the Foreign Intelligence Surveillance Act, or FISA, to wiretap Carter Page, a former Trump campaign adviser, during the early stages of the Russia investigation.

But even if the House passes the legislation, the bill could face obstacles in moving quickly through the Senate, where it would need 60 votes to overcome any filibuster. It would also need to be signed by President Trump, who has been unpredictable on surveillance policy issues while displaying a hazy understanding of their details.