WASHINGTON Legislation that would allow the families of Sept. 11 victims to sue the government of Saudi Arabia for allegedly backing the terrorists who carried out the attacks could be devastating to the U.S. military, according to Defense Secretary Ash Carter.

Carter’s admonition, detailed in a letter to a senior member of Congress and released Tuesday, comes as lawmakers prepare to vote to override President Barack Obama’s veto of the bill. Carter said he’s sympathetic to the intent of the measure, but cautioned the legislation could lead to the public disclosure of American secrets and even undercut counterterrorism efforts by sowing mistrust among U.S. partners and allies.

The Senate is scheduled to hold an override vote Wednesday, and the House is expected to follow despite deep misgivings among a number of lawmakers about the bill’s effect on the United States. They fear the measure will boomerang and further complicate relations with a longstanding U.S. ally in the Middle East.

“I’ve got concerns about what this bill is going to mean to America,” said Sen. Bob Corker, R-Tenn., the chairman of the Foreign Relations Committee. “It’s the blowback to us because we’re the most involved in the world. You end up exporting your foreign policy to trial lawyers.”

The Senate’s top Democrat, Harry Reid of Nevada, predicted Tuesday Obama’s veto would not be sustained. If the House also overrides, the bill would become law. During his nearly two full terms in office, Obama has never had a veto overridden by Congress.

The legislation, which has broad support among Democrats and Republicans, gives victims’ families the right to sue in U.S. court for any role that elements of the Saudi government may have played in the 2001 attacks that killed nearly 3,000 people. Fifteen of the 19 Sept. 11 hijackers were Saudi nationals.

Courts would be permitted to waive a claim of foreign sovereign immunity when an act of terrorism occurs inside U.S. borders, according to the terms of the bill. Saudi Arabia has objected vehemently to the legislation.

Obama rejected the measure Friday, telling lawmakers the bill would make the U.S. vulnerable to retaliatory litigation in foreign courts that could put U.S. troops in legal jeopardy. The bill’s proponents have disputed Obama’s rationale as “unconvincing and unsupportable,” saying the measure is narrowly tailored and applies only to acts of terrorism that occur on U.S. soil.

But Obama said foreign governments would be able to act “reciprocally” and allow their courts to exercise jurisdiction over the United States and its employees for allegedly causing injuries overseas through American support to third parties. He cited as notional examples actions that might be taken overseas by U.S.-backed armed militias and the improper use by foreign forces of U.S. military equipment.

Carter amplified Obama’s concerns in a Sept. 26 correspondence to Rep. Mac Thornberry of Texas, the Republican chairman of the House Armed Services Committee and an opponent of the legislation. Thornberry last week urged his GOP colleagues to let Obama’s veto stand.

In the letter, Carter described the potential for litigants to seek classified intelligence data and analysis and sensitive operational information to establish their cases in what could be an “intrusive discovery process.”

If the U.S. were sued overseas, a foreign court would decide whether the information should be protected from disclosure, he said. Paradoxically, the information could be central to a defense against the accusations.

“Disclosure could put the United States in the difficult position of choosing between disclosing classified or otherwise sensitive information or suffering adverse rulings and potentially large damage awards for our refusal to do so,” Carter wrote.

Whether or not a case has merit, the U.S. would still have to defend itself or its troops against private litigants in foreign courts, Carter added. That raises the possibility of service members who refuse to appear or to divulge classified information being held in civil or criminal contempt by the foreign court, according to Carter.

If a case results in a sizeable monetary award for damages, the U.S. could have to fend off effort to seize U.S. property as payment, according to Carter.

Allowing U.S. partners and allies to be subject to lawsuits in the United States will undermine the trust and cooperation American forces need to accomplish their missions and could have “a chilling effect on our own counterterrorism efforts,” Carter told Thornberry.