The last of Dzhokhar Tsarnaev’s college classmates convicted of trying to derail the FBI’s investigation of the deadly 2013 Boston Marathon bombings is scheduled to leave federal prison today — straight into the custody of the Department of Homeland Security, his lawyer confirmed.

Dias Kadyrbayev, 24, a Kazakhstan national, has spent the past five years behind bars, most recently at the low-security federal institution in Big Spring, Texas.

As part of his 2014 guilty plea to obstruction of justice charges, Kadyrbayev agreed to be deported back to Kazakhstan and waived every right he had to challenge his removal from the United States.

“He did as well as possible,” New Jersey attorney Robert G. Stahl said yesterday of Kadyrbayev’s sentence. “He used his time to improve his English language skills and to take some courses. He’s very anxious to get back home to his parents, siblings and friends. He’s got a great family. It’s been a long time to be in a jail in another country, where your family can only visit you once or twice a year because of the cost of travel.”

Kadyrbayev, Azamat Tazhayakov, 24 and Robel Kidane Phillipos, 24, went to Tsarnaev’s dorm room at the University of Massachusetts Dartmouth three days after the April 15, 2013, terrorist attack and removed his laptop commuter — which was saved — and a backpack, fireworks and jar of Vaseline that were later unearthed from a New Bedford landfill. The trio never gave Tsarnaev up, even as the FBI went public with photos in a desperate effort to identify him and his brother for the bombing deaths of three race spectators, and before they murdered MIT police officer Sean Collier.

Tazhayakov, also of Kazakhstan, was convicted of obstruction of justice in 2014. He returned to his homeland following his 2016 release from prison, according to Kazakhstan-based TV channel KTK.

Phillipos was convicted of lying to the FBI about a terrorist investigation. He was released from prison in February. The Herald reported earlier this month he is relocating to California to continue his education and look for work.