Introduction
While developing an application, the most important process is to secure sensitive data. Permissions add security to system data and features and use predefined permissions.
Permission Types
Normal
It is low-level security-sensitive information. The system will grant the permissions automatically without asking the user, but permission is listed in the application package description.
Dangerous
This is high-level security-sensitive information. The permission is asked to the user and if the user grants permission, the permission will not be asked anymore until the application is reinstalled.
Signature
It is extremely high-level security-sensitive information. Apps signed with the same certificate as app defining the permissions can acquire it. If signature matches, it automatically grants the permission.
Special
The system grant access to system resources only by the off-band acquisition method. The app must use two if necessary.
Privileged
These are for system image apps. It should not have to use them.
Defining Permissions
Defining own permissions are used for secure apps. For built-in permissions, the permissions are defined by the system and own permissions are used when application are exposed sensitive information. Own permissions are set inside the AndroidMainfest.xml.
- <permission android:description = "string resource"
- android:icon = "drawable resource"
- android:label = "string resource"
- android:name = "string"
- android:permissionGroup = "string"
- android:protectionLevel = ["normal" | "dangerous" | "signature" | "signatureOrsystem"] />
For grouping the permissions, there are two ways: Use the <permission-group> element and add permissionGroup attributes to <permission>; the section "Manifest Top Level Entries" in the text companion. Use the <permission-tree> element and name permission basis of "Manifest Top Level Entries" in text companion.
Using Permissions
- <uses-permission android :name = "String"
- android:maxSdkVerion = "integer" />
The name attribute specifies the permission name and to connect the permission to all components at a time on a per-component base. In such case the below code can be used inside the permission attribute.
- <activity android:name = "com.example.myapp.ExampleActivity"
- android :permission = "com.example.myapp.abcPermission" />
Acquiring permission
Permissions enquiry happens at the runtime of an application. This made the psermission system more flexible. The below runtime permission inquiry must be included in the code.

Join the conversation! Your thoughts help the community grow.