Police have identified the second assailant who attacked a church in northern France this week as a 19-year-old known to security services as suspected of having "Islamist militant" links, sources say.

Police on Thursday identified the man as Abdel-Malik Nabil Petitjean from a town in eastern France on the border with Germany, a judicial source told Reuters news agency.

Security services had in June opened a special file on Petitjean for becoming radicalised, a police source said separately.

The government has said there are about 10,500 such people in France.

Petitjean and an already identified accomplice, Adel Kermiche, took hostages at a church in Normandy on Tuesday before slitting the throat of an elderly priest at the altar.

Kermiche, also 19, had been awaiting trial on "terror" charges and had been fitted with an electronic tag despite calls from the prosecutor for him not to be released.

ISIL releases video

The Islamic State of Iraq and the Levant (ISIL, also known as ISIS) released on Wednesday a video that purportedly shows the two men pledging allegiance to the group, which is led by Abu Bakr al-Baghdadi and operates in parts of Syria and Iraq.

The footage, which was posted on Wednesday on the ISIL-linked website Amaq, appears to show two young men naming themselves as "Abu Omar" and "Abu Jalil al-Hanafi" and reciting a pledge of allegiance to Baghdadi.

READ MORE: ISIL releases video of 'French church attackers'

Al Jazeera's Natacha Butler, reporting from Paris, said the assailants entered the church during a morning service.

"There were worshippers there; there were nuns; and they took those people hostage, including that priest who was killed. One of the nuns managed to escape, French radio reported, and it was that person who raised the alarm and called the police," she said.

"Special forces arrived shortly after and the hostage-takers were killed when they tried to leave the church."

On high alert

The Normandy attack came as France was on high alert after the attack in Nice earlier this month which killed 84 people and a string of deadly attacks last year claimed by ISIL.

The country is in a state of emergency and has boosted visible police presence.

The security measures have been extended four times since assailants, who pledged allegiance to ISIL, struck Paris in November, killing 130 people at restaurants, a concert hall and the national stadium.

The Nice attack has touched off a bitter political spat over alleged security failings, with the government accused of not doing enough to protect the population.

France boosts regional security after ISIL-claimed church attack

Source: Al Jazeera and agencies