U.S. cybersecurity stocks surged in premarket trading Monday as investors bet that the digital security industry would have the last laugh in the wake of Friday's global cyber ransomware attacks.

FireEye (FEYE - Get Report) , a cyber leader in threat detection, saw its stock jump 7.2% in morning trading, while sector heavyweights Symantec (SYMC - Get Report) and Palo Alto (PANW - Get Report) were up 4.9% and 4.0% respectively.

The PureFunds ISE cybersecurity ETF (HACK - Get Report) was 3.2% higher from Friday's close at $29.74.

Cybersecurity stocks were also active in London trading throughout most of the European session, with Sophos Group (SPHHF  rising more than 6%, bringing the year to date gain for the shares to about 40%.

The London-listed company provides cybersecurity software solutions to small and medium sized businesses as well as public sector organizations.

Among other things, it offers an advanced server protection product which enables client companies to lock down all of their servers with a single click when a security breach has been detected.

Bought by private-equity firm Apax Partners in 2010, Sophos shares have gained more than 50% since they started trading on the London Stock Exchange in June 2015.

Friday's ransomware attack, which shut down vast swathes of Britain's National Health Service and hit multiple corporations across the globe, did much of its work by locking up the files and data held on servers by its victims.

Quite apart from bringing a renewed focus to bear on cybersecurity across the globe, the nature of the attack could prove to be a boon for companies like Sophos who are able to offer products that safeguard servers and other critical infrastructure.

Also in London, NCC Group (NCCGF saw its stock rise by more than 4.4% to change hands at 143 pence each after the opening bell after the fallout from Friday's attack offers a new lease of life to its beleaguered cybersecurity consulting business.

NCC consults on systems design and development for corporate and public sector clients.

The stock saw a torrid start to the year after management were forced to report a number of contract losses and it was revealed that a string of recent acquisitions have led to operational challenges within the group.