The U.S. military said the incident occurred in Farah province, in western Afghanistan, and that the attacker, a member of a village militia known as the Afghan Local Police, was shot and killed.
Military officials declined to identify the branch of service of the two dead Americans, but U.S. special-operations forces are the main mentors of the Afghan Local Police, a force set up to help keep the Taliban from taking over rural communities.
The military said in a statement that the incident was under investigation.
"Insider" shootings -- attacks carried out by Afghan police, soldiers or members of the security apparatus -- have risen sharply this year. Last week alone there were three assaults that killed seven American troops, including six U.S. Marines.
At least two other attacks have taken place this month that were aimed at NATO troops by Afghan allies, but did not involve Western fatalities. The NATO force does not routinely report "insider" shootings that result in injuries rather than deaths.
-- Laura King
Photo: Afghan police check vehicles in Herat, where security has been intensified ahead of Eid al-Fitr, a festival marking the end of Ramadan. Credit: Jalil Rezayee / EPA