There was no immediate comment on any of the attacks from the Taliban, who have stepped up their assaults across Afghanistan in recent months.

A string of Taliban attacks in western and eastern Afghanistan have left at least 12 people dead, including four women who died in the crossfire during a shootout between insurgents and the military, Afghan officials said on Tuesday.

In western Farah province, the Taliban attacked a military checkpoint, killing four troops and wounding six, according to Mohammad Naser Mehri, the provincial governor’s spokesman.

The attack in Bala Buluk district started late on Monday night and lasted until around dawn on Tuesday. Mr. Mehri said the Afghan air force was called in and airstrikes later killed 19 Taliban fighters and wounded 30.

“The Taliban were pushed back and the situation is under control now,” he added.

In eastern Logar province, four women were killed and four children were wounded in the crossfire during a shootout between insurgents and the military.

The fighting took place near Puli Alim, the provincial capital, on Monday afternoon, said Hasibullah Stanikzai, a provincial council member. He added that “an investigation is underway to determine which side caused the civilian casualties.”

Also on Monday night, the Taliban attacked a police checkpoint in eastern Ghazni province, killing four policemen and wounding five, said Arif Noori, spokesman for the provincial governor. He said the battle in Jaghatu district lasted for three hours.

There was no immediate comment on any of the attacks from the Taliban, who have stepped up their assaults across Afghanistan in recent months.

Separately, the Islamic State group claimed responsibility on Tuesday for an attack that killed an Afghan soldier and wounded three troops and a civilian on Sunday in the eastern city of Jalalabad, the provincial capital of Nangarhar.

Both the Taliban and the local IS affiliate regularly target Afghan security forces. The IS affiliate has also carried out several attacks targeting the country’s Shia minority. On Sunday, IS claimed a suicide attack two days earlier on a mosque in the city of Gardez, south of Kabul. The attack killed at least 29 people and wounded another 81.