A former New Zealand student who built a bomb used in an Isis suicide attack was allegedly inspired by a close friend's death.
Taie bin Salem bin Yaslam al-Saya'ari was gunned down by police in Saudi Arabia on Sunday.
Authorities say he planned an attack last year at one of Islam's holiest sites, manufacturing a bomb used in the July 4 suicide attack outside a mosque where the Prophet Muhammad is buried which killed four Saudi security force members.
After shooting Al-Saya'ari over the weekend police found two explosive belts, two machine guns, a home-made grenade and basins filled with chemicals.
The Saudi man is believed to have lived and studied in New Zealand between 2008 and 2013.