Is it possible at application level? Or do we have to do it inside the OS?
People might want to do this to reduce the attack surface. Ideally, the application, at virtually any point of time, should have a permission only if it is needed, following the `principle of least privilege’.
To clarify: by “change”, I mean to give up certain permissions temporarily, and regain them sometime later when they are really needed.
It would be against clarity Android policys . The application has or not has the permisions for doing something . It can be a security problem if you can think of it.