The senior Iranian official made the comments in Damascus.
Speaking at a joint press conference with Syrian Prime Minister Muhammad Naji al-Otarii, Rahimi stressed that his country was standing by Syria with all its power.
"Syria is a strong and capable state and it has the ability to withstand any threat," he said, characterizing Israel's threats as "worthless."
"The days where Israel could run wild are long gone," he added. "Israel tasted the taste of failure in the summer of 2006 and in 2009."
Rahimi said the talks he held in Damascus were constructive and added that the two sides held intense contacts in respect to various economic and industrial issues.
Barak, Clinton talk tough
Earlier, Defense Minister Ehud Barak told the American Jewish Committee in Washington that Israel is not interested in escalation, but is following the effort to change the balance of power in the Middle East.
He added that Israel would hold the Lebanese and Syrian governments responsible for the introduction of any "balance-breaking weapons" to Hezbollah.
Speaking at the same venue, Secretary of State Hillary Clinton said Syrian transfers of increasingly sophisticated weaponry, including rockets, to Hezbollah and Hamas could spark new conflict in the Middle East.
"These threats to Israel's security are real, they are growing and they must be addressed," she said.
AP and Yitzhak Benhorin contributed to the report