WASHINGTON -- Defiant in one of her final appearances in office, Secretary of State Hillary Clinton told Congress on Wednesday that she accepts responsibility for security lapses in the deadly Sept. 11 attack on U.S. posts in Libya. But she also stressed that the assault was part of a broader war against extremists in North Africa.Although her voice cracked and she appeared close to tears when describing the deaths of Ambassador Chris Stevens and three other Americans, Clinton overall seemed confident -- and even combative at times -- when pressed on security lapses in the attacks in the eastern city of Benghazi.The questioning took on highly partisan tones: Democrats blamed Congress for denying funds that they say would have helped the State Department improve diplomatic security, and Republicans depicted an administration cover-up of high-level negligence in security measures.Clinton appeared first before the Senate Foreign Relations Committee and then at the House Foreign Affairs Committee.Being summoned before Congress to answer for what an independent panel called "grossly inadequate" security procedures was hardly the ideal career capstone for Clinton, who vows to exit the political stage once her presumed successor, Sen. John Kerry, D-Mass., is confirmed. One Democrat openly lamented that Clinton's final appearance before Congress was to discuss a tragedy rather than to recap her diplomatic successes."Nobody wants to sit where I am and have to think now about what coulda, shoulda, woulda happened," Clinton told the Senate panel.Current events continually encroached on what was to have been the long-awaited reckoning over the Obama administration's handling of the Benghazi attack.In response to pointed questions about the administration's readiness to combat al Qaeda-allied forces that are trying to win a foothold in North Africa, Clinton called the fight "a necessary struggle." She tied the assault in Libya to last week's hostage crisis in Algeria and to the French-led military campaign against Islamist rebels in northern Mali.Clinton portrayed the militant operation against the U.S. Consulate and nearby CIA annex in Benghazi as a direct consequence of the Arab Spring revolts, which toppled autocrats and gave operational space to long-suppressed radical forces. She said weapons that disappeared in the fall of Libyan leader Moammar Gadhafi's regime undoubtedly had been smuggled to other countries, including for use in the Syrian uprising.At least twice, Clinton's voice cracked and she appeared close to tears when addressing the deaths of colleagues. But she also showed a combative streak, especially when firing back at suggestions that the department had failed to debrief evacuees to find out quickly whether the attack was the outgrowth of a spontaneous demonstration or a well-planned terrorist operation."The fact is, we had four dead Americans!" Clinton practically yelled to Sen. Ron Johnson, R-Wis., stressing that her first priority during the evacuation was treatment for the wounded."Was it because of a protest or because of guys out for a walk one night who decided they'd go kill some Americans?" she continued."What difference at this point does it make? It is our job to figure out what happened and prevent it from ever happening again, senator."Republican lawmakers had demanded for months that Clinton explain in person the many missteps that an independent review panel found in her department's handling of the crisis.Clinton's appearance was delayed by a prolonged illness and a concussion she suffered when fainting, though some right-wing critics accused her of trying to wriggle out of her commitment to testify.On Wednesday, Clinton reiterated her full responsibility for the overall security posture of the department.But she reminded the committee that the review board had found that direct responsibility for the deficiencies highlighted during the Benghazi assault began at the level of assistant secretary and below.Republican lawmakers, however, insisted that Clinton be held directly responsible. "Had I been president at the time, I would have relieved you of your post," said freshman Sen. Rand Paul, R-Ky.