Bob Woodward and Carl Bernstein defended the press while discussing recent charges that the White House leaked classified national security information to the New York Times.

The White House is facing allegations that it deliberately leaked information to the paper to play up President Obama's record on national security. John McCain and several other legislators are demanding an investigation into the leaks, while the administration has vehemently denied the charges.

Woodward and Bernstein appeared on Sunday's "Face the Nation" to mark the 40th anniversary of Watergate, and weighed in on the controversy.

When asked what he made of the allegations, Bernstein cautioned against "creating a witch hunt" for sources and reporters. "Because now more than ever we need real reporting on this presidency, on national security, on all these areas," he said. "And the press is not the problem here." He added that there were laws in place to handle people who were leaking classified information.

Woodward agreed, asking, "was there real harm to the national security?" He continued, "And it’s very difficult, I know from doing stories like this, where you are dealing with sensitive government secrets, to modulate and be careful, at the same time hold the government accountable for what they’re doing."

"The record of the press, you know, is really quite good in protecting real genuine national security secrets which we often know about," Bernstein added.

For its part, the Times has defended its reporting. Managing editor Dean Baquet said he "would more easily understand the criticism if we did not examine Obama's role in drone strikes than the criticism that we did."

Related on HuffPost:

Loading Slideshow...
  • Dianne Feinstein, Saxby Chambliss, Mike Rogers, C.A. "Dutch" Ruppersberger

    After a closed-door meeting with National Intelligence Director James Clapper, the four leaders of the House and Senate Intelligence Committees hold a news conference, on Capitol Hill in Washington, Thursday, June 7, 2012, to discuss the recent spate of classified national security information leaks. From left are Rep. C.A. "Dutch" Ruppersberger, D-Md., the ranking Democrat on the House Intelligence Committee; House Intelligence Committee Chairman Mike Rogers, R-Mich., Sen. Saxby Chambliss, R-Ga., vice-chair of the Senate Intelligence Committee, and Senate Intelligence Committee Chair Sen. Dianne Feinstein, D-Calif. (AP Photo/J. Scott Applewhite)

  • Dianne Feinstein, Saxby Chambliss, Mike Rogers, C.A. "Dutch" Ruppersberger

    After a closed-door meeting with National Intelligence Director James Clapper, the four leaders of the House and Senate Intelligence Committees hold a news conference, on Capitol Hill in Washington, Thursday, June 7, 2012, to discuss the recent spate of classified national security information leaks. From left Rep. C.A. "Dutch" Ruppersberger, D-Md., the ranking Democrat on the House Intelligence Committee; House Intelligence Committee Chairman Rep. Mike Rogers, R-Mich., Senate Intelligence Committee Chair Sen. Dianne Feinstein, D-Calif.; and Sen. Saxby Chambliss, R-Ga., vice-chair of the Senate Intelligence Committee. (AP Photo/J. Scott Applewhite)

  • Dianne Feinstein, Saxby Chambliss, Mike Rogers, C.A. "Dutch" Ruppersberger

    After a closed-door meeting with National Intelligence Director James Clapper, the four leaders of the House and Senate Intelligence Committees hold a news conference, on Capitol Hill in Washington, Thursday, June 7, 2012, to discuss the recent spate of classified national security information leaks. From left are, Rep. C.A. "Dutch" Ruppersberger, D-Md., the ranking Democrat on the House Intelligence Committee; House Intelligence Committee Chairman Rep. Mike Rogers, R-Mich., Senate Intelligence Committee Chair Sen. Dianne Feinstein, D-Calif.; and Sen. Saxby Chambliss, R-Ga., vice-chair of the Senate Intelligence Committee. (AP Photo/J. Scott Applewhite)

  • James Clapper

    Director of National Intelligence James Clapper, center, emerges from a closed-door meeting with the House and Senate Intelligence Committees aimed at stopping security leaks, Thursday, June 7, 2012, on Capitol Hill in Washington. (AP Photo/J. Scott Applewhite)

  • James Clapper

    Director of National Intelligence James Clapper, center, emerges from a closed-door meeting with the House and Senate Intelligence Committees aimed at stopping security leaks, Thursday, June 7, 2012, on Capitol Hill in Washington. (AP Photo/J. Scott Applewhite)

  • Jay Carney

    Press Secretary Jay Carney briefs reporters at the White House in Washington, Monday, June 4, 2012. (AP Photo/Charles Dharapak)

  • House Leader Boehner And Cantor Respond To Obama's Economic News Conference

    WASHINGTON, DC - JUNE 08: House Majority Leader Eric Cantor (R-VA) (L) and U.S. Speaker of the House John Boehner (R-OH) (R) respond to U.S. President Barack Obama's remarks on the U.S. economy June 8, 2012 in Washington, DC. During their remarks, Cantor said, 'Did he see the job numbers that came out last week? The private sector is not doing fine. And, frankly, I'd ask the president to stop engaging in the blame game.' (Photo by Win McNamee/Getty Images)

  • House Leader Boehner And Cantor Respond To Obama's Economic News Conference

    WASHINGTON, DC - JUNE 08: House Majority Leader Eric Cantor (R-VA) (L) and U.S. Speaker of the House John Boehner (R-OH) (R) respond to U.S. President Barack Obama's remarks on the U.S. economy June 8, 2012 in Washington, DC. During their remarks, Cantor said, 'Did he see the job numbers that came out last week? The private sector is not doing fine. And, frankly, I'd ask the president to stop engaging in the blame game.' (Photo by Win McNamee/Getty Images)

  • House Leader Boehner And Cantor Respond To Obama's Economic News Conference

    WASHINGTON, DC - JUNE 08: U.S. Speaker of the House John Boehner (R-OH) arrives to respond to U.S. President Barack Obama's remarks on the U.S. economy June 8, 2012 in Washington, DC. During remarks with House Majority Leader Eric Cantor, Cantor said, 'Did he see the job numbers that came out last week? The private sector is not doing fine. And, frankly, I'd ask the president to stop engaging in the blame game.' (Photo by Win McNamee/Getty Images)

  • House Leader Boehner And Cantor Respond To Obama's Economic News Conference

    WASHINGTON, DC - JUNE 08: House Majority Leader Eric Cantor (R-VA) (L) and U.S. Speaker of the House John Boehner (R-OH) (R) respond to U.S. President Barack Obama's remarks on the U.S. economy June 8, 2012 in Washington, DC. During their remarks, Cantor said, 'Did he see the job numbers that came out last week? The private sector is not doing fine. And, frankly, I'd ask the president to stop engaging in the blame game.' (Photo by Win McNamee/Getty Images)

  • House Leader Boehner And Cantor Respond To Obama's Economic News Conference

    WASHINGTON, DC - JUNE 08: U.S. Speaker of the House John Boehner (R-OH) (R) and House Majoirty Leader Eric Cantor (R-VA) (L) respond to U.S. President Barack Obama's remarks on the U.S. economy June 8, 2012 in Washington, DC. During Cantor's remarks, Cantor said, 'Did he see the job numbers that came out last week? The private sector is not doing fine. And, frankly, I'd ask the president to stop engaging in the blame game.' (Photo by Win McNamee/Getty Images)