Image copyright Pacemaker Image caption Fred Scappaticci denies he was an Army agent within the IRA

The British spy Stakeknife - described by an Army general as "our golden egg" - is now the subject of a £35m criminal inquiry called Operation Kenova.

The inquiry has been triggered by a classified report which Northern Ireland's Director of Public Prosecutions Barra McGrory QC has told Panorama "made for very disturbing and chilling reading".

What Stakeknife actually did has been wreathed in speculation since he was identified in 2003 as Belfast bricklayer Freddie Scappaticci.

The one stand-out fact, however, has not been in doubt: for over a decade Scappaticci maintained his cover in the IRA by interrogating fellow British agents to the point where they confessed and were then shot.

One British spy was preparing other British spies for execution.

And there were a lot of executions: 30 shot as spies by the IRA's so-called Nutting Squad which, I am told, Scappaticci eventually came to head.

Panorama has learned that Scappaticci is linked to at least 18 of those "executions".

'Draconian injunction'

Not all the victims would have been registered agents like him who produced the best intelligence.

Some were akin to "informers" - people with close access to IRA members, or who passed on what they saw and heard to the security forces.

A few were innocent of the IRA's charge of spying.

Still, the spectacle of one British agent heading an IRA unit dedicated to rooting out and shooting other British spies is so extraordinary that I've often wondered how exactly the state benefitted by the intelligence services having tolerated this for the whole of the 1980s.

The obvious person to ask is Scappaticci himself - but a draconian injunction stops journalists from approaching him, even to the point of making any enquiries about where he now lives or what he does.

Image caption Jon Boutcher (left), chief constable of Bedfordshire Police, is leading Operation Kenova, with the authority of PSNI Chief Constable George Hamilton

Scappaticci was recruited by a section within military intelligence called the Force Research Unit, or FRU.

I'm told the Army have assessed his intelligence as having saved some 180 lives.

Can Scappaticci's intelligence have been so valuable that the sacrifice of other agents was a price worth paying to maintain his cover?

It's not quite that simple.

Had the cavalry been sent in every time Scappaticci tipped off his handlers about who was at risk, he himself wouldn't have lasted long.

Yet protecting him also meant the murders he knew about - or was even involved in - were never properly investigated, driving a "coach and horses" through the criminal justice system, according to Mr McGrory.

Image caption Barra McGrory said the report made for "disturbing and chilling reading"

Also, the Army's assessment that Stakeknife saved 180 lives doesn't translate to the number of actual lives saved as a direct consequence of actioning Stakeknife's intelligence by, for example, interdicting an IRA unit on active service.

I understand that figure of 180 is partly the army's guesstimate of lives that would have been lost had Stakeknife's intelligence not led to arrests and the recovery of weapons.

Of course Stakeknife also contributed significantly to "building a picture" of the IRA, an insight much valued by the intelligence services.

An ex-FRU operative with access to his intelligence told me: "He knew all of the main players and picked up a tremendous amount of peripheral information.

"As the [IRA] campaign changed and the political side became more important again he was highly placed to comment on that."

'Cunning and resilience'

No doubt, but it's hard to quantify "picture building" in terms of actual lives saved.

One thing is for sure: leading a double life at the heart of an IRA unit with a Gestapo-like hold over its rank and file would have required cunning - and resilience.

Especially since Scappaticci told his army handlers he disliked gratuitous violence.

He seems to have managed the violence bit though, even when it was close to home.

I'm told that in January 1988, Scappaticci sent a young boy up to the home of Anthony McKiernan, asking him to call by to see Scappaticci.

The Scappaticcis and McKiernans were friends - children from both families had sleepovers.

That was the last McKiernan's wife and children saw of him. Accused by Scappaticci's Nutting Squad of being a spy - something the family strongly deny - some 24 hours later, he was shot in the head.

Bond films

Unsurprisingly, Scappaticci's ex-IRA comrades paint a less flattering picture than his handlers.

They say he was a prodigious consumer of pornography, loved James Bond movies and - although he was on the IRA's Belfast Brigade staff - was never a "true republican."

That might explain why, after Scappaticci was released from detention without trial in December 1975, he drifted away from the republican movement and got involved in a building trade VAT scam.

There were family holidays in Florida.

But then he was arrested by the police and agreed to work for the fraud squad as an informer.

His former IRA comrades also speak of a man with an intimidating manner, handy with his fists and a large ego who liked to be at the centre of things.

His appointment to the IRA's Nutting Squad - a job most IRA members ran a mile from - certainly gave him that opportunity.

It provided Scappaticci with unrivalled access to what the IRA high command were thinking and their war plans.

Image caption Mr Scappaticci left Northern Ireland when identified by the media as Stakeknife, in 2003

It also gave him access to the names of new IRA recruits on the pretext of vetting them, plus details of IRA operations on the pretext of debriefing IRA members released from police custody to establish whether they gave away too much to their interrogators.

That explains why military intelligence was so eager to recruit Scappaticci when, in September 1979, he graduated to the FRU from spying for the fraud squad.

He got an agent number - 6126 - and a codename. Stakeknife.

His luck ran out in January 1990 after police agent Sandy Lynch was rescued from the clutches of the nutting squad.

The police thought Lynch was about to be shot, Scappaticci having got him to confess. The ordinary CID who did not know Scappaticci was a spy found a thumb print in the house where Lynch had been held.

Scappaticci fled to Dublin. However, a senior police officer who was in the know advised the FRU to get Scappaticci to concoct an alibi for his thumbprint.

It worked. On his return to Belfast in the autumn of 1992, Scappaticci was arrested and then released without charge.

Sidelined

His handlers hoped he could return to spying. But by now the IRA were suspicious and removed him from the security unit.

With Scappaticci's access to IRA secrets gone, the FRU formally stood him down as an agent in 1995.

How did he escape the same treatment at the hands of the IRA that he had helped mete out to others?

Probably because the sight of his body dumped on a roadside would have provoked a slew of questions about those IRA leaders who appointed him to protect the IRA from spies like him - and who also ignored warnings from their more sceptical comrades along the border that "Scap" was not to be trusted.

That did not stop the IRA in Belfast from putting Scap in his place.

After being sidelined, he agreed to help the staunchly republican Braniff family clear the name of a brother, Anthony, who was shot as a spy in 1981. He was eventually exonerated by the IRA.

But when Scappaticci spoke up for Anthony at a private meeting of republicans, to his embarrassment, the IRA's most senior man in Belfast, Sean "Spike" Murray suddenly appeared and slapped him down.

When Scap was eventually outed as Stakeknife by a former FRU operative in 2003, he was spirited to England where MI5 told him the IRA knew he had been a spy.

Stakeknife's gamble

He rejected MI5's offer of protective custody, flew straight back to Belfast and sought a meeting with the IRA.

He gambled on not being shot because he calculated the IRA now had every reason to support a denial that he was a spy - even though he knew they didn't believe him.

His gamble was based on the fact that the IRA's political wing Sinn Fein were now engaged in the peace process.

Scappaticci calculated that were the IRA to admit they'd long suspected he was a spy, it would undermine the official line that they'd fought the British to an honourable draw.

Any such admission would provoke the rank and file into questioning whether the IRA had been pushed into peace, paralysed by the penetration of agents like him.

His gamble paid off.

After meeting two of the most senior representatives of the IRA leadership, Martin "Duckster" Lynch and Padraic Wilson, I'm told Scappaticci and the IRA came to an understanding: Scappaticci would issue a firm denial which the IRA would not contest.

To this day, that's been the IRA's official position - even though, as they say in Belfast, the dogs in the street know it's nonsense.

Once again, Agent 6126 had relied on his wits and native cunning.

Whether the 71-year-old Scappaticci now outwits the 50 detectives trawling over everything he did, what his handlers allowed him to do, and what the IRA leaders authorised him to do, is another question.

You might say he's the spy who knows too much - because he knows the answers to all these questions.

Panorama is broadcast on Tuesday night and can be watched online after broadcast