Brazilian President Dilma Rousseff on Tuesday delivered a stinging rebuke of electronic espionage by the U.S. National Security Agency, telling the U.N. General Assembly that American eavesdropping constitutes "a breach of international law and an affront" to Brazil's sovereignty.

America's spying efforts pose a threat to democracy throughout the world, Rousseff said, as she proposed that the United Nations establish legal guidelines to prevent "cyberspace from being used as a weapon of war."

"Without the right of privacy, there is no real freedom of speech or freedom of opinion, and so there is no actual democracy," Rousseff said. And "without respect for (a nation's) sovereignty, there is no basis for proper relations among nations."

Rousseff said that her government has filed a formal protest against the U.S., demanding an apology and a "guarantee that such acts will not be repeated."

"Those who want a strategic partnership cannot possibly allow recurring and illegal actions to go on as if they were an ordinary practice," she said. Rousseff also dismissed as "untenable" Washington's contention that the U.S. needed to monitor electronic communications as part of its global campaign to fight terrorism. "Brazil knows how to protect itself," she said. "Brazil . . . does not provide shelter to terrorist groups."