1

How can I check the installation of the new application to my phone through my android application.Also I need to scan the permissions the installing app is seeking. Inshort the feature called on-install scan in CM security is used and I want to implement it in my app,please help me with the code. My problem statement is ,I have an app that should do the following 1.While installing a new apps ,my app must seek what permission the installing app requires 2 I have to say it is a malicious app if it contains some predefined set of permission

Jorge
  • 1,136
  • 9
  • 15
Preetham
  • 577
  • 5
  • 13
  • 1
    What you have tried? – Nigam Patro Apr 19 '16 at 05:08
  • 1
    Possible duplicate of [How to get App's Permission for each app? how to do it programmatically on Android?](http://stackoverflow.com/questions/5385957/how-to-get-apps-permission-for-each-app-how-to-do-it-programmatically-on-andro) – T D Nguyen Apr 19 '16 at 05:18

1 Answers1

0

Use package manager and a concrete mask, for example

PackageManager p = context.getPackageManager(); final List<PackageInfo> appinstall = p.getInstalledPackages(PackageManager.GET_PERMISSIONS | PackageManager.GET_PROVIDERS)
Jorge
  • 1,136
  • 9
  • 15
  • Thank for the answer ,but I need to get those permissions when the new app is installing not after installation . – Preetham Apr 19 '16 at 05:49