WELLINGTON, New Zealand—New Zealand authorities imprisoned a man inspired by the ISIS terrorist group for three years after catching him with a hunting knife and extremist videos—but at a certain point, despite grave fears he would attack others, they say they could do nothing more to keep him behind bars. So for 53 days from July, police tracked the man’s every move, an operation that involved some 30 officers working around the clock. Their fears were borne out Friday when the man walked into an Auckland supermarket, grabbed a kitchen knife from a store shelf, and stabbed five people, critically injuring three. New Zealand officials confirmed Saturday that 32-year-old Ahamed Aathil Mohamed Samsudeen was the attacker. Two more shoppers were injured in the melee. On Saturday, three of the victims remained hospitalized in critical condition and three more were in stable or moderate conditions. The seventh person was recovering at …