MINNEAPOLIS (AP) — A federal judge in Minnesota has ordered an Iraqi man released from immigration custody until there's a final order to remove him from the U.S.

District Judge David Doty ordered Monday that 35-year-old Farass Adnan Ali be released within 30 days. Ali has been in custody on immigration charges for 18 months.

Immigration and Customs Enforcement officials allege that when completing immigration forms, Ali concealed his service in the Saddam Hussein regime's elite Republican Guard.

Lawyers for Ali challenged what they call his "unreasonable, prolonged" pre-deportation detention, which included seven months of solitary confinement.

Ali attorney Ian Bratlie of the American Civil Liberties Union of Minnesota says he hopes Ali is released this week.

A spokeswoman for the U.S. Attorney's office in Minnesota did not respond to requests for comment.