WASHINGTON — The CIA’s former deputy director said Wednesday he deleted references to terrorism warnings from widely disputed talking points on the deadly 2012 Benghazi attack to avoid the agency’s gloating at the expense of the State Department.

Mike Morell faced more than three hours of questioning from the House intelligence committee in a rare open session that examined who changed the talking points — and why — in the politically charged aftermath of the deadly Sept. 11, 2012, assault on a US diplomatic mission in Libya.

Four Americans, including US Ambassador Chris Stevens, were killed in two separate attacks over a chaotic period of several hours. Multiple independent and congressional investigations have largely faulted the State Department for inadequate security at the mission.

Morell, a 33-year veteran of the spy agency who has served six Republican and Democratic presidents, insisted that politics had no bearing on the revisions to the talking points and said he was under no pressure to protect either President Obama or then-Secretary of State Hillary Rodham Clinton.

“I never allowed politics to influence what I said or did. Never,” he said.

The White House, wrapped up in a fierce presidential campaign, made only minor editorial changes to the talking points, according to Morell.

The intelligence community’s talking points, compiled for members of Congress, suggested the Benghazi attack stemmed from protests in Cairo and elsewhere over an anti-Islamic video rather than an assault by extremists.

Republicans have accused the Obama administration of trying to mislead the American people about an act of terrorism in the final weeks before the November election.

Morell deleted references to extremist threats linked to al Qaeda in versions of the talking points that were used by Susan Rice, then US ambassador to the United Nations, in a series of Sunday talk-show appearances. Morell said his actions were driven by the information provided by intelligence community analysts and the Defense Department.

He said the CIA knew that some of the individuals involved in the attack were al Qaeda from classified sources, information that couldn’t be included unless it was declassified. The talking points were provided to members of the committee for dissemination to the American people.

Morell said he removed references to the warnings based on previous CIA analysis. Otherwise, he said, the talking points would have been a “way for CIA to pound its chest and say, ‘We warned,’ laying all the blame on the State Department.”