Israel’s intelligence services will help investigate whether the attackers had links to Iran or the Islamic State.