Every time I restart my Xolo Era 4g, Android 5 Lollipop phone, it auto enables "allow installation of apps from unknown sources" option. I switch it off manually, then in a few seconds, a pop-up for an unknown app to install shows, and on the background, the "unknown sources" button automatically toggles. This keeps on going forever. I haven't rooted my phone and have factory reset it many times.
I first installed an antimalware app, and when I run it, it found around 16 malware, of which I deleted 14 but there was no option to delete the last two. Then I installed the notification app. I restarted my phone. After that, the internet automatically started. I immediately switched it off. Then I went to settings and switched off to allow unknown apps installation.
Then I opened the menu and slide it a few times and the malware attacked again. Opening the settings disclosed that an unknown app installation is switched on. Many apps are promoted for installation. After pressing cancel around 50 times, I went to the menu again and many new apps were installed. I have repeated this scenario two times once I switched the internet on. But with the internet off, I saw an app installation prompt too. I don't remember with the internet off whether the apps got actually installed or not.
Now I opened the notification app and it showed one process having some text similar to Andriod UI lolipop 5.0, it had a lollipop icon to its left. On clicking on that, it further showed one process. The process was related to the notification app itself and had text "toaster" or maybe "toasted". Now I have factory reset my phone again and have uninstalled all default apps like Flipkart, Snapdeal, Paytm, UC browser, etc. Now if I'll again restart my phone, the virus will start again.
Please tell a method to not allow any app to toggle the "unknown sources" options on without rooting the phone.