ISLAMABAD (AP) — Pakistani authorities said Monday they have arrested 22 people involved in the lynching of a university student who was accused of blasphemy and detained a teenage woman who had been recruited by the Islamic State group for a foiled attack on a church.

Word of the arrests came as U.S. President Donald Trump’s national security adviser arrived for talks on combatting militants in South Asia, highlighting Pakistan’s struggle with Islamic extremism.

The 16 students and six university employees are believed to have incited or taken part in the mob that killed 23-year-old Mohammad Mashal Khan, provincial police chief Salahuddin Mehsud said. The student was beaten and shot to death at a university in the northwestern city of Mardan on Thursday.

Mehsud said no evidence has been found to indicate Khan committed blasphemy against Islam, which is punishable by death in Pakistan. The mere suspicion of blasphemy is enough to incite deadly riots in the deeply conservative country.

Pakistan had recently vowed to combat the sharing of blasphemous material on social media, and has tried to enlist Facebook and Twitter in the campaign.

A military spokesman meanwhile said authorities detained a teenage woman earlier this month who had been recruited by the Islamic State group to carry out a suicide attack against a church on Easter.

Noreen Leghari, 19, was detained after a previously reported shootout on April 14, the day before Easter, in which another militant was killed, said Maj. Gen. Asif Ghafoor.

The new details on the raid were released as H.R. McMaster, the U.S. national security adviser, arrived on his first visit since the United States dropped its largest non-nuclear bomb on an Islamic State tunnel complex in neighboring Afghanistan.

McMaster arrived in Islamabad after holding talks in Afghanistan on efforts to combat the Taliban and the IS group’s Afghan affiliate. The U.S. dropped the Massive Ordnance Air Blast bomb, or MOAB, on an Islamic State tunnel complex carved into a mountain in eastern Afghanistan on Thursday, reportedly killing 95 militants.

McMaster met with Prime Minister Nawaz Sharif and other senior officials. Pakistan’s foreign affairs adviser Sartaj Aziz said Islamabad remained committed to working for peace and reconciliation in neighboring Afghanistan, and that officials meeting with McMaster had discussed efforts to secure the border.

The U.S. Embassy said McMaster “expressed appreciation for Pakistan’s democratic and economic development, and stressed the need to confront terrorism in all its forms.”

Pakistan has long sought to downplay the growing presence of Islamic State militants, who have claimed a number of attacks in recent months. Monday’s announcement marked the first time Pakistani officials have acknowledged that the extremist group based in Syria and Iraq is recruiting within the South Asian country.

Pakistan has been struggling to combat the much larger and more well-established Pakistani Taliban, which emerged after the 2001 U.S.-led invasion of Afghanistan and have carried out attacks that have killed tens of thousands of people.

The Islamic State group is believed to have recruited disgruntled Taliban fighters in both Pakistan and Afghanistan with its promise of building a worldwide Islamic caliphate.

Leghari was recruited via Facebook, and went missing in February, later marrying an Islamic State fighter who was killed in the April 14 raid, a Pakistani security official said on condition of anonymity because he was not authorized to brief reporters. He said the woman had fought alongside her husband during the raid and shot at security forces.

Ghafoor suggested she had fallen prey to the group’s online propaganda. He portrayed her detention as a rescue and said “we will rehabilitate her.”

___

Associated Press writers Riaz Khan in Peshawar, Pakistan and Zaheer Babar in Lahore, Pakistan contributed to this report.