Taliban insurgents have killed six people in an attack on a foreign logistics and supply company in Kabul, the latest in a string of assaults on the Afghan capital.

In an emailed statement a Taliban spokesman claimed responsibility for the attack, confirming its fighters had entered "an important foreign base and logistics warehouse".

Kabul police chief General Ayoub Salangi said four Nepalese guards and two truck drivers working for the company were killed in the attack.

Insurgents drove an explosives-laden truck into a vehicle bay in the compound north of Kabul airport, detonating an explosion that left a crater six metres deep and about 15 metres wide.

"It made a hole the size of a pool," Mr Salangi said.

According to Mr Salangi three other attackers then engaged in a gunfight with Afghan security forces for up to an hour before they were killed.

A witness said he saw the bodies of two people being carried away, although it was unclear whether they were those of the attackers or of other victims.

Atiqullah, a 54-year-old truck driver for the company, said at least four co-workers had been wounded in the attack.

"I woke up to go for morning prayer and suddenly there was a very heavy explosion followed by gunfire," Atiqullah said.

"We escaped from the compound and went to another company nearby.

"Security forces came in 30 minutes and rescued us."

The attack came a week after Taliban fighters penetrated the most secure area of Kabul and attacked buildings in an area that includes Afghan president Hamid Karza's palace.

Violence has been escalating across Afghanistan, as NATO-led combat troops prepare to leave by the end of 2014.

Reuters