For four U.S. military personnel assigned to the American-led training command in Kabul, Afghanistan, it was supposed to be just another routine visit to the main prison near the Afghan capital.

But as their party started to drive away from the Pol-E-Charki Prison, a place layered with checkpoints and security guards, a soldier with the Afghan National Army raised his weapon and fired into their vehicle.

The Sunday afternoon ambush killed two U.S. servicemembers and injured two others. ANA soldiers who witnessed the attack returned fire, killing their comrade, who was described as “the rogue soldier” by American authorities.

“They oversee operations at the prison,” U.S. Army Maj. Sheldon Smith, spokesman for the Combined Security Transition Command-Afghanistan, said of the Americans. The U.S. military personnel “were there on a routine visit.”

Smith saw the two injured servicemembers Monday morning and said both appeared to be doing fine. They were listed in stable condition.

The identities of the two Americans killed in the ambush were being withheld pending family notification. Their bodies were flown out of Afghanistan shortly after dawn Monday aboard a military aircraft that took off from nearby Bagram Air Base.

On Monday, a spokesman for Afghanistan’s Defense Ministry said the Afghan soldier in the incident was “mentally ill.”

The spokesman, Zahir Azimi, said the soldier had been in the Afghan army for a year and a half and had been hospitalized twice for mental illness.

All of the U.S. personnel in the attack were based out of Camp Eggers, the headquarters for CSTC-A. The U.S.-led command coordinates all of the training activities involving the Afghan army and police, and it has regular dealings with Afghan defense and interior ministries.

Smith described the fallen servicemembers as “guys we see in the gym and chow hall every day. [The killings have] hit close to home for all of us.”

Meanwhile, the two soldiers wounded in the attack were issued Purple Heart medals Monday.

The two deaths mark the first time anyone directly assigned to the training command headquarters has been killed, Smith said.

U.S. Army Brig. Gen. Douglas A. Pritt, who supervises the embed training program for Task Force Phoenix, said Monday six of his trainers have died in combat since he took charge in July.

Afghans who join the army or police are vetted beforehand, though some get longer looks than others, depending on the job. Pritt indicated that Afghans assigned to prominent positions or sensitive locations, such as prisons, face closer scrutiny.

An investigation into the shootings already is under way by U.S. and Afghan officials. If there were lapses, Pritt said, “we need to deal with it.”

Smith added that early indications are the gunman acted alone.

In an interview several days ago, Maj. Gen. Robert Durbin, who heads up CSTC-A, talked about the vetting process. He said investigators access watch lists and reach into a candidate’s past to ensure candidates are trustworthy and not criminals or human rights violators, especially officers and senior leaders.

“For both the army and police, as part of their recruitment, they have to be vouched for by a tribal elder or mullah,” Durbin said.

A memorial service at Camp Eggers was planned for late Monday.

Sign Up for Daily Headlines

Sign-up to receive a daily email of today’s top military news stories from Stars and Stripes and top news outlets from around the world.

Sign up