Asadullah Khalid, the head of Afghanistan’s intelligence agency, suffered severe abdominal injuries in a suicide attack in Kabul on Dec. 5. According to the State Department, he had been granted entry to the United States in mid-December for medical treatment at the request of Afghan President Hamid Karzai’s administration.

The White House did not publicly announce that Obama had visited Khalid, but Afghan news outlets reported on the brief meeting. And a snapshot purportedly showing Obama standing by Khalid’s bedside — the spy chief wearing splints on his forearms and a bandage on his face — made the rounds on social media.

A leading U.S. human rights organization said it is outraged by the president’s decision to greet Khalid, who has been accused of abuses including torture and drug trafficking even as he distinguished himself as a Karzai ally and anti-Taliban figure in his native Kandahar.

“Even if your administration determined that humanitarian arguments justified his entry for medical treatment, a presidential visit to his bedside . . . was a major misstep,” Kenneth Roth, executive director of Human Rights Watch, wrote Dec. 23 in a letter to Obama, who is scheduled to meet with Karzai at the White House on Friday.