Gaia/AppPermissions

From MozillaWiki
Jump to: navigation, search

What is forcing your Gaia app to be a certified app? Could it be just a privileged app or even a web app? What is currently stopping that from happening?

To find out, take a look at the permissions your app requests in its manifest.webapp file, and compare against the list here. Also, please note any other reasons that your app currently has to be certified.

Note: bug 1014410 has been filed on automatically granting permissions for the shipped-with-device Gaia apps so that prompting is not required. This may be important for maintaining existing UX / not being silly.

browser

  • Permissions
    • settings (read only)
    • nfc (read/write)
  • Has to run in the main process because we don't have nested processes for content processes.
  • Is being replace by the system browser which will be part of the system app.

calendar

settings":{ "access": "readonly" } but currently not used for anything

camera

  • Permissions
    • settings (readonly) We need to read settings to know if we should play various sounds or not.

Also, we need to be certified so the #-moz-samplesize media fragment works for us until that feature is enabled more generally.

clock

  • Permissions
    • settings (readwrite, to save/restore audio.volume.alarm setting. Also used to try to intercept hardware volumeup and volumedown events, which the System app doesn't currently pass to apps)
    • attention (to display the alarm ringing screen)

communications

  • Permissions
    • audio-channel-telephony
    • bluetooth
    • idle
    • mobileconnection
    • nfc (readwrite)
    • settings (readwrite)
    • telephony
    • time
    • voicemail
    • wifi-manage

costcontrol

  • Permissions
    • sms- sms-received, sms-sent system message.
    • mobileconnection - access to SIM card, check service status
    • settings (readonly) - used in shared code l10n.js
    • networkstats-manage - Obtain statistics of data usage
    • telephony - telephony-call-ended system message.

email

  • Permissions
    • settings (read only) - to support "email sent" sound which is controlled by the settings app per UX decision some time ago. The e-mail app could just control this internally in its own settings.
  • Permissions prompts as bad UX that become moot if as a preloaded app we can pre-grant ourselves the permission.

findmydevice

fm

gallery

  • Permissions
    • deprecated-hwvideo - Needed for sharing video decoding hardware among Camera, Gallery and Video.
    • nfc (readwrite)
    • settings (readonly) - Because it needs to access the chosen locale, which is stored in the settings.

Gallery also needs to be certified because it uses the #-moz-samplesize media fragment for decoding images. Until this is enabled for non-certified content, we need to be certified.

homescreen

  • Permissions
    • mobileconnection
    • open-remote-window - This allows the homescreen to open windows in seperate content processes (ie <iframe remote='true>)
    • webapps-manage - Used to get the list of all installed apps, so that apps can be launched when their icon is tapped.
    • settings (readwrite) - Used to observe when language changes (which can't be done with navigator.language) and also to set the keyboard language.
    • power

keyboard

  • Permissions
    • settings (readwrite)

music

pdfjs

search

settings

  • Permissions
    • mobileconnection - Used throughout the application to access SIM card
    • voicemail - Used for voicemail settings
    • bluetooth - Handle bluetooth settings.
    • device-storage:apps (readonly) - Add, read, or modify files stored in the apps location on the device.
    • webapps-manage - Obtain access to the navigator.mozApps.mgmt API to manage installed Open Web Apps.
    • permissions - Allow an app to manage other permissions of other apps.
    • settings (readwrite) - Configure or read device settings.
    • wifi-manage - Enumerate available WiFi networks, get signal strength, connect to a network.
    • attention - Allow content to open a window in front of all other content. Used by telephone and SMS.
    • time - Set current time. Time zone information is controlled by the Settings API. Formerly called systemclock.
    • power - Turn the screen on or off, control CPU, device power, and so on. Listen for and inspect resource lock events
    • idle - Notify the app if the user is idle.
    • telephony - Access all telephony-related APIs to make and receive phone calls.
    • download
    • nfc (read)

sms

  • Permissions
    • sms
    • mobileconnection
    • settings (readonly)
    • phonenumberservice

system

The system app is really part of the platform and can probably never be anything other than a certified app.

video

  • Permissions
    • deprecated-hwvideo
    • nfc (readwrite)
    • settings (readonly)

wallpaper

  • Permissions
    • settings (readwrite) - Wallpaper setting.

bluetooth

bookmark

emergency-call

fl

operatorvariant

ringtones

setringtone

wappush

  • Permissions
    • settings (read/write) - We need to be able to adjust certain settings when we receive content-provisioning messages, these usually contain APN, POP3 or IMAP settings.
    • wappush - This is needed to receive WAP Push messages.