The government is looking into whether it will change the law to make it possible to send would-be terrorists, or refugees who have been serious offenders, back to their home countries.
And former justice minister Andrew Little has defended how long it took to draft tighter terrorism legislation despite warnings that people planning a terrorist act were currently engaged in a 'lawful activity' because New Zealand had not made such activity unlawful.
Ahamed Samsudeen stabbed shoppers at a Countdown supermarket in the Auckland suburb of New Lynn last September.
Authorities had been trying to detain him while he waited for an appeal hearing against deportation - because of the risk he posed.
Immigration Minister Kris Faafoi said the government is talking to other countries about how they deal with deporting protected people - those who face the risk of persecution in their home countries.
"We're currently in a phase where we are asking some experts for some feedback to the proposals. Some of that includes talking to other countries about the regimes that they have in place to relocate people. It's not as easy as it sounds and obviously, that was one of the sticking points with the individual involved.
"So we haven't come to a final position yet. But we have, I guess - in comparison to where we were in September last year, we've advanced a lot of the policy discussions."
The government was told last July that although Samsudeen's refugee status was cancelled because of fraud in 2019, he would probably qualify as a protected person under the Immigration Act and so it was unlikely he could be deported. He could not be detained for the purpose of being sent home, if deportation was not a realistic prospect.
Little told parliament in a special debate in the days after the attack, that the country would be reflecting on how someone protected from harm by New Zealand's laws set out on a murderous mission despite authorities knowing the risk he posed.
"We have given refugee status to an individual, because of a claimed threat he was under - and yet he has posed a significant threat to fellow New Zealanders. And that is an intolerable tension for any country to be under, and it does call for us to examine our laws."
Prime Minister Jacinda Ardern said she had expressed concern "that the law could allow someone to remain here who obtained their immigration status fraudulently and posed a threat to our national security".
The issue of deporting a former refugee who may still qualify as a 'protected person' because of ongoing risk of persecution in their home country was a hard problem, Little told RNZ.
"It's a question about whether we entertain the idea that if we find that somebody given refugee status is a national security risk, that we act in the face of international law, and give ourselves the power to deport that person, obviously following a due process. That is one of the challenges we have to consider.
"It's not in my bailiwick [jurisdiction], so I'm not actively considering it. But it is an issue that certainly at the time, September last year, was raised with us for ministers to consider."
Immigration officials appeared before select committee last week to discuss their work.
"We are working with ministers around current sufficiency and adequacy of the Immigration Act in respect of dealing with national security matters," said acting deputy secretary of labour, science, and enterprise, Ruth Isaac.
An 'extremely high-risk approach'
It was not the only law that proved insufficient.
A regulatory impact statement summarised the problem that new terrorism legislation would eventually solve - but that had not by September 2021 - that planning or preparation to commit a terrorist act was not a criminal offence.
"If a person or entity undertakes planning or preparation to carry out a terrorist act, this would be a lawful activity. Relevant agencies, such as New Zealand police, would only be able to act in the face of an immediate threat. This necessitates an extremely high-risk approach of waiting until such time as a person becomes a legally justifiable 'immediate threat' and that this would be detected in time to intervene."
Prosecutors had tried to bring terrorism charges against Samsudeen, with a High Court judge who heard his case noting in 2020 that the absence of an offence of preparing an attack could be an Achilles' heel in the law.
But the government has denied it did not act fast enough, following security agency warnings five years ago that terrorists planning an attack could not be prosecuted.
The SIS briefed its minister, Andrew Little, in 2018 about the risk that Ahamed Aathil Mohamed Samsudeen posed, and that "current legislative settings are not adequate to prevent potential terrorist threats in New Zealand".
Little, who was also justice minister from 2017 to November 2020, defended the three years it took to commission work and consult on a law change.
The bill had not reached its second reading when the Sri Lankan refugee stabbed shoppers at LynnMall in September. It was passed under urgency within a month of the attack.
Police had been the lead agency in the round-the-clock surveillance of Samsudeen, who by last winter had spent four years in prison, mainly on remand, for charges that eventually became convictions of possessing a knife, refusing to assist police, possession of restricted and objectionable material and fraud.
Police said they cannot calculate how much their surveillance operation cost in the seven weeks between his release from custody and the day he was fatally shot by undercover officers. But it said about 40 staff - not all of whom worked fulltime on the operation - were supported by about 130 other staff, including 25 special tactics group officers.
In a meeting with Little a month before the attack, the director-general of SIS, Rebecca Kitteridge, "highlighted the long term discomfort of the investigation being in this monitoring space with the assessed risk that the target presents". Several SIS written briefings note that Samsudeen "poses a high risk of undertaking a domestic act of faith-motivated extremist violence."
"We assessed that the target would likely mobilise towards a domestic act of violence at some point, advise that the target's pattern of life is not consistent - making it difficult to predict or prepare for his movements," said one update.
An SIS chart showed that 'likely' and 'probable' meant a likelihood of between 50 and 75 percent. Its quarterly update on 1 September - two days before the attack - reported the terrorism threat level at medium.
Complicated policy work
Little, minister in charge of SIS and minister of justice throughout the first Ardern-led government, pointed out the inadequacies in counter-terrorism laws were first identified in 2007.
"But nothing had been done until I was first briefed as minister of justice in 2017. So I was briefed very early on in the time I was minister of justice, and in conjunction with the prime minister in that capacity as the Minister of National Security and Intelligence commissioned the work early in 2018 to get those gaps addressed. [A MoJ document says that happened in late 2018.]
"The nature of that policy work is detailed and complicated. It doesn't just involve the Ministry of Justice and the DPMC - in addition to the intelligence agencies, the police are involved and because it is criminalising actions, which on a different blush could actually be quite innocent actions, it is a very difficult area of law drafting to get right.
"We knew that it would take a reasonable amount of time, the policy work was done by 2020. That is the time it takes to deal with a complicated piece of policy."
Work on the Terrorism Suppression Act change was commissioned in 2018 and the bill was introduced to parliament in April 2021.
Little said the time it took to draft and enact the legislation was necessary. "It's important when we're putting forward criminal statutes of this nature, and this is at the high and hard end of criminal statutes in complicated areas, is that we get the policy right to get the legislation right and I'm satisfied that the correct amount of time was taken to get the work done."
Consultation took place with government agencies and 15 academics and legal practitioners.
The legislation which agencies operated under is not part of the review out next month, which will look at how police, Corrections and SIS managed Samusudeen, and whether they did enough to assess and respond to the risk that Samsudeen posed.