A security firm recovered thousands of naked selfies, emails and text messages, phone numbers, and other personal data from factory-reset phones they bought from Ebay, which may prove the only way to delete data is by destroying a phone.

Avast, a security firm, based at the Czech Republic, used forensic tools to extract data from the phones which were factory-reset to prevent access to their stored data. Most smartphones come with a "factory-reset" feature, an option that allows users to reset the device, erase all stored data, and return the phone to its initial state.

However, Avast found that using forensic tools that can be downloaded easily online may help in accessing data from these factory-reset phones. They claimed they were able to access approximately 40,000 images, 750 of which were depicting women in different stages of nudity and 250 featuring men's genitals. There were also 1,500 family pictures featuring children, 1,000 recorded Google searches, and 750 emails and text messages. The company was also able to extract around 250 email addresses and contact names.

"Deleting files from your Android phone before selling it or giving it away is not enough. You need to overwrite your files, making them irretrievable," Avast wrote in a blog post.

Google explained that the security firm used older smartphones, and these phones were not yet equipped with security protections cound in current models, BBC News reported. Google added that users should enable data encryption on their devices before using the factory reset option to make it harder for third parties to access data.

Smartphone vendor Apple included data encryption on firmware and hardware beginnign with their iPhone 3GS and in newer models.