BAGHDAD (AFP) - Even after the recapture of Mosul, the Islamic State in Iraq and Syria (ISIS) still holds significant territory in several Iraqi provinces and has the ability to carry out attacks in government-held areas.
Here are some of the key areas still controlled by the extremists, the recapture and control of which pose political as well as military challenges:
A town located between Mosul and the Syrian border that had an estimated population of around 200,000 before ISIS seized it in the summer of 2014.
Tal Afar was a Shi'ite Muslim-majority enclave in the mostly Sunni Muslim area with an overwhelmingly Turkmen population before its capture by ISIS.
"Tal Afar itself is going to be a bit like Mosul, it's going to be... sort of a quite conventional clearance operation," said Michael Knights of the Washington Institute for Near East Policy.
But the issue of which forces will participate, and who will control it after it is retaken, are potential sources of conflict.
"Shi'ite militia insistence on controlling the Turkmen (town) of Tal Afar juxtaposed with US and Turkish refusal to allow the Shi'ite militias to participate" are among the conditions that could lead to conflict in the future, said Patrick Martin of the Institute for the Study of War.
A town in Iraq's Kirkuk that is the centre of a large ISIS-held area in a province that is otherwise controlled by Kurdish forces.
Security forces entered an anti-government protest camp in the Hawijah area in April 2013, sparking clashes that killed dozens, a key event in a surge in violence in Iraq that culminated in an ISIS offensive that overran swathes of the country the following year.
"Political challenges are preventing the Hawijah operation from starting," Martin said.
"The convergence of Iraqi Kurdish forces, who seek to control Kirkuk and its oil resources, Iraqi Shi'ite militias who seek to prevent Kurdish separatism and Iraqi government forces could lead to instability in recaptured Kirkuk," he said.
Hawijah is "part of a threat complex that is an island of ungoverned space in the middle of north-central Iraq. And it's a complicated, big, long-term problem," Knights said.
He said clearing Hawijah will likely be left until last.
ISIS holds a string of territory along the Euphrates River valley in Anbar province, including the Al-Qaim area on the Syrian border.
While Iraqi forces have recaptured Ramadi and Fallujah, the two main population centres in Anbar, this territory closer to the border with Syria will be difficult to defend once recaptured.
"Holding the border and preventing (ISIS) infiltration of western Anbar's expansive deserts with limited manpower will be a serious challenge" for Iraqi forces, Martin said.
Knights agreed. Syrian border areas "are really dangerous areas where ISIS could throw... a tank company over the border and just overrun you and smash you to bits if you're not careful."
Successfully defending the small border forts in western Anbar will require sensors on the border to detect intruders and military forces that can respond quickly on the ground or with air strikes, Knights said.
Government-held areas Iraqi forces have retaken three cities and numerous towns and villages from ISIS, but the extremists still have a presence in government-held areas and are able to carry out frequent attacks on civilians and security forces personnel.
"By the time we liberate all these openly (ISIS)-controlled areas, they're gonna have a whole bunch of re-clearing to do," said Knights.
He gave Diyala province - where ISIS has undergone a resurgence since the province's announced recapture in 2015 - as an example of what may happen in other areas.
ISIS's predecessor, the Islamic State of Iraq, was also dealt major military setbacks in past years, but widespread Sunni Arab anger with the government combined with the Syrian civil war to set the stage for its resurgence.
While ISIS has suffered a series of military defeats, Iraq will have to successfully navigate issues including political reconciliation with Sunnis and reconstruction of recaptured areas to head off future conflict.