Srinagar: A police officer was lynched by a mob late on Thursday after he opened fire on a group of people who caught him clicking pictures near a mosque in Nowhatta area of Srinagar.

The incident reportedly occurred while separatist leader Mirwaiz Umar Farooq was offering prayers at the Jamia Masjid and was to make a speech later.

Deputy SP (Security) Mohammed Ayub Pandith, who was in civilian clothes, was caught clicking pictures outside the mosque, following which the officer opened fire with his service pistol, injuring three people. He was caught by an angry mob outside and beaten to death.

ALSO READ | Don't Test Restraint Shown by Police, Mehbooba Mufti Warns Kashmiris

A PTI report said he was stripped naked before being stoned to death.

"Two persons have been arrested so far and a third has been identified. All of them (involved in lynching of the officer) will face the law," DGP SP Vaid told reporters on sidelines of the wreath laying ceremony of slain officer.

It was not immediately clear why the officer was clicking pictures inside the mosque.

“He was deployed for duty at the mosque where people were to offer prayers and Mirwaiz Umar Farooq was to deliver an address,” a top police officer told CNN-News18.

ALSO READ | Kashmir Mob Lynching: Mufti, Abdullah and Gandhi Condemn in Same Language

The separatist leader, however, denied being present there at the time of the incident. “Media is misrepresenting the facts. I was not at the masjid. I came after 12.”

Calling it a “brutal” act, Mirwaiz tweeted that “state brutality should not snatch our humanity and values”.

Deeply disturbed & condemn the brutal act at Nowhatta.Mob violence & public lynching is outside the parameters of our values & religion.... — Mirwaiz Umar Farooq (@MirwaizKashmir) June 23, 2017

....We cannot allow state brutality to snatch our humanity & values — Mirwaiz Umar Farooq (@MirwaizKashmir) June 23, 2017

Ayub Pandith was reportedly a resident of the area where the mosque is located.

He was laid to rest with full honours later on Friday in the presence of Jammu and Kashmir Chief Minister Mehbooba Mufti. Condoling the officer’s death, the CM said: “For how long will this continue? Jammu and Kashmir police are the best in the country. They show a lot of restraint in dealing with their own people. This is a shameful incident.”

“People should realise that if these incidents continue, then there could come a time when policeman won’t be around to protect you,” Mehbooba Mufti said.

Former chief minister Omar Abdullah called the officer’s death a “travesty”.

His death is a tragedy & the manner of his death a travesty. May the people who lynched DySP Pandith burn in hell for their sins. https://t.co/uuddYdbJYc — Omar Abdullah (@abdullah_omar) June 23, 2017

Congress Vice-President Rahul Gandhi blamed the incident on the "complete failure".

Heartbreaking to see J&K being pushed back several decades because of the complete failure of the PDP/BJP Govt — Office of RG (@OfficeOfRG) June 23, 2017

“This is against our culture and no one can accept this,” Congress leader Ghulam Nabi Azad said.

The incident came as Muslims across Kashmir were observing Laylatul Qadr (the night of power) with night-long prayers and supplications being made inside the mosques and shrines of the Valley.

The authorities announced restrictions on movement of people in seven police station areas of the city as a precautionary measure.

The restrictions, which came into force at dawn, were announced to maintain law and order as separatists had called for protests after Friday prayers against killing of a civilian during protests in Kakapora area of Pulwama District on Thursday.

(With PTI inputs)