Prime Minister Jacinda Ardern has named a sitting Supreme Court justice to head New Zealand’s top level investigation into the actions of security agencies and other issues related to the mosque shootings last month in which 50 people were killed.

The Royal Commission of Inquiry will look into the gunman’s activities before the attack, including how he obtained a gun license and weapons and his use of social media.

Ardern said Monday the government “will ensure no stone is left unturned as we examine as quickly as possible how the March 15 attack happened, what could have been done to stop it and how we can keep New Zealanders safe.”

The commission led by Sir William Young will be expected to report its findings to the government by Dec. 10.