Afghanistan National Army soldiers stand guard at a gate of Camp Qargha, west of Kabul, after the shooting incident. Credit:AP "The wounded German general, whose life is no longer in danger, is being given medical treatment," it said. Seven other Americans and five British troops were among the wounded, according to the Afghan official. The Afghan President Hamid Karzai was quick to condemn the attack, saying the delegation had been visiting the facility to help build Afghanistan's security forces. "Today at 12pm, a terrorist in army uniform opened fire on international partners and other Afghan officers, wounding several," an Afghan Ministry of Defence statement said.

Shooting: NATO vehicles leave Camp Qargha on Tuesday. Credit:AP "Three of our officers have been injured. ISAF (International Security Assistance Force) troops have also suffered casualties," General Mohammmad Zahir Azimi, a spokesman for Afghanistan's Defence Ministry said. "ISAF have quarantined the site, allowing nobody including Afghan forces to approach." NATO's ISAF said in a statement: "We can confirm that an incident occurred involving local Afghan and ISAF troops at Camp Qargha." Attacked: Camp Qargha is known as "Sandhurst in the sand" as British forces oversaw building the officer school. Credit:AFP In its statement, NATO said it was "in the process of assessing the situation".

The gunman was using a light machinegun, according to a US official. Such attacks have eroded trust between the allies and complicated efforts to train Afghanistan's 350,000-strong security force. The Taliban says insider attacks reflect their ability to infiltrate the enemy, while ISAF officials say the incidents often arise over misunderstandings or altercations between troops. In 2012, dozens of incidents forced international troops to take measures to reduce interaction with their Afghan partners and since then, the number of insider attacks has fallen sharply. In a similar attack on Tuesday, several were wounded in eastern Paktia province when a policeman opened fire on international and Afghan forces, police chief Zalmay Oryakhil said.

Qargha is known as "Sandhurst in the sand," as British forces oversaw building the officer school and its training program. In a statement, the British Defence Ministry said it was investigating the incident and that "it would be inappropriate to comment further at this time." The attack comes as so-called "insider attacks" – incidents in which Afghan security turn on their NATO partners – largely dropped last year. In 2013, there were 16 deaths in 10 separate attacks. In 2012, such attacks killed 53 coalition troops in 38 separate attacks. Such "insider attacks" are sometimes claimed by the Taliban insurgency as proof of their infiltration. Others are attributed to personal disputes or resentment by Afghans who have soured on the continued international presence in their country more than a dozen years after the fall of the Taliban's ultra-conservative Islamic regime. Foreign aid workers, contractors and other civilians in Afghanistan are increasingly becoming targets of violence as the US-led military coalition continues a withdrawal to be completed by the end of the year. In eastern Paktia province, an Afghan police guard also exchanged fire on Tuesday with NATO troops near the governor's office, provincial police chief General Zelmia Oryakhail said. The guard was killed in the gunfight, he said. It wasn't clear if the two incidents were linked and police said they were investigating the incident.

Meanwhile, a NATO helicopter strike targeting missile-launching Taliban militants killed four civilians in western Afghanistan, an Afghan official said on Tuesday. NATO said they were investigating the attack. The attack in western Herat province comes as civilian casualties from NATO attacks remain a contentious issue across the country. Almost 200 people protested against NATO in Herat on Tuesday, carrying the bodies of the dead civilians into the provincial capital and demanding an investigation. The strike happened on Monday night in the province's Shindan district, said Raouf Ahmadi, a spokesman for the provincial chief of police. He said Taliban militants launched a missile at an airport nearby, drawing the NATO helicopter's fire. He said the NATO attack killed two men, one woman and a child. "We strongly condemn the killings by foreign troops and we have reported this to the presidential palace," Deputy Provincial Governor, Aseeluddin Jameh, said. "The family was coming back from a wedding in Shindand district when they were hit."

In a statement, NATO said it was aware of the attack and was investigating, without elaborating. NATO "takes all allegations of civilian casualties seriously, and is assessing the facts surrounding this incident," it said. Civilians increasingly find themselves under fire as the 2001 US-led war draws to a close, as Afghan forces take the lead in operations targeting the Taliban. The civilian death toll in the war in Afghanistan rose 17 per cent for the first half of this year, the United Nations reported in July. The UN said 1564 civilians were killed from January through June, compared with 1342 in the first six months of 2013. Insurgents were responsible for 74 per cent of the casualties, the UN said, while pro-government forces were responsible for 9 per cent, government forces 8 per cent and foreign troops just 1 per cent. The rest could not be attributed to any group. Outgoing President Hamid Karzai has repeatedly clashed with NATO over civilian casualties.

Afghan security forces also increasingly find themselves under attack as the planned foreign troop withdrawal draws near. On Tuesday, a police car struck a roadside bomb in the eastern province of Nouristan, killing three officers, provincial police chief Abdul Baqi Nouristani said. Two other roadside bombs in northern Sari Pul province killed three people, including a district police chief and his driver, deputy provincial police chief Sakhi Dad Haidary said. AP, AFP, Reuters