A man who earlier this month seized an automatic weapon from a police officer at Orly airport in Paris had traces of cocaine in his blood and a long criminal record, while the attacker who killed 86 in Nice last July had a history of heavy drinking, cannabis use and casual sex.