John Walker Lindh’s eyes, dark and wild, were ubiquitous across magazine covers and cable news channels, alongside militants in Afghanistan, after he was captured in November 2001. He was a long-haired guerrilla with a California address — a traitor to some, a misguided kid sucked into Islamic jihad to others.

Dubbed the “American Taliban,” Lindh was sentenced to 20 years in prison after pleading guilty to supporting militants who harbored al-Qaeda as it planned the attacks of Sept. 11, 2001. But in a surprise move, Lindh will be released from federal prison on Thursday, three years early.

Lindh and other incarcerated American supporters of the Islamic State present a quandary with growing urgency: Is the United States prepared to try to rehabilitate extremists and foreign fighters, and welcome them back into society?