From left, Deputy Attorney General James Cole; National Security Agency (NSA) Deputy Director Chris Inglis; NSA Director Gen. Keith B. Alexander; Deputy FBI Director Sean Joyce; and Robert Litt, general counsel to the Office of the Director of National Intelligence; prepares to testify on Capitol Hill in Washington, Tuesday, June 18, 2013, before the House Intelligence Committee hearing regarding NSA surveillance. (AP Photo/Charles Dharapak)

WASHINGTON (AP) -- The U.S. foiled a plot to bomb the New York Stock Exchange because of the sweeping surveillance programs at the heart of a debate over national security and personal privacy, officials said Tuesday at a rare open hearing on intelligence led by lawmakers sympathetic to the spying.

The House Intelligence Committee hearing provided a venue for officials to defend the once-secret programs and did little probing of claims that the collection of people's phone records and Internet usage has disrupted dozens of terrorist plots. Few details were volunteered.

Army Gen. Keith Alexander, director of the National Security Agency, said the two recently disclosed programs — one that gathers U.S. phone records and another that is designed to track the use of U.S.-based Internet servers by foreigners with possible links to terrorism — are critical. But details about them were not closely held within the secretive agency. Alexander said after the hearing that most of the documents accessed by Edward Snowden, a 29-year-old former systems analyst on contract to the NSA, were on a web forum available to many NSA employees. Others were on a site that required a special credential to access. Alexander said investigators are studying how Snowden did that.

He told lawmakers Snowden's leaks have caused "irreversible and significant damage to this nation" and undermined the U.S. relationship with allies.

When Deputy FBI Director Sean Joyce was asked what is next for Snowden, he said, simply, "justice." Snowden fled to Hong Kong and is hiding.

In the days after the leaks, House Intelligence Committee Chairman Mike Rogers cited one attack that he said was thwarted by the programs. In the comments of other intelligence officials, that number grew to two, then 10, then dozens. On Tuesday, Alexander said more than 50 attacks were averted because of the surveillance. These included plots against the New York subway system and a Danish newspaper office that had published cartoon depictions of Muhammad.

In a new example, Joyce said the NSA was able to identify an extremist in Yemen who was in touch with Khalid Ouazzani in Kansas City, Mo., enabling authorities to identify co-conspirators and thwart a plot to bomb the New York Stock Exchange.

Ouazzani pleaded guilty in May 2010 in federal court in Missouri to charges of conspiracy to provide material support to a terrorist organization, bank fraud and money laundering. Ouazzani was not charged with the alleged plot against the stock exchange. Joyce said the arrest was made possible by the Internet surveillance program disclosed by Snowden.

Joyce also said a terrorist financier in San Diego was identified and arrested in October 2007 because of a phone record provided by the NSA.

The individual was making phone calls to a known designated terrorist group overseas, Joyce said. He confirmed under questioning that the calls were to Somalia.

Alexander said the Internet program had helped stop 90 percent of the 50-plus plots he cited. He said just over 10 of the plots thwarted had a connection inside the U.S. and most were helped by the review of phone records. Still, little was offered to substantiate claims that the programs have been successful in stopping acts of terrorism that would not have been caught with narrower surveillance. In the New York subway bombing case, President Barack Obama conceded the would-be bomber might have been caught with less sweeping surveillance.

Officials have long had the authority to monitor email accounts linked to terrorists but, before the law changed, needed to get a warrant by showing that the target was a suspected member of a terrorist group. In the disclosed Internet program named PRISM, the government collects vast amounts of online data and email, sometimes sweeping up information on ordinary American citizens. Officials now can collect phone and Internet information broadly but need a warrant to examine specific cases where they believe terrorism is involved.

Alexander said he would provide the lawmakers more details on the 50-plus plots Wednesday but the details would be classified.

Committee Chairman Mike Rogers, R-Mich., and Rep. C.A. Dutch Ruppersberger of Maryland, the panel's top Democrat, said the programs were vital to the intelligence community and assailed Snowden's actions as criminal.

Story continues