Assailants shot dead a senior Saudi security officer west of the capital Riyadh on Tuesday, the interior ministry said in a statement carried by state media, and the attack was claimed by the militant Islamic State.