It is unusual to see, let alone hear, from Britain’s spymasters in public. But in the past few weeks the UK’s intelligence chiefs have been uncharacteristically outspoken on the threat posed to national security by Huawei, the Chinese telecoms equipment maker.

In speeches and other public appearances, the heads of MI6, the foreign secret service; GCHQ, the government’s communications intelligence hub, and the National Cyber Security Centre have attempted to bring some clarity to the raging debate about Chinese technology, described by Robert Hannigan, a former GCHQ chief, as a “growing hysteria”.

However, while their carefully crafted remarks suggest the UK’s intelligence agencies are slowly forming a settled view on how to deal with Huawei, behind the scenes the spying organisations’ views diverge.

“The intelligence agencies are all agreed that there is a threat,” said one former senior UK intelligence official. “Where I think there is understandable divergence is on the way the threat can be managed and mitigated.”

Their views matter because they are each feeding security advice into a government review of the UK’s telecoms infrastructure, which is due to report in the next few weeks. With the US and other members of the Five Eyes intelligence alliance, such as Australia and New Zealand, adopting a much tougher line on Huawei, the report will also be of international significance.

For now, British intelligence seems to be prepared to take a more measured approach. In a speech in Singapore on Monday, Jeremy Fleming, the GCHQ director, said that the UK had to “understand the opportunities and threats” from Chinese technology but a supplier’s country of origin should not lead to automatic bans.

Drawing on remarks made by Ciaran Martin, the NCSC chief executive, in Brussels a few days earlier, Mr Fleming said all equipment manufacturers would have to meet tougher cyber security standards if they were to play a part in future fifth generation mobile phone networks.

“The NCSC, as part of GCHQ, is the national technical authority for cyber security,” Mr Fleming said, pointedly. “It’s our job to bring objective, evidence-based and technically authoritative advice to the policy table.”

But, while GCHQ and its cyber experts at the NCSC believe they have the technological knowhow to manage any threat to critical future 5G telecoms networks, MI5, Britain’s domestic security service, and military chiefs argue for a more cautious approach when it comes to Huawei. Andrew Parker, the director-general of MI5, is the one spy chief who has so far not given a public view on the Chinese company.

MI6, meanwhile, has been giving mixed messages. In a discussion at St Andrews university in Scotland before Christmas, Alex Younger, the chief of the UK’s foreign intelligence service, appeared to present a different view from GCHQ.

“We need to decide the extent to which we are going to be comfortable with Chinese ownership of these technologies and these platforms in an environment where some of our allies have taken a quite definite position,” he said, referring to Washington’s far tougher stance on Huawei. The US wants allies to bar or block the Chinese company amid concerns over espionage and intellectual property theft.

Since then, Mr Younger has fallen more in line with the GCHQ and NCSC position, telling journalists at the Munich security conference last month that country of origin was not as important as quality when it came to cyber safeguards.

“From the technical side the NCSC might well be right,” said one government official, “but given China’s long-term plans in this area, it doesn’t look good when you consider what some of our closest allies are saying. Even if there is 1 per cent risk, is it a risk worth taking?”

One explanation for the different views comes from the very different tasks the UK’s intelligence services perform and the way technology is upending those roles.

One of MI5’s most important functions is to counter spying conducted by hostile foreign states in Britain. Another is to protect the UK’s critical infrastructure, including telecoms networks, power stations and the financial sector, from terrorist attack or disruption.

Over the past decade GCHQ has evolved from the leading secret listening post, which traditionally gathered communications intelligence, into the British state’s leading actor in cyber space, contributing to a notable shift in the way government intelligence agencies operate and the balance of power between them.

This has inevitably led to a blurring of the lines — with the traditional human intelligence agencies, MI5 and MI6, having to rapidly adapt to the way hostile states and terrorists conduct espionage and disruption campaigns.

“GCHQ has at its beating heart this group of very technical people,” said Anthony Glees, of the University of Buckingham’s Centre for Security and Intelligence Studies. “MI5 has had a number of attempts at developing cyber capabilities but they can’t compete with what GCHQ has.”

Others view the great game playing out over Huawei as a more straightforward matter of geopolitics.

“China has embarked on a major exercise to reshape the planet in accordance with its own interests,” said Nigel Inkster, a former director of MI6 and a senior adviser at the International Institute for Strategic Studies, a security think-tank.

For the UK’s spymasters weighing technological risk with geopolitical strategy, perhaps the bigger question is whether banning Huawei from 5G would actually make any difference to China’s ability to spy in the UK and cause disruption.

“China has managed to conduct effective cyber espionage operations against the UK for a long time without having to rely on Huawei equipment to do it,” said Mr Inkster, adding, ominously: “A 5G network will require a constant stream of software updates and the scope for infected code. The line that Huawei is just a telecommunications company has worn beyond thin.”