MI5 reportedly opened a file on Labour leader Jeremy Corbyn amid concerns over his willingness to enter into dialogue with members of the IRA.

The security agency is believed to routinely keep files on people of interest, including political activists and campaigners. Archived documents have revealed Mr Corbyn attended several events supporting the militant Republicans during the 1980s and 1990s.

An unnamed source reportedly told The Telegraph: “If there was a file on someone, it meant they had come to notice. We opened a temporary file and did a preliminary investigation. It was then decided whether we should open a permanent file on them.”

A spokesman for the Home Office said they could neither confirm nor deny who M15 kept files on in the interests of national security.

The Metropolitan Police’s Special Branch reportedly monitored Mr Corbyn at around the same time because of his involvement with anti-racist groups, but it is unclear whether intelligence was shared between the organisations. The MI5 file is reported to have been opened "by the early 1990s".

A spokesman for Mr Corbyn said: “M15 kept files on many peace and Labour movement campaigners at the time, including anti-Apartheid activists and trade unionists.”

M15 has previously come under fire from privacy organisations for keeping files on leading left-wing historians and academics, including Eric Hobsbawm and Christopher Hill, who were both once members of the Communist Party.

Nobel prize-winning author Doris Lessing was also spied on by the security service for 20 years – long after she had abandoned her youthful interest in communism.

At the height of the troubles, Mr Corbyn was a backbench MP for Islington North and appeared at a number of Republican protest events, along with his long-time friend, the now Shadow Chancellor John McDonnell.

Mr Corbyn was arrested in 1986 for joining a protest outside the Old Bailey intended to show solidarity with members of the IRA including Patrick Magee, who was later convicted of the Brighton bombing.

The Labour leader was criticised by families of IRA last year after he failed to explicitly condemn the group during a telephone interview with BBC Radio Ulster.

When asked if he condemned the IRA, he replied: “I condemn all bombing, it is not a good idea, and it is terrible what happened.”

But supporters of the veteran left-winger have said his relationship with Republicans should be viewed in the context of the successful peace talks which followed.

He consistently called for a peace process while maintaining his support for a united Ireland throughout his backbench career. Shortly after he entered Parliament in 1983, he said the large Irish population in his constituency had voted for him to be their MP “with a clear 'Troops Out' ticket".

Former Home Office minister Chris Mullin has described Mr Corbyn as being “ahead of his time” because of his willingness to hold dialogue with Republicans when few other politicians would dare to do so for fear of upsetting popular opinion on the UK mainland.

A spokesman for Mr Corbyn told The Telegraph: “Jeremy campaigned for peace in Northern Ireland. To do so, he campaigned for the rights of all to be respected and spoke to people on all sides of the conflict.

”Jeremy campaigned for fair trials and against miscarriages of justice, after a series of well publicised cases, such as the Guildford Four and the Birmingham Six.“