Authorities in Azerbaijan, a former Soviet republic bordering Iran, have arrested two men suspected of plotting to attack prominent foreigners including Israel's ambassador and a local rabbi, officials and media reported.
The National Security Ministry said the men were connected to an Iranian citizen who had links with Iran's intelligence.
Azerbaijan, a secular Muslim country, is home to more than 9,000 Jews and has friendly ties with Israel and the United States. A major energy producer, it exports oil to Israel and imports weapons and military hardware.
"Citizens of Azerbaijan - Rasim Aliyev and Ali Huseynov - were preparing an attack on public figures, who are foreign citizens," the National Security Ministry said in a statement.
The U.S. embassy issued a warning to its citizens saying "the possibility remains for actions against U.S. or other high-profile foreign interests in Azerbaijan".
The announcement came after several state websites in Azerbaijan were rendered inaccessible for hours this month by hackers who left threats and anti-Israel messages. That incident coincided with similar cyber attacks in Israel.
The ministry said the Iranian citizen, identified as Balagardash Dadashev, had helped the two buy weapons including sniper rifles, handguns and explosive devices in Iran and smuggle them to Azerbaijan.
Azeri media reported the suspects had been due to receive $150,000 and their targets included the Israeli ambassador and a local rabbi. The Israeli embassy said it was "operating as usual" and declined further comment.
On Jan. 16, hackers calling themselves the Azerian Cyber Army posted images of the devil over photographs of the Azeri and Israeli presidents, as well as messages saying "Servants of Jews" and "Enemies of Islam."
The same day, hackers disrupted online access to the Tel Aviv Stock Exchange, El Al Airlines and 3 banks in what the government described as a cyber attack against Israel.
Azeri authorities have said they had thwarted a plan by agents of Iran and Hezbollah to set off a car bomb near the Israeli embassy in Baku four years ago, as well as an alleged plot targeting the U.S. and British embassies in 2007.
In what may have been a reference to the plot, Israel's military chief said "we are witnesses to the ongoing attempts by Hezbollah and other hostile entities to execute vicious terror attacks at locations far away from the state of Israel."
Earlier, police in Thailand detained a Lebanese man earlier this month on suspicion of planning an attack. Officials said he had links with Hezbollah, a Shi'ite Islamist group in Lebanon backed by Syria and Iran that is on the U.S. blacklist of foreign terrorist organizations.
Diplomatic ties between Azerbaijan and Iran are cool, but Iranian companies operate and have stakes in oil contracts in the Caspian Sea state, which exports around 1 million barrels of crude a day (bpd) westward through a pipeline operated by a consortium led by BP.