The malicious software behind the onslaught appeared to exploit a vulnerability in Microsoft Windows that was supposedly identified by the National Security Agency for its own intelligence-gathering purposes and was later leaked to the internet.

The attack gained attention from media largely after it impacted National Health Service operations in England.

Russian Federation appeared to be the hardest hit, according to security experts, with the country’s Interior Ministry confirming it was struck.

Among the companies targeted was US -based FedEx.

“Like many other companies, FedEx is experiencing interference with some of our Windows-based systems caused by malware. We regret any inconvenience to our customers”. In the town of Blackpool, doctors had resorted to pen and paper, with phone and computer systems having shut down.

Hospitals across England cancelled appointments and turned away patients Friday after suffering an apparent cyberattack. Some chemotherapy patients were even sent home because their records could not be accessed.

The problem also affected the switchboard at Newham University Hospital, Barts said. Later on Friday, Portugal reported a similar attack. The user is asked to pay a ransom to unlock the computer. “A number of countries and organizations have been affected”.

“The National Cyber Security Centre is working closely with NHS digital to ensure that they support the organisations concerned and that they protect patient safety”.

£415,000), saying: “Ooops, your files have been encrypted!”

Alan Woodward, visiting professor of computing at the University of Surrey, said there was evidence the ransomware was spreading using a Microsoft flaw exposed in a recent leak of information from US intelligence agencies. He said companies can apply the patch released in March to all systems to prevent WannaCry infections.

It demands payment in three days or the price is doubled, and if none is received in seven days the files will be deleted.

It said the attack did not specifically target the NHS.

“Today our engineers added detection and protection against new malicious software known as Ransom:Win32.WannaCrypt”, Microsoft said in a statement.

Companies including USA delivery company FedEx and the Spanish telco Telefonica were also affected.

Authorities in Britain have been braced for cyber attacks in the run-up to the vote, as happened during last year’s US election and on the eve of the French vote.

Bart’s Health, which runs several London hospitals, said it had activated its major incident plan, cancelling routine appointments and diverting ambulances to neighboring hospitals.

Patrick Ward, a 47-year-old sales director, said his heart operation, scheduled for Friday, was canceled at St. Bartholomew’s Hospital in London. “They can’t do it now, because of all this”, he said. “It’s stressful enough for someone going through recovery or treatment for cancer”.

A huge extortion cyber attack hit dozens of nations.

Britain’s National Cyber Security Centre and its National Crime Agency were looking into the United Kingdom incidents.

A cyber attack which hit Britain’s National Health Service (NHS) was declared as a major incident Friday night, with British Prime Minister Theresa May saying it was an global attack.

An alleged hacker unconnected to the incident told Sky News the attack could spread to almost every country in the world. In February 2016, a Los Angeles hospital, the Hollywood Presbyterian Medical Center, paid $17,000 in Bitcoin to hackers who took control of its computers for more than a week. As the disruptions rippled through hospitals, doctors’ offices and ambulance companies across Britain on Friday, the health service declared the attack as a “major incident”, a warning that local health services could be overwhelmed by patients.

An NHS sign is seen at St Thomas’ Hospital in central London, Britain May 12, 2017. Other services soon went down, and then, the unidentified NHS worker says, a “bitcoin virus pop-up message” started taking over computer screens. “That was a shock”.