A Taiwanese company that makes chips for Apple's iPhone is back in full production after being infected with malware at the weekend.
The Taiwan Semiconductor Manufacturing Company (TSMC) had to shut down parts of its factories.
It said the attack had featured a "mutation" of the Wannacry ransomware.
The manufacturing giant denied that it had been hacked and blamed an error during the installation of a new tool that had not been taken offline first.
Chief executive CC Wei told reporters he was "shocked and surprised" that the attack had taken place.
"It's impossible that humans would never make mistakes and we have changed the system to automatically detect [the virus] and such a mistake would never be made again," he told Reuters.
The company did not comment on where the malware may have originated.
TSMC's other clients include Nvidia and Qualcomm. It is often listed as one of the world's largest semiconductor manufacturers.
"The issues suffered by TSMC remind us that any organisation, even those working at the forefront of technology development, can fall victim to malware," said Thomas Nuth, director of product at cyber-security company Nozomi Networks.
"While downtime can be a frustrating inconvenience for most, when it targets the manufacturing process the results can be exceptionally expensive."