WASHINGTON -- Former CIA Director David Petraeus is expected to testify Friday before congressional lawmakers that he knew "almost immediately" the attack on the U.S. Consulate in Benghazi, Libya, was the work of a loosely-formed militia with members sympathetic to al Qaeda.
Petraeus' testimony will be behind closed doors before Republican and Democratic members of the House and Senate intelligence committees looking into the September 11 attack that left four American dead, including U.S. Ambassador Chris Stevens.
The attack on the consulate was a political hot button during the presidential campaign as questions were raised about everything from security at the compound to the Obama administration's initial description of the events.
The issue has been further complicated by Petraeus' surprise resignation last week after publicly admitting to an extramarital affair, which immediately raised questions among administration detractors about whether his departure was linked to fallout over the Benghazi attack.
Sen. Dianne Feinstein, the Senate Intelligene Committee chair, has insisted despite his resignation that Petraeus testify. She has said what he knew was imperative for committee members to understand what happened before, during and after the attack on the consulate.
Petraeus is expected to tell lawmakers that the CIA knew fairly quickly following the attack on the diplomatic compound that it was the work of Ansar al Sharia, according to an official with knowledge of the case. The official spoke on condition of anonymity because of the sensitivity of the subject matter.
Petraeus believes, according to the official, confusion has emerged over two separate intelligence questions: Who was responsible, and what was the motivation of the attack?
According to the official, Petraeus says the stream of intelligence from multiple sources, including video at the scene, indicated the group was behind the attack.
But a separate stream of intelligence also emerged at the same time indicating the violence at the consulate was inspired by protests in Egypt over an ostensibly anti-Islam film that was privately produced in the United States. The movie, "Innocence of Muslims," portrayed the Prophet Mohammed as a womanizing buffoon.
There were 20 intelligence reports that indicated that anger of the film may be to blame, the official said.
The CIA eventually disproved those reports, but not before Petraeus' initial briefing to Congress following the attack where he discussed who might be behind the attack and what prompted it. During that briefing he raised Ansar al Sharia's possible connection as well as outrage over the film, the official said.
Petraeus' aim in testifying, according to the official, is to clear up "a lot of misrepresentations of what he told Congress initially."
The former CIA director also is expected to tell the congressional committees that he did develop unclassified talking point in the days after the attack but had had no direct involvement in developing the ones used by Susan Rice, the U.S. ambassador to the United Nations.
Rice has been under fire for suggesting the attack on the consulate was a spontaneous event spurred by a protest against the anti-Muslim film.
An official familiar with the briefing said one Republican House member "got into it" Thursday with acting CIA Director Michael Morrel and Director of National Intelligence James Clapper about Rice's comments, challenging why they weren't as strong as they should have been on whether an extremist element was involved in the attack.
The official, who was not authorized to discuss the matter, spoke on condition of anonymity.
Petraeus, meanwhile, can also expect to be asked whether his resignation from the CIA's top post had anything to do with the attack in Libya.
Rep. Dutch Ruppersberger of Maryland, the senior Democrat on the House Intelligence Committee, told reporters Thursday that he plans to ask Petraeus: "Did your resignation have anything to do with the fact that you were suppose to testify before Congress?"
Petraeus told Krya Phillips of HLN, CNN's sister network, that his resignation was not linked to the Benghazi attack and that he never passed classified information to the woman he was having an affair with at the time.
CNN's Barbara Starr, Suzanne Kelley, Ted Barrett and Chelsea J. Carter contributed to this report.