KABUL, Afghanistan — Seven American soldiers were shot and wounded by an Afghan commando on Saturday, the second such insider attack in a week, according to Afghan officials.

The attack took place in the Afghan National Army 209th Corps headquarters at Camp Shaheen, in the northern city of Mazar-i-Sharif. Col. Abdul Qahar Aram, spokesman for the 209th Corps, said an Afghan soldier had opened fire, wounding foreign soldiers in the garrison area of the camp. He said reports claiming the soldiers had been killed were false.

The United States military would confirm only that American soldiers were wounded in an insider attack that occurred there at about 2 p.m., and that an Afghan soldier had been killed and another wounded. The United States military also denied that any of its soldiers had been killed.

Another Corps spokesman, Maj. Nasratullah Jamshidi, said the attacker, an Afghan commando, had been shot at the scene and died on his way to a hospital.