KABUL (Reuters) - Taliban insurgents ambushed a convoy of Afghan security forces in a mountainous northern area on Monday, killing 22 soldiers and police, an official said, as bombs in Kabul and another area killed three.

U.S. troops remove a damaged vehicle, which was hit by a suicide attack, in Kabul October 13, 2014. REUTERS/Omar Sobhani

The violence comes as the Taliban and their militant allies step up attacks ahead of the withdrawal of most foreign troops at the end of the year, seeking to weaken the new Afghan government that will take over most of the fight.

The Taliban, who ruled Afghanistan with an iron fist from 1996 to 2001, attacked from the mountains as the convoy was travelling through Laghman Valley in Sar-e-Pul province, Gov. Abdul Jabar Haqbeen said.

Eight security forces were wounded and seven were taken captive.

“Twelve army and police vehicles are totally destroyed,” Haqbeen said.

A suicide car bomber rammed a NATO military convoy along a major road out of Afghanistan’s capital, Kabul, early on Monday, killing one Afghan civilian, authorities said.

The Taliban claimed responsibility for the attack on the Jalalabad Road, a main thoroughfare with a U.S. military base and a housing compound for U.N. and other international contractors and aid workers.

At least three foreigners were wounded in the blast targeting their armoured vehicles, but their identities were not known, police said.

A spokesman for the U.S.-led NATO mission in Afghanistan said a patrol was attacked but there were no fatalities among the international force. The force does not confirm injuries.

The bomber in a Toyota Corolla car drove into the convoy just before 7 a.m. (0230 GMT), said Farid Afzali, head of Kabul’s police investigation department.

“As a result of the blast, one of our countrymen was killed and three foreigners slightly wounded,” Afzali said.

Reuters television footage showed the remains of one of the white armoured vehicles, its engine blackened and mangled and side door damaged.

It was the second car-bomb attack on international forces in Kabul in a month.

Taliban spokesman Zabihullah Majahid said on Twitter that the target was a foreign military convoy and several troops were killed. The insurgents, who are fighting to expel foreign forces and re-establish their strict Islamist state driven from power in 2001, often exaggerate the results of their attacks.

In the eastern province of Nangarhar, a suicide bomber detonated his explosives in front of a clinic killing two people and wounding seven, the Ministry of Defence said.

A bomb planted in a crowded market in the Qarabagh district of Kabul wounded 22 civilians and five of them were in critical condition. Four children were among wounded, said district governor Samih Sharifi.

The Taliban took advantage of weeks of political paralysis over a disputed election to regain territory in provinces such as Helmand in the south and Kunduz in the north.

President Ashraf Ghani appealed in his inauguration address late last month for the militants to join peace talks but they denounced his government for signing a security pact with the United States, calling it a “sinister” U.S. plot to control Afghanistan.