13132 Commits

Author SHA1 Message Date
Ben Gruver
b1a90d3b14 Merge "Remove the sender package filter from the intent firewall" into jb-mr2-dev 2013-04-08 21:36:37 +00:00
Ben Gruver
a4879c3425 Monitor the firewall rules file for changes
Change-Id: I4e9a8f06cc535ba5a347e6992e1466cff09890e9
2013-04-08 14:27:37 -07:00
Daniel Sandler
91fe8455d6 Clean up language in forced foreground service notifications.
Old:  [ IC ] %s running
      [ ON ] %s is running

New:  [ IC ] %s is running
      [ ON ] Touch for more information or to stop the app.

Additionally, disallow these misbehaving services from
supplying their own content views; if you attempt to run a
foreground service with icon == 0, this is the notification
you will get, period.

Bug: 8525548
Change-Id: I2bfd7340396ef925885e8c2160a720f9eff07a35
2013-04-08 13:01:02 -04:00
Ben Gruver
8be8df2141 Implement event logging for intent firewall
Change-Id: If79052d07f3e5c02cfdbd0dd00026b01110045c2
2013-04-07 14:29:34 -07:00
Geremy Condra
a1ca6facee Merge "Fix crash in ConfigUpdater when the target dir doesn't exist." into jb-mr2-dev 2013-04-05 21:52:40 +00:00
Michael Wright
bdb706e48d Merge "Pipe through device resolution information" into jb-mr2-dev 2013-04-05 21:43:31 +00:00
Jeff Brown
4a706bc6f1 Merge "Correctly manage the lifecycle of IME InputChannels." into jb-mr2-dev 2013-04-05 20:57:01 +00:00
Geremy Condra
aa3c81e497 Fix crash in ConfigUpdater when the target dir doesn't exist.
Change-Id: I44ee0e3791938da0bf890fb38cd886330c0ee01d
2013-04-05 13:17:07 -07:00
Daniel Sandler
5feceebb89 New NotificationListenerService.
This is the best and only way for apps to listen for
notifications: create a NotificationListenerService, wait
for the NoMan to bind to you (as a result of the user
checking a box somewhere in Settings and agreeing to a
scary dialog box), and you'll start receiving notification
posted and dismissed callbacks. Your service, while enabled,
will also be able to clear one or all notifications.

Use this power wisely.

This change moves StatusBarNotification out of
com.android.internal into android.service.notification.
[Internal customers, including System UI and early users of
the system-only listener binder API, will need to be
updated.]

Bug: 8199624
Change-Id: I1be46f823d4b3ddc901109ec1e085cd6deb740c2
2013-04-05 19:54:44 +00:00
Ben Gruver
9cc60e81d7 Remove the sender package filter from the intent firewall
Change-Id: I3124c6969984eef646f22216c709bdfb324d6679
2013-04-05 12:20:24 -07:00
Craig Mautner
bab9687e64 Merge "Make the min layer go down through all windows" into jb-mr2-dev 2013-04-05 17:28:08 +00:00
Craig Mautner
4238e3e4b5 Make the min layer go down through all windows
The min layer was set to only show the windows that matched
the specified app token. But that meant when dialogs were
launched it only showed the dialogs and not the background
windows.

Added improved debugging.

fixes bug 8502844.

Change-Id: I26b49568b872801ec9aa088df20317aa752dacd6
2013-04-05 10:26:19 -07:00
Jeff Brown
1951ce86c2 Correctly manage the lifecycle of IME InputChannels.
InputChannels are normally duplicated when sent to a remote process
over Binder but this does not happen if the recipient is running within
the system server process.  This causes problems for KeyGuard because the
InputMethodManagerService may accidentally dispose the channel
that KeyGuard is using.

Fixed the lifecycle of InputChannels that are managed by the IME
framework.  We now return a duplicate of the channel to the application
and then take care to dispose of the duplicate when necessary.
In particular, InputBindResult disposes its InputChannel automatically
when returned through Binder (using PARCELABLE_WRITE_RETURN_VALUE).

Bug: 8493879
Change-Id: I08ec3d13268c76f3b56706b4523508bcefa3be79
2013-04-04 22:45:12 -07:00
Ben Gruver
633dc9bcef Add a config updater component for the intent firewall
Change-Id: I43f6defa16691099592bf87e75f2d1a732135cf3
2013-04-04 19:46:22 -07:00
Michael Wright
c6091c64c9 Pipe through device resolution information
Bug: 8424494
Change-Id: Iafeeee0d5cd29342c1cdc86b9616222aaa5d1b94
2013-04-04 18:10:37 -07:00
Jeff Sharkey
9059d3775a Merge "Nuke heavy parts of notification before archiving." into jb-mr2-dev 2013-04-04 06:09:35 +00:00
Ben Gruver
8c3ee9d50a Merge "Initial implementation of IntentFirewall functionality" into jb-mr2-dev 2013-04-03 23:36:22 +00:00
Nick Kralevich
0d17aaa543 Merge "Grant optional permissions by default for system apps." into jb-mr2-dev 2013-04-03 23:26:28 +00:00
Nick Kralevich
60792852c8 Grant optional permissions by default for system apps.
For pre-installed system apps, automatically grant all optional
permissions.

Change-Id: I99bb320a0bbaa9873baeb63655556fe0fae6f011
2013-04-03 16:17:06 -07:00
Jeff Sharkey
0c1baf9dd6 Nuke heavy parts of notification before archiving.
Bug: 8537938
Change-Id: I2e4eccc3bd6d57fe5cef340d9e67986d78d3be95
2013-04-03 13:08:52 -07:00
Kenny Root
d72317abd7 Remove keystore entries when package removed
Add a hook into PackageManagerService so that when app IDs are
completely removed, we erase all entries from keystore for those UIDs
that have gone away.

(cherry picked from commit 95e3ee3971915b323e5c13dcfe3b12a4180850cd)

Bug: 3020069
Change-Id: I374258ccc103f8cb3e238f2bf0d1afda0659db94
2013-04-03 11:32:52 -07:00
Ben Gruver
4efe9403af Initial implementation of IntentFirewall functionality
This has the full filter functionality, but is currently only
able to block Activity intents. Logging intents, or blocking
service/broadcast intents is not yet implemented.

Change-Id: Ied3d8dedf982e17bcbdff3e328eeb87477954df7
2013-04-02 21:18:41 -07:00
Michael Wright
75e181ddfe Merge "Lock when obtaining the current monitor name." into jb-mr2-dev 2013-04-02 21:01:27 +00:00
Brian Colonna
1eccc0cf5f Merge "FUL now restarts when flipping tablet 180 (bug 7484464)" into jb-mr2-dev 2013-04-02 20:19:24 +00:00
Nick Kralevich
55cfcd7569 Merge "doSignaturePermission -> grantSignaturePermission" into jb-mr2-dev 2013-04-02 19:44:02 +00:00
Nick Kralevich
f667c8d327 Merge "grantPermissionsLPw: introduce isNewPlatformPermissionForPackage" into jb-mr2-dev 2013-04-02 19:43:09 +00:00
Nick Kralevich
5b7d148193 Merge "grantPermissionsLPw: get rid of a level of curly braces" into jb-mr2-dev 2013-04-02 19:41:46 +00:00
Nick Kralevich
bb7ba4ae67 Merge "grantPermissionsLPw: introduce doSignaturePermission" into jb-mr2-dev 2013-04-02 19:40:23 +00:00
Dianne Hackborn
006c633896 Merge "Fix bug in initializing preferred activities." into jb-mr2-dev 2013-04-02 19:01:18 +00:00
Mita Yun
f4c240e68a Fixed a NPE in AccountManagerService
Bug: 8518620
Change-Id: Idf9b5864896ec57c63e3987fc01c73a5c983b5e2
2013-04-02 11:32:27 -07:00
Nick Kralevich
94b8c93789 doSignaturePermission -> grantSignaturePermission
Change-Id: Iee3c24c8ce5ebbd0b0e8cf7b0e308f998fc6eaf9
2013-04-02 09:38:00 -07:00
Nick Kralevich
3337dbf707 grantPermissionsLPw: introduce isNewPlatformPermissionForPackage
Make grantPermissionsLPw by refactoring some code into a new
function, isNewPlatformPermissionForPackage.

No functional changes.

Change-Id: I467dacfe1fcf7e77cef4cb6df54536eeaafd9064
2013-04-02 09:38:00 -07:00
Nick Kralevich
daae541ac3 grantPermissionsLPw: get rid of a level of curly braces
We can get rid of an indention level by modifying an if/else
block slightly.

No functional changes.

Change-Id: I0404093ea9ebe7729417d825afb6e97e158ad23e
2013-04-02 09:38:00 -07:00
Nick Kralevich
35bee33d6f grantPermissionsLPw: introduce doSignaturePermission
Make grantPermissionsLPw smaller by introducing a new doSignaturePermission
function.

Just a refactoring. No functional code changes.

Change-Id: Ia967fd93e3f7cf3e48fcd13be0b04994b76d36f3
2013-04-02 09:38:00 -07:00
Dianne Hackborn
4d491a605e Fix bug in initializing preferred activities.
Now that we are smarter about the initialization, we need
to do this after all packages are scanned.

Change-Id: I598f5ef84dcc83779bbff29e4c92136c63fb32de
2013-04-01 18:10:51 -07:00
Michael Wright
8fa56f60a7 Lock when obtaining the current monitor name.
Also, remove some dead code.

Change-Id: I0e65671f9ca43addd8fc44dcd878bcff2f588e42
2013-04-01 16:46:36 -07:00
Christopher Tate
73882cf489 Merge "debuggerd now notifies the Activity Manager about native crashes" into jb-mr2-dev 2013-04-01 21:22:27 +00:00
Christopher Tate
58d380d2af debuggerd now notifies the Activity Manager about native crashes
The Activity Manager sets up a permission-guarded domain socket, which
debuggerd connects to when a crash happens.  If this is successful,
the daemon then mirrors the logged crash report to that socket, then
closes it.

The Activity Manager parses the native crash dump supplied by debuggerd
and forwards it to the standard app-crashed code.  The UX result is
that users now see the normal "app has stopped unexpectedly" dialog
with "report" and "okay" options for native crashes, not just for
DVM-mediated crashes.

Bug 8322568

Change-Id: Ie1b279896c603bd74d82d6cfcfd66a8f231da134
2013-04-01 13:50:23 -07:00
Amith Yamasani
63fba8c12e Merge "Add new primary accounts to secondary limited users" into jb-mr2-dev 2013-04-01 00:50:00 +00:00
Amith Yamasani
5be347bc52 Add new primary accounts to secondary limited users
When a new account is added to the primary, those will be marked
as shared accounts for secondary limited users. If the secondary user
is currently running, clone the account right away.

Bug: 8510431
Change-Id: Ie8ad87a7205e7b1a5a1752e75fbbfc416b2a58a7
2013-03-31 17:44:31 -07:00
Amith Yamasani
9fd0854d2a Merge "Fix test" into jb-mr2-dev 2013-03-31 02:01:21 +00:00
Amith Yamasani
31c0959b1a Fix test
Change-Id: I329ceff03d3707e10c2e4eabfb8e6ea61082ae6d
2013-03-30 19:00:30 -07:00
Amith Yamasani
42bc734b30 Merge "Block access to accounts for limited users." into jb-mr2-dev 2013-03-31 01:32:39 +00:00
Amith Yamasani
27db46850b Block access to accounts for limited users.
Make sure that apps that have access to restricted accounts can see them.
If they don't have access, they shouldn't be able to add a new account either.
Show an error message in the account picker if the user/app is not authorized.

Change-Id: I117c0b14d7d06c5ac4e66506df156b174567f5f3
2013-03-30 18:25:49 -07:00
Geremy Condra
cac0e0b11b Merge "Add SELinux updater and Settings-based enforcement switch." into jb-mr2-dev 2013-03-30 22:08:20 +00:00
Amith Yamasani
9e8ba8f273 Merge "Improve RestrictionEntry API" into jb-mr2-dev 2013-03-30 01:47:33 +00:00
Amith Yamasani
86118baa4f Improve RestrictionEntry API
More getters and setters, better naming.
New extra defined for returning a custom intent that handles showing the
   restrictions UI.

Change-Id: I2ee0cdb4edd99e71a9004ff5e929dbe243b45557
2013-03-29 17:28:47 -07:00
Geremy Condra
77118fb55e Add SELinux updater and Settings-based enforcement switch.
Bug: 8116902
Change-Id: Ifac495026a354dac7655c28ea2188499a2a319aa
2013-03-29 16:52:56 -07:00
Brian Colonna
b1b9a8ac07 FUL now restarts when flipping tablet 180 (bug 7484464)
When a tablet rotates, FUL must be stopped and restarted in a new
position.  90 degree rotations cause a configuration change, causing
FUL to be automatically reconstructed in the new location.  However,
a 180 degree rotation is not a configuration change, so FUL was not
restarting.  A 180 degree rotation happens more often than one might
think.  If you set the tablet down and later picked it up in the
opposite orientation, FUL would not work prior to this fix.

This change adds a rotation watcher to KeyguardFaceUnlockView.  It
watches for 180 degree rotations and stops and restarts FUL
accordingly.

The rotation watcher callback must be unregistered when
KeyguardFaceUnlockView is recreated (as during 90 degree rotation
changes), otherwise the number of rotation watcher callbacks will keep
growing and they will never go away.  This is a problem not just
because there are many callbacks hanging around, but also because the
old callbacks end up trying to access biometric unlock views that no
longer exist, resulting in crashes.  So, a simple function was added
to the window manager to unregister a rotation watcher.

Change-Id: Ie1ef20a9a22b8f4e39918987dff2b8ad444fcfd1
2013-03-29 18:35:43 -04:00
Dianne Hackborn
a57c695bf2 Reduce duration of rotation xfade animation.
Also add code for tracking how long a rotation takes,
and who is causing it to take that time.

Change-Id: Ie3352ddfddd247f5a5c08f7da6bfe6b4da607ba2
2013-03-29 15:03:18 -07:00