LAHORE, Pakistan — A suicide bomber attacked security forces guarding a famous Sufi shrine in Pakistan’s eastern city of Lahore on Wednesday, killing at least 10 people and wounding 20 others, police said.

Hizbul Ahrar, an offshoot of the Pakistani Taliban, claimed responsibility for the attack, saying their target was the police. Hundreds of pilgrims were inside and outside the shrine, where a local Sufi saint is buried, when the blast took place.

Sufism is a mystical strain of Islam that often involves reverence for local holy figures and shrines. Sunni extremists view Sufism with hostility and have carried out attacks on Sufi celebrations and shrines across the Muslim world. In Pakistan, militants carry out near-daily attacks targeting security forces.

Lahore police chief Ghazanfar Ali said five police and five passers-by were killed in the attack, adding that the toll could rise as some of the wounded were in critical condition.

Chaudhry Mohammad Sarwar, the governor of Punjab province, told reporters that those who carried out Wednesday’s attack were the “enemy of Islam and humanity.”

“God willing, the security forces with the cooperation of whole nation will defeat these terrorists,” he added.

Prime Minister Imran Khan also condemned the bombing.

Pakistanis in large numbers visit the shrine, where a pair of suicide attacks in 2010 killed and wounded dozens of people.

Lahore is the capital of eastern Punjab province, which has seen similar attacks in recent years.