"At a press conference we announced readiness to confront cyber attacks against Hormuzgan installations, which was mistakenly reported by the agencies as a cyber attack having been foiled," Ali Akbar Akhavan said.
Earlier on Tuesday, ISNA news agency quoted him as saying: "A virus had penetrated some manufacturing industries in Hormuzgan province, but its progress was halted with ... the cooperation of skilled hackers."
According to ISNA, Akhavan said one of the targets of the latest foiled attack was the Bandar Abbas Tavanir Co, which oversees electricity production and distribution in Hormuzgan and adjacent provinces.
He had said the malware was "Stuxnet-like" but did not elaborate and that the attack had occurred over the "past few months."
Stuxnet, tailored specifically to target Iran's uranium enrichment operation, struck Iran in 2010 and reportedly dealt a serious blow to its disputed atomic programme.
Iran has blamed the US and Israel for cyber attacks in the past. In April, it said a voracious virus attack had hit computers running key parts of its oil sector and succeeded in wiping data off official servers.
Tehran is at odds with Washington and its allies which fear Iran's nuclear activity is aimed at developing nuclear weapons. But Iran says its programme is solely for peaceful purposes.
The US and Israel do not rule out military action against the Islamic state if diplomacy fails to stop its controversial nuclear activity.