Afghanistan’s Taliban has condemned the massacre of children in a school in the northern Pakistani city of Peshawar by that country’s main Taliban group, which left 148 people dead, mostly children.

“The Afghan Taliban expresses its sorrow over the tragedy and grief for the families of the victims,” the group’s official spokesman Zabihullah Mujahid said in a statement late Tuesday.

“The intentional killing of innocent people, children and women is against the basics of Islam and this criteria has to be considered by every Islamic party and government,” it said.

The Afghan Taliban, the statement added, has “always condemned the killing of innocent people and children” such as the suicide attack during a game of volleyball in the Afghan province of Paktika in November, in which 61 civilians died but which was not claimed by any Afghan group.

Nonetheless, Afghan insurgents usually target public places and cause huge civilian casualties.

The main Taliban group in Pakistan, Tehrik—e—Taliban Pakistan (TTP). claimed responsibility for the school attack and justified it by saying “the army targets our families” in operations against insurgents in the tribal areas of North Waziristan and Khyber.

The TTP, created in 2007, brings together diverse groups and Pakistani tribes and, in theory, is linked to the Afghan Taliban.

The Afghanistan Taliban joined the international community in denouncing Tuesday’s attack on the army—run school which claimed the lives of 132 children.

US President Barack Obama called it a “heinous attack” and reiterated the US commitment to combat terrorism and extremism.

Leaders of neighbouring countries such as India’s Prime Minister Narendra Modi, and Afghanistan’s President Ashraf Ghani, the UN’s resident coordinator in Pakistan Timo Pakkala, and human rights organisations such as Amnesty International have also strongly condemned the massacre.