CHICAGO (CBS) — A 21-year-old Bolingbrook man who pleaded guilty to trying to join ISIS has been sentenced to 3 years, 4 months in prison — but he is expected to be freed in time to enroll in college next fall.

Mohammed Hamzah Khan had been arrested two years ago at O’Hare on the verge of leaving the country to join ISIS.

READ MORE: 'I Had Fear': What Some In Chicago Are Saying After Receiving The Johnson & Johnson COVID Shot Before It Was Pulled

His cooperation with the government led to a sentence of just under 3 ½ years.  And with time served, that means he’ll be freed next year.

The judge ordered Khan under supervised release for 20 years — seen by observers as an uncommonly long time.

READ MORE: Chicago Police Officer Injured During Traffic Stop In Dunning

Outside court, his father, Shafi Khan, was thankful his son will at least be free soon.

“We are thankful to the judge, to the FBI and the government, what they decided for our son and his future. And we thank God that the judgment has come out,” he said.

At the end of the sentencing hearing, the judge told Khan: “I hope you appreciate what happened in this case…  You, who profess to regard this country as your enemy: Here you have not been treated as an enemy.”

MORE NEWS: Woman Shot In Hand In Broad Daylight In Irving Park