Democrat Barack Obama lumped Republican John McCain in with the unpopular Bush administration on Friday for advancing a "naive and irresponsible" foreign policy, attempting to turn the tables in a presidential election battle in which his own national security credentials have been challenged. Obama also hinted that were McCain president, he would continue the policies currently followed by the Bush administration, and added that terror groups like Hamas and Al Qaida have grown because the US under Bush "took ... [the] eye off the ball in Afghanistan." Obama took on McCain a day after accusing President George W. Bush of calling him an appeaser during a trip to Israel by criticizing those who believe in negotiating with "terrorists and radicals." The White House denied the comments were meant for Obama, but McCain took the opportunity to jump into the fray, accusing him of naivety and saying he should explain to voters why he is willing to talk with rogue leaders. Obama has said as president he would be willing to personally meet with leaders from Iran and other regimes the United States has deemed rogue - drawing fire from Republicans and his Democratic rival Hillary Rodham Clinton. Obama's dust-up with the Republicans reflects an increasing shift toward an expected face-off between Obama and McCain in November. But, even as Obama holds what appears to be an insurmountable delegate lead in the Democratic race, Clinton has insisted she is staying in the race until last primary in June. She was campaigning in Oregon on Friday. The issue of national security has been relatively ignored so far in the race, as the weak economy and the protracted Democratic primary battle have taken center stage. But Bush's comments gave McCain, a war veteran and longtime senator, the opportunity to bring the issue back to the forefront, challenging his younger rival's credentials on security. "It would be a wonderful thing if we lived in a world where we don't have enemies. But that's not the world we live in. And until Senator Obama understands that reality, the American people have every reason to doubt whether he has the strength, judgment and determination to keep us safe," McCain said in a speech to the National Rifle Association in Louisville, Kentucky. In return, Obama sounded a campaign theme that a McCain presidency would simply extend Bush policies for four more years, as he lumped the two together. "If they want a debate about protecting the United States of America, that's a debate I'm ready to win because George Bush and John McCain have a lot to answer for," he declared. He blamed Bush for policies that enhance the strength of terrorist groups such as Hamas and said al-Qaida's leadership is stronger "because we took our eye off the ball in Afghanistan." At a rally in South Dakota, he said Bush's and McCain's criticisms were an example of foreign policy marked by "fear-mongering that has prevented us from actually making us safer" and turned a word commonly used against him - "naive" - on his opponent. McCain had a "naive and irresponsible belief that tough talk from Washington will somehow cause Iran to give up its nuclear program and support for terrorism," he said. McCain's campaign issued a statement accusing Obama of a "hysterical diatribe." The Republican also said it would be "reckless" for a US president to meet with leaders such as Iranian President Mahmoud Ahmadinejad. Clinton has also pounced on Obama for saying he would meet with US foes, but she seized on Bush's comments, saying that while she and Obama have differences on foreign policy, "we are united in our opposition to the Bush policies and the continuation of those policies" by McCain. Obama argued that tough-minded diplomacy and engagement with rivals is a bipartisan foreign policy that dates to former presidents, such as Democrat John F. Kennedy and Republicans Richard Nixon and Ronald Reagan. "This whole notion of not talking to people, it didn't hold in the '60s, it didn't hold in the '70s ... When Kennedy met with [Soviet leader Nikita] Khrushchev, we were on the brink of nuclear war," Obama told reporters in South Dakota. He also noted that Nixon opened talks with China with the knowledge that Chinese leader Mao Zedong "had exterminated millions of people." Other Democrats accused McCain of hypocrisy Friday, saying the certain Republican presidential nominee had previously said he would be willing to negotiate with Hamas. McCain told reporters in West Virginia: "I made it very clear, at that time, before and after, that we will not negotiate with terrorist organizations, that Hamas would have to abandon their terrorism, their advocacy to the extermination of the state of Israel, and be willing to negotiate in a way that recognizes the right of the state of Israel and abandons their terrorist position and advocacy." McCain said there was a "huge difference" between his own statements and Obama's willingness to negotiate with "sponsors of terrorist organizations." Republicans increasingly see Obama, a first-term Illinois senator, as the all-but-certain victor in the fierce race for the Democratic nomination. He holds an ever-widening 1,904 to 1,719 delegate lead over Clinton, with 2,026 needed to clinch the nomination at the party convention in August. This week, former presidential candidate John Edwards threw his long sought-after support behind Obama, bringing a new wave of support for the Illinois senator, who gained eight delegates Thursday and six more Friday. With only five state contests remaining, Clinton has no real hope of overtaking Obama through primary wins or even if she secures delegates from Florida and Michigan - states stripped of their delegates because they held primaries too early. Still, on Friday she unveiled three new ads in the upcoming primary states of Oregon and Kentucky.