In recent years, as the development of machine learning become more and more faster, people's lives have been convenient, while security risks have also arisen. The security and privacy issues of machine learning put its own development into a difficult position. Machine learning models can be trained and predicted on the basis of a large amount of data, while these data will inevitably contain a varying amount of sensitive or private information. With the frequent occurrence of data security and privacy leaks, and the degree of leakage gradually deepens, the way to guarantee data security and privacy has attracted much attention. This article discusses privacy protection based on machine learning by analyzing machine learning and the privacy issues it facing.