22

I want to create an system application(while installing it will ask user permission to make it as system app) for UN-rooted application. As I am not familiar in android, please tell me how to create it.

Thanks in advance.

ponraj
  • 738
  • 1
  • 7
  • 21
  • 3
    I'm not sure you can do that. First, you need to sign your application with Android keys, and since your phone is un-rooted, I don't know if your able to do that – edoardotognoni May 02 '13 at 09:04
  • Look at this article (http://www.androidauthority.com/install-user-app-as-system-app-how-to-93522/). Maybe it will help you. – Alexey Odintsov Jul 11 '13 at 13:22
  • 1
    Your question seems to be contradictory. Since you're telling us you're not familiar with Android, you'll have to specify exactly what mean when you use the term "system app". An iOS developer on Android for instance would certainly have a completely different definition of what a "system app" was supposed to be like on Android. – Stephan Branczyk Jul 11 '13 at 21:28

1 Answers1

35

True system apps are baked into the ROM image, and signed with the same key the ROM was signed with, giving them extra access to the system.

You cannot add a new system app on the same level without updating the ROM image of the device, and even then you'll need the OEM key to sign your app and you will have to request them to include it in their ROM.

Having a rooted device allows standard apps to gain extra access without being system apps.

Raghav Sood
  • 81,899
  • 22
  • 187
  • 195
  • 22
    Not exactly correct. System Apps do not *need* to be in the firmware/ROM - they can be installed just like ordinary (non-system) Apps. The critical point, as you indicate, is that the App *must* be signed with the same key used to sign the firmware Apps. – adelphus Jul 16 '13 at 20:03
  • @adelphus But if they're installed like ordinary apps, they can also be uninstalled the same way iirc. – Raghav Sood Jul 17 '13 at 02:11
  • 1
    They *can* be uninstalled, that's not necessarily a problem, though. (If they're baked into the ROM properly, only updates can be uninstalled) – Delyan Jul 17 '13 at 21:10
  • @adelphus : (1) Are you saying that if an app is signed with same key as the OS then even if they reside in data/app they have all privileges like a system app? (2) Say, once we sign an app with the system key,is there any way we can confirm that the app really has become a system app? – Basher51 Aug 14 '14 at 03:57
  • Hello, I am thinking to do this like : 1) Root phone programatically 2) Install apk in System/apps folder 3) UnRoot device. Is it feasible way to do? I need to make one default app which will never be uninstall from device. Please share any possible ways to achieve this. Thanks – Hardik Joshi Aug 22 '14 at 11:08
  • 3
    @Basher51 (1) Yes. (2). To actually make an app run as the system user, you need to specify android:sharedUserId="android.uid.system" in the Apps' manifest (and of course, sign it with the firmware key). The easiest way to determine if an app is actually running as system is to look at its' uid in logcat messages - the system user always has a uid of 1000. – adelphus Aug 26 '14 at 16:09
  • @Prince - is it feasible? Yes - it is common for people with rooted devices to remount /system as read-write and install apps into the system/app folder. The apps don't need to be system-level apps and installing it into the (normally read-only) system partition will prevent the user from uninstalling it - unless of course, the user can root the device and delete the APK themselves. – adelphus Aug 26 '14 at 16:15
  • This comment is't true. System apps can be installed like regular apps. – yams Dec 10 '21 at 16:49