Saleh made the remarks after meeting with Hassan Rowhani, secretary of Iran's Supreme National Security Council, on bilateral cooperation in the security, economic and cultural matters, it said.
"President Saleh insisted on the right of Iran, and any other state, to acquire nuclear technology and use it for peaceful ends," said the agency.
Saleh also reiterated his country's rejection of any "nuclear weapons or any other kinds of mass destruction arms in the (Middle East) region, chiefly in Israel."
Rowhani, Iran's chief nuclear negotiator in talks with the European Union, is on a regional tour.
In Kuwait on Monday, he urged the United States, which accuses Iran of seeking nuclear weapons under the guise of an energy program, to make a "courageous" first move for reconciliation with Tehran.