Iraqi-born cleric Mullah Krekar kneels to pray, after being released from Kongsvinger prison, in Kongsvinger, Norway, Sunday Jan. 25, 2015. (AP Photo/NTB scanpix, Audun Braastad)

In 1991, Mullah Krekar arrived in Norway as a refugee. An Iraqi Kurd born under the name Najmeddine Faraj Ahmad, he has acknowledged he is the co-founder of Ansar al-Islam, a notorious Sunni Islamist group that targeted U.S. troops during the Iraq insurgency and has been linked to both al-Qaeda and the Islamic State.

While he says he no longer has any links to the group, the 58-year-old Krekar faced multiple criminal charges in Norway, earning himself the label of a "danger to national security" from the Supreme Court of Norway and a place on a United Nations list of terrorists. Yet Norway can't deport Krekar. The country has had an expulsion order against him since 2003, but it has been unable to send him to Iraq due to Norway's humanitarian concerns that he may face torture or execution there.

Last month, Norway released Krekar from prison, where he had served almost three years for death threats against Prime Minister Erna Solberg and three Kurds. Now the country faces a dilemma: What to do with an extremist non-citizen who cannot be deported?

Norway's solution, at least for the time being, is to keep him in the country, yet send him far, far away. On Monday, a court in Oslo said Krekar cannot stay in the Norwegian capital and instead must live in Kyrksaeteroera, a village with a few thousand inhabitants that is a nine-hour drive away.

A street scene Jan. 20, 2015, in the city of Kyrksaeterora, Norway, where released Islamic leader Mullah Krekar from Iraq is to be moved to a refugee reception center. Mullah Krekar was released from prison in Olso, Norway, where he was serving a two years and 10 month sentence for threats against Norwegian Prime Minister Erna Solberg and three Kurds.  EPA/Henrik Sundgaard NORWAY OUT

Under the court's orders, the married father of four would live at a refugee center in the village and be required to check in with police several times a week. "With some misgivings, the court considers that the basic national interest, at least until 31 December 2015, must take precedence over Faraj's right to a family life, freedom to move freely throughout the country and to choose his own place of residence," the court's decision read, according to Agence France-Presse.

The move is reminiscent of other "internal deportations" throughout history: There are even echoes of Leon Trotsky's brief time in Norway, where he lived under house arrest in a rural area before eventually being deported to Mexico. It comes at a time of intense scrutiny about Islamist extremism in Europe in the wake of the rise of the Islamic State militant group and last month's terrorist attacks in Paris.

Norway's hope is that Krekar will leave Norway at some point: According to the newspaper Aftenposten, there are talks with Italy to deport him there so he can face more charges; Germany and Switzerland have also been explored as possibilities. For now, however, Krekar is appealing the decision to send him to Kyrksaeteroera -- and staying at a secret location in Oslo.