This has been misquoted by CNN-this is what he actually said-on CanOFunEditing to add this link to an article -
Iraq Bans CNN due to their mistranslation of remarks<snip>
On Saturday, President Mahmoud Ahmadinejad defended Iran's right to continue nuclear research. State media have complained since the speech that CNN used the translation "nuclear weapons" instead of "nuclear technology."
The ban by the Culture and Islamic Guidance Ministry was read in a statement on state-run television.
"Due to mistranslation of the words of President Mahmoud Ahmadinejad during his press conference, activities of the American CNN in Tehran are banned until further notice," said a statement by the Culture and Islamic Guidance Ministry read on state-run television.
...
(CNN's APOLOGY)
"CNN quoted Mahmoud Ahmadinejad as saying that Iran has the right to build nuclear weapons," the network said in its report of the ban. "In fact he said that Iran has the right to nuclear energy. He added that, quote, a nation that has civilization does not need nuclear weapons and our nation does not need them. CNN has clarified what the Iranian president said and apologized here on the air to the Iranians directly, as well as on the air."