Edward Snowden, the former US intelligence contractor who leaked classified documents revealing US internet and phone surveillance, has asked Ecuador for asylum.