Doctors across the country described their dismay as their computers suddenly stopped working on Friday.
Doctors across the country described their dismay as their computers suddenly stopped working on Friday, leaving them with no access to patients' x-rays, blood test results or medical histories.
Dozens of state-run National Health Service (NHS) hospitals were hit, many closing their doors to emergency cases and cancelling routine appointments and surgery.
They were among many victims of an indiscriminate global attack that has struck hundreds of thousands of computers worldwide by exploiting known vulnerabilities in older Microsoft computer operating systems.
European car factories and Russian banks were also affected by the attack, which blocks computers and threatens to delete the locked files unless a ransom is paid.
But with their eyes on the June 8 general election, Britain's opposition parties accused Prime Minister Theresa May's Conservative government of failing to ensure the NHS is properly protected.
Many of the almost 8,000 doctors' surgeries in England were also affected, warning of delays as doctors reverted to paper records and appointments.
Several hospitals were still facing disruptions on Monday, with St Bartholomew's in London cancelling appointments and warning of delays to pathology and diagnostic services.
At the hospital on Friday, patient Patrick Ward had been shaved and had his catheter fitted ready for a long-awaited heart operation when the attack happened.
"I was all ready to go, then at 1.30 pm the surgeon turned up and said there's nothing we can do," he told the BBC, citing concerns that if he needed a transfusion, doctors would not be able to accurately match his blood type.
At a hospital in Norfolk, eastern England, staff were told on Monday they could still only view x-rays in one room, while pharmacy services were being restricted as computer systems were upgraded.
The main opposition Labour party accused ministers of ignoring the growing threat of so-called ransomware attacks, saying that 79 English health organisations had suffered such attacks since June 2015.
Labour leader Jeremy Corbyn blamed a lack of funding for the NHS, which has a projected budget of £123.6 billion this year, telling a nurses' conference on Monday: "Tory cuts have exposed patient services to cyberattacks."
The smaller Liberal Democrats party highlighted the government's decision in 2015 not to extend a technical support deal with Microsoft for Windows XP systems, saying it had left Britain "defenceless".
However, on a campaign visit to Oxfordshire in southern England Monday, May pointed to a £1.9 billion investment in cyber security across government promised last year.
"We take cyber security seriously," she said, while highlighting the international nature of the attack.
"This is not something that focused on attacking the NHS here on the UK."
The government held an emergency ministerial meeting on Saturday and was due to meet again on Monday.
May previously said there was no evidence that patient data had been compromised.
May's official spokesman noted that the annual IT budget in the NHS was £4.2 billion, and an extra £50 million had been allocated to update cyber security.
However, the National Audit Office, the spending watchdog, warned last November that capital funds, including for IT, were being diverted to cover a shortfall in day-to-day running costs.
Saif Abed, a doctor and expert in health IT systems, said the attack would be a wake-up call.
"Of course there is an element of technical failure. But that's only a relatively small part of the problem," he told AFP.
"IT directors are underfunded and have so many projects to deal with take the NHS from being paper to digital, they can't keep up with all the tasks they have.
"Cyber security hasn't been top of the agenda. We've been saying for some time that maybe it would take some kind of major incident to move it up."