1123 Commits

Author SHA1 Message Date
Jeff Sharkey
925cc2a066 More protected broadcasts!
Bug: 26144973
Change-Id: I56f047d7e4b9d7bcf1ac40c98ee381badd909057
2016-03-02 16:21:58 -07:00
Dianne Hackborn
e5ad41bc02 Fix issue #27317952: PendingIntent.getIntent() should be protected
Change-Id: Ib05135cd94f5251942a6fc6df542ed39083f7827
2016-02-29 18:02:43 -08:00
Makoto Onuki
bdb14a30d0 Remove READ_WRITE_CONTACT_METADATA, which is no longer used
Bug 27365657

Change-Id: Iaf1b62991bbb0ccce9488e4e50bc49a12663a2d0
2016-02-25 17:26:06 -08:00
Svetoslav Ganov
5cd52bee32 Merge "Expose removed permissions flag as system API" into nyc-dev 2016-02-23 02:21:01 +00:00
Svet Ganov
2a1376d9df Expose removed permissions flag as system API
There are some permissions that were removed from the platform
and guard nothing but legacy apps may be checking them before
calling APIs. Hence, these apps should get the permissions as
expected despite them being a no-op. To address this the platform
declares removed permissions as normal permissions that are hidden
such that legacy apps can always get them. These permissions are
not shown in the UI. Play needs a way to filter out these
permissions like the platform as they have permissions UI too.

bug:23361760

Change-Id: I10f442dfc09a299ddc5480d8bf2db0bd786aec62
2016-02-22 18:10:49 -08:00
Felipe Leme
66d7588078 Removed bugreport intents from protected list.
These intents are send by Shell, which is not a protected uid, and
already required the android.permission.DUMP permission, hence they are
protected by permission.

BUG: 27287868
Change-Id: Ie7cfe20a119e8abe989186ca2e0ae16454b4cf22
2016-02-22 11:04:03 -08:00
Svet Ganov
9cea80cddd No overlay when permissions shown - framework
bug:26973205

Change-Id: I88395e47649191bb7db6dd8723c49e741ef4f1e4
2016-02-20 17:41:47 +00:00
Jason Monk
5dbd4aad80 SysUI Tuner: Night mode v3
TwilightService:
 - Add support for locking on/off twilight globally
 - Change twilight state to have float amount rather than
   having clients calculate it using the sunrise/set values
 - State controlled through secure setting
 - Override mode which locks to a state for a couple hours then
   resets
 - Add broadcast for SysUI to listen to

Brightness/Power:
 - Updates to handle TwilightService changes
 - Added secure setting to control whether or not to use
   twilight when calculating brightness.

Tuner:
 - UI Overhall
 - NightModeController will set the values of the custom color matrix
   taking into account the current twilight service state and any
   custom calibration set by the user.
 - Probably other stuff.

Change-Id: I213f1f76a143e711c507b2ba7d784f581bfc32b4
2016-02-18 14:06:51 -05:00
Martijn Coenen
087fd6829d Merge "Update protected broadcasts used by NFC." into nyc-dev 2016-02-18 12:25:03 +00:00
Martijn Coenen
5e906f8829 Update protected broadcasts used by NFC.
Change-Id: Ie7d062e83929e1058e19427f6ca624ab3f8ee472
2016-02-18 12:19:39 +01:00
Jeff Sharkey
37fc7a7fc0 More protected broadcasts.
These actions are owned by the system and should not be sent by
third-party apps for security reasons.

Bug: 27171917, 27169730, 27172357, 27163393
Change-Id: I3161cd3c1c37d26a92723b22878dc5aef6f30c47
2016-02-16 09:41:57 -07:00
Rubin Xu
b5f0049f98 Fix typo in filling ACTION_MANAGED_PROFILE_UNLOCKED extras.
Change-Id: Ic949a0d7f72d46d7cc36018b4b0fc54024c3b180
2016-02-15 14:12:32 +00:00
Pavel Zhamaitsiak
d820abddd2 Make ACTION_RADIO_OFF protected
Bug: 25113145
Change-Id: Idcb88cb1fd06d4761ef1f634136f8ec697bf0851
(cherry picked from commit ae6688ca5d2b506eff29ba27c7532513f2da7da8)
2016-02-09 18:16:48 +00:00
Abhijith Shastry
901bbe0667 Merge "Hidden permissions to access blocked numbers." into nyc-dev 2016-02-08 22:40:36 +00:00
Amit Mahajan
c08268e647 Make permission RECEIVE_EMERGENCY_BROADCAST public.
It is required to receive intent SMS_EMERGENCY_CB_RECEIVED_ACTION
which is already public.

Bug: 24914029
Change-Id: I2d5461fcedb2cb347c818ab6f94577008f6af242
(cherry picked from commit 45d9b36fc6a609893022b812084987cda3e3717d)
2016-02-08 22:20:03 +00:00
Abhijith Shastry
d6e1ed5906 Hidden permissions to access blocked numbers.
BUG: 26232372
Change-Id: I213622ef4623dadcf56745798fb3452c57fa4bd5
2016-02-08 14:18:56 -08:00
Chris Wren
10c63d8a12 move assistant to system API
Bug: 26693581
Change-Id: I7e29b8521e2c33683b8032e63da734cfde1dfcc9
2016-02-05 14:55:35 -05:00
Steven Ng
ee081d5bd0 Merge "Add new permission and action for managed provisioning (QR flow)" 2016-02-04 10:24:44 +00:00
Christopher Tate
4cf5a49e54 Mark the idle-maint trigger broadcast 'protected'
Bug: 26942536
Change-Id: I52d6b304fc894cad7957f84946178378c309f621
2016-02-03 16:42:19 -08:00
Felipe Leme
f933871976 Merge "Created a ACTION_RESTRICT_BACKGROUND_CHANGED intent." 2016-02-02 23:59:30 +00:00
Carlos Valdivia
bf33bd4d31 Revert "Permissions: Get rid of GET_ACCOUNTS"
This reverts commit 918c55a67c2bf0cec79f75dec6ca468e914a5fd1.

Change-Id: I995f134336bf61ac1f21052355900ae89d0d6694
2016-02-02 15:01:56 -08:00
Steven Ng
980a1b6fa8 Add new permission and action for managed provisioning (QR flow)
+ Instead of reusing NFC provisioning action, new action and permission
  are introduced for QR code provisioning

Bug: 26240297
Change-Id: Id2632d6c6b9e62bf3cad5bc141430d49df4a2c5d
2016-02-02 17:43:18 +00:00
Shreyas Basarge
a491c07f36 Merge "SyncManager on JobScheduler" 2016-02-01 15:32:58 +00:00
Rubin Xu
c3cd05f8a4 Add DevicePolicyManager APIs for process logging.
Add Device Owner APIs for controlling and retrieving the logs. Retrieving the
logs should be rate limited unless we are at the risk of losing logs due to
constrained buffer space.

Bug: 22860162
Change-Id: I80658f5a14e86d7cfd42402fbc5e98dc11698c0e
2016-02-01 10:28:24 +00:00
Jaewan Kim
54fa566ab7 Merge "PIP: Use StatusBarService to handle PIP key" 2016-01-30 01:06:29 +00:00
Makoto Onuki
6c7185cd20 Fix permission doc
Bug 26406584

Change-Id: I2c443cc52c600edb1ad904e0eb013829caee9897
2016-01-29 16:14:41 -08:00
Shreyas Basarge
8c834c0767 SyncManager on JobScheduler
SyncManager now uses JobScheduler for scheduling
and persistence purposes.

Change-Id: I38c92aedbf4d891ca297644d0b706835aaedfcd6
2016-01-29 22:15:15 +00:00
Jaewan Kim
c552b04cb4 PIP: Use StatusBarService to handle PIP key
Bug: 26591829
Change-Id: I7051fab966e2fc0887b2a21ddbf11aff7e16804b
2016-01-29 18:40:47 +09:00
Felipe Leme
9778f76123 Created a ACTION_RESTRICT_BACKGROUND_CHANGED intent.
This intent will be broadcasted when:

- Global restrict background setting is changed (sent to all packages)
- An individual uid is added to or removed from the whitelist (sent just
  to the packages belonging to that uid).

This intent is only sent to registered receivers.

BUG: 26451391
Change-Id: Ic0a5771f88baa52076ad04764f29098a386463cc
2016-01-28 13:28:11 -08:00
Adam Powell
e7c74cc96e Revert "Pinning components in ChooserActivity"
This reverts commit ec6bc41e1835804533fd21b3ef8047ecd893bcfd.

Bug 26842512

Change-Id: I9fc775d21081885d0e26fca4ade412a18da45b7c
2016-01-28 09:04:20 -08:00
Adam Powell
ec6bc41e18 Pinning components in ChooserActivity
Move ChooserActivity to SystemUI. This is a safer place for it to live
and still be able to persist data to storage.

Add a context menu to long press for chooser targets allowing users to
'pin' a target component from an app. This causes it to sort to the
front of the list so that a user's favorite apps are always available
from share UIs, etc. Similarly, all ChooserTargets from a pinned
component receive an impossibly large boost for sorting so that they
will always appear first.

Bug 26791843

Change-Id: Ib4e603d9d4263403e98ce619287452ddab593044
2016-01-27 17:17:31 -08:00
Peng Xu
a35b5539a9 Dynamic Sensor Discovery Implementation
Defined the dynamic sensor meta data type and UUID of sensor, as well
as the broadcast intent that is related to dynamic sensor status
change.

Modify SensorManager, SystemSensorManager and the JNI layer to support
dynamic sensor discovery.

Added SensorNotificationService to notify apps that sensor connected
or disconnected via broadcast.

Change-Id: I28adfb005357d7e3983d65117d6865830c75027d
2016-01-27 16:37:22 -08:00
Sailesh Nepal
4665f49b9c Merge "Add new public API to allow call screening" 2016-01-27 22:16:59 +00:00
Sailesh Nepal
1bef339b88 Add new public API to allow call screening
This CL adds a new service that the default dialer can implement to
screen incoming calls.

If the service is implemented then Telecom uses it to decide if a call
should be shown to the user or rejected.

Note, I initially tried to simply extend InCallService instead of
creating a whole new service. The problem with this approach is that:
  - this breaks some in call services which show UI as soon as they are
    bound to
  - the in call service lifecycle is tightly coupled to adding and
    removing calls. Call screening happens before a call is added which
    makes it a bad fit to in call service
  - call screening is a function of only the default dialer's in call
    service but the existing code also binds to "controller" call
    services

For these reasons it seemed simpler to just create a new optional
service.

BUG: 22857261
Change-Id: I53f2ef93360e0af19b6ce45af21026be6cf3a7f3
2016-01-27 13:54:12 -08:00
Arunesh Mishra
a772e5fc06 SoundTrigger API improvements.
This CL implements the SoundTrigger API improvements as given in b/22860713. Only the java-level
parts are implemented in this CL.

Key changes include:

* Addition of a SoundTriggerManager/SoundTriggerDetector system API to manage
  the sound-trigger based sound models.
* Addition of a SoundTriggerService service that manages all sound models
  including voice (keyphrase) and sound-trigger based models.
* Includes logic to write sound-trigger based models to the database.
* VoiceInteractionManager service now uses SoundTriggerService instead of
  SoundTriggerHelper.

Bug: 22860713
Change-Id: I7b5c0ed80702527c4460372efeb5e542d3693a69
2016-01-27 12:49:20 -08:00
Carlos Valdivia
3cdbc806ff Merge "Permissions: Get rid of GET_ACCOUNTS" 2016-01-27 00:12:06 +00:00
Sailesh Nepal
58941094d4 Merge "Mark mised call notification as protected" 2016-01-26 21:48:58 +00:00
Rubin Xu
e6e907ea09 Merge "Show dialog when launching work apps is not possible." 2016-01-25 17:51:22 +00:00
Rubin Xu
f13c980169 Turn off profile by stopping the user.
Bug: 22541941
Change-Id: I713ab9b87f3dd1b7bd6206af137562d20a44d76d
2016-01-25 16:29:29 +00:00
Carlos Valdivia
918c55a67c Permissions: Get rid of GET_ACCOUNTS
Bug: 21901286

Change-Id: Id2c42f4d449a32c88078d80dcf952d15e67d536c
2016-01-24 14:57:03 -08:00
Sailesh Nepal
d1a28aa17b Mark mised call notification as protected
This CL marks the missed call notification as protected. This prevents
other apps from being able to broadcast it.

BUG: 22857261
Change-Id: I01ae992f2a5fe255f057c5aa28c5c47d34a0a093
2016-01-23 13:51:32 -08:00
Rubin Xu
58d2599832 Show dialog when launching work apps is not possible.
There are two cases when this could happen. First is when the work
profile is turned off by the user, and the second is when the profile
owner has suspened the package.

Bug: 22776761
Bug: 22541941
Change-Id: Ibc671e93f87dff0168bb7643494b9d6b45a1a7f9
2016-01-22 19:53:01 +00:00
Makoto Onuki
efd88c3beb Merge "Add missing system broadcast actions to the protected list." 2016-01-21 21:34:59 +00:00
Makoto Onuki
730a759254 Add missing system broadcast actions to the protected list.
Bug 26697573

Change-Id: I39e6b90b38c6e1dbe4978be1cb2a10d72b015cba
2016-01-21 12:17:14 -08:00
Andrei Stingaceanu
69d5ebc59e Suspend apps - broadcast intent and API
Send a protected broadcast to registered receivers only
when packages get suspended.

Bug: 22776761
Change-Id: I043053ed45bdc202ead18518a0c1e39cce47947c
2016-01-20 17:52:41 +00:00
Michal Karpinski
a8c8851caa Merge "DPM changes to support remote bugreports" 2016-01-18 10:00:55 +00:00
Amith Yamasani
12747879b0 User creation with an intent
New API for an app to request creating a new user with
a given user name and seed account information for the
SetupWizard to use when that user is switched into.

Also adds system APIs to read the seed account data from
UserManager.

Bug: 22776757
Change-Id: I0bc3f11ee19c15e0ee2a908c88d98b13296cc30d
2016-01-15 17:06:35 -08:00
Jaewan Kim
52632e21fa PIP: Use long press HOME for PIP on Android TV (2/2)
Bug: 25580820
Change-Id: Ic269132ec7de1e725989ad57a1ee205b3334e3bb
2016-01-15 09:29:34 -08:00
Michal Karpinski
3fc437e89b DPM changes to support remote bugreports
Bug: 22860136
Change-Id: If984318e421f511d9b0fc7138aacd36d5334698f
2016-01-14 11:00:22 +00:00
Dongwon Kang
ab064b3b36 Merge "Add a way for SystemUI to receive media resource (e.g. A/V codec) usage" 2016-01-13 18:21:00 +00:00