Notes

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 3

Q1. i) Describe all steps in application deployment on google play store.

ii) Write steps for customized permissions. (6m)

Ans –

i) Describe all steps in application deployment on google play store.

1. Prepare Your App:

 Create an APK (Android Package) file for your app. This file contains all the necessary
resources and code for your app to run on Android devices.

2. Create a Google Play Console Account:

 Sign up for a Google Play Console account if you haven't already. You'll need a
Google account to do this.

 Provide necessary information such as developer name, email address, and payment
details.

3. Prepare Store Listing:

 Log in to the Google Play Console.

 Create a new app by clicking on the "Create app" button and follow the prompts.

 Fill in the details for your app's store listing, including title, description, screenshots,
promotional graphics, categorization, and contact details.

4. Upload APK:

 Go to the "App releases" section in the Google Play Console.

 Upload your APK file under the appropriate release track (e.g., production, beta,
alpha).

5. Review & Publish:

 After uploading your APK, Google Play Console will perform checks to ensure it
meets quality and policy standards.

 Address any issues or warnings reported by the console.

 Once your app passes review, you can proceed to publish it by clicking the "Start
rollout to production" button.

ii) Write steps for customized permissions:

Customized permissions in an Android application allow developers to request specific permissions


from users at runtime, instead of requesting all permissions at installation. Here are the steps to
implement customized permissions in your Android app:

1. **Declare Permissions**: In your app's `AndroidManifest.xml` file, declare only the permissions
that are considered dangerous or critical for the app to function.
2. **Check Permissions at Runtime**: Before performing operations that require permissions, check
if the permission is granted by the user. You can use the `ContextCompat.checkSelfPermission()`
method to check if a permission is granted.

3. **Request Permissions**: If the permission is not granted, request the permission from the user
at runtime. You can use the `ActivityCompat.requestPermissions()` method to request permissions.

4. **Handle Permission Results**: Override the `onRequestPermissionsResult()` method in your


activity to handle the result of the permission request. Check if the requested permission is granted
and proceed accordingly.

5. **Explain Permission Requests**: When requesting permissions from the user, provide a clear and
concise explanation of why the permission is needed and how it will be used in the app.

6. **Handle Permission Denials**: If the user denies a permission request, gracefully handle the
denial and adjust the app's behaviour accordingly. You can also provide guidance on how the user
can manually grant the permission in the device settings.

7. **Test Customized Permissions**: Thoroughly test your app to ensure that the customized
permissions implementation works as expected and that the app behaves correctly in various
permission scenarios.

Q2. List various classes of SMS Telephony. (2m)


Ans –

 TelephonyManager
 SmsManager
 SmsProvider
 SmsMessage
 MmsMessage

Q3. Explain Android Security model.

Ans –

 The Android security model is primarily based on a sandbox and permission mechanism.
 Each application is running in a specific Dalvik virtual machine with a unique user ID assigned
to it, which means the application code runs in isolation from the code of all other
applications.
 Therefore, one application does not have access to other applications’ files.
 Android application has been signed with a certificate with a private key.
 This allows the author of the application to be identified if needed. When an application is
installed in the phone it is assigned a user ID, thus avoiding it from affecting other
applications by creating a sandbox for it.
 This user ID is permanent on which devices and applications with the same user ID are
allowed to run in a single process.
 This is a way to ensure that a malicious application Cannot access / compromise the data of
the genuine application.
 It is mandatory for an application to list all the resources it will Access during installation.

Q4. Elaborate the need of permissions in Android. Explain the permissions to set system
functionalities like SEND-SMS, Bluetooth.

Ans - The purpose of a permission is to protect the privacy of an Android user. Android apps must
request permission to access sensitive user data (such as contacts and SMS), as well as certain
system features (such as camera and internet). Depending on the feature, the system might grant the
permission automatically or might prompt the user to approve the request.

 android. permission. SEND_SMS

Allows the app to send SMS messages. This may result in unexpected charges. Malicious apps may
cost you money by sending messages without your confirmation.

Following is the code snippet to set SEND_SMS permissions in manifest file.

<uses-permissions android: name = ‘android.permissions.SEND_SMS’>

 android. permission. BLUETOOTH

Allows the app to initiate and accept Bluetooth connections. Apps that utilize Bluetooth
functionality need this permission.

You need to provide following permissions in AndroidManifest.xml file.

<uses-permission android: name="android.permission.BLUETOOTH" />

<uses-permission android: name="android.permission.BLUETOOTH_ADMIN" />

You might also like