Duterte declared martial law in the whole Mindanao on May 23, 2017, following the crisis in Marawi between Philippine government security forces and militants affiliated with the Islamic State of Iraq and the Levant (ISIL), including the Maute and Abu Sayyaf Salafi jihadist groups. Martial law was extended three times.