KABUL, Afghanistan (NBC News) - U.S. Defense and military officials tell NBC News a U.S. Army Two-Star Major General, was killed Tuesday in an insider attack at an Afghan military training facility near Kabul.

More than a dozen Western soldiers in all -- including several Americans -- were shot in the deadly attack on officials visiting the military complex.

As many as 12 Western soldiers -- including several Americans -- were shot in a deadly attack on high-level officials visiting a military academy Tuesday near Afghanistan's capital.

U.S. officials told NBC News that most, if not all, of the victims were American. They said a lone gunman opened fire at a group that included American officials at the Camp Qargha training facility.

One high-ranking U.S. service member was killed and more than a dozen Western troops were wounded, according to senior U.S. defense officials. The officials said the death toll is expected to rise given the severity of troops' injuries.

Officials earlier had told NBC News that the three Western troops had died but later revised the figure. There was no immediate explanation for the discrepancy, however, death tolls often change in the confusing aftermath of such attacks.

Earlier, a spokesman for the NATO-led International Security Assistance Force confirmed "fatalities" after "a shooting incident involving ISAF and Afghan troops," but could not confirm the number of victims or their nationalities.

Gen. Mohammmad Zahir Azimi, a spokesman for Afghanistan's Defense Ministry, tweeted in Dari that the gunman was wearing an Afghan military uniform and was shot dead after opening fire on Afghan and international colleagues.

Germany's military said in a statement that 15 troops had been wounded in the attack, including a German brigadier general, according to The Associated Press. Those details could not immediately be independently confirmed by NBC News.

The shooting broke out at Camp Qargha, which is located west of Kabul. The camp includes the National Military Academy of Afghanistan, which was reconstructed after the 2001 invasion and whose design is based on West Point.

Qargha, which is overseen by the British military, is sometimes called "Sandhurst in the sand" - a reference to the British military's own officers' training school.

Training Afghanistan's 350,000 strong security forces is a large part of the current NATO-led operation, especially as the U.S.-led coalition prepares to hand over combat operations by the end of 2014.

An Afghan intelligence source told NBC News that a high-level ISAF delegation was visiting and touring the academy when the shooter opened fire from a window. Two senior Afghan officers also were injured in the attack, the source added, speaking on condition of anonymity because he was not authorized to speak to the media.

The U.K. Ministry of Defense said Wednesday that it was aware of reports and that the incident is under investigation.

“It would be inappropriate to comment further at this time,” it added.

NBC News' Cassandra Vinograd and The Associated Press contributed to this report.