The officer was the highest-ranking member of the American military to die in hostilities in the Afghanistan war.