Commit Graph

16149 Commits

Author SHA1 Message Date
Automerger Merge Worker
251a110c45 DO NOT MERGE: Adds artificial package handler latency am: de626c28d7 am: 895d932835
Change-Id: Icbf1e5c7475260bee1c147f92aa328dd29f4fb17
2020-01-27 20:22:29 +00:00
Automerger Merge Worker
895d932835 DO NOT MERGE: Adds artificial package handler latency am: de626c28d7
Change-Id: I5303926e34c973ca9e4a7d12d0f4cd46e2fbcde8
2020-01-27 20:14:59 +00:00
Benedict Wong
1ebbd0bb6b Merge changes from topic "add-ikev2-vpn-types"
am: adb79e3b39

Change-Id: I205121bbd8ef8adbe5e7a5ea1c57bbcac0efae0e
2020-01-22 22:09:41 -08:00
Benedict Wong
50b444359e Add VpnManger API surface
This change adds the VpnManager, which will be used by apps to install
profiles for all platform VPN types (currently only IKEv2).

Bug: 143325939
Test: Compiles, FrameworksNetTests passing.
Change-Id: I57f854d0a5b18358f3541c24ca0cd8aed03fd7a1
2020-01-22 19:24:24 -08:00
Cody Kesting
45e0caf5dc Merge changes from topic "connectivity-diagnostics-system-server"
am: 9cd249c11a

Change-Id: I48a9f1f734b5e2dd4f7ed91c052cec5c8c62c076
2020-01-22 19:10:05 -08:00
Cody Kesting
9cd249c11a Merge changes from topic "connectivity-diagnostics-system-server"
* changes:
  Add ConnectivityDiagnosticsManager to System Server.
  Make DataStallReport Parcelable.
  Make ConnectivityReport Parcelable.
2020-01-23 01:56:33 +00:00
Benedict Wong
418b97e5db Merge "Add new appop for Platform VPNs"
am: b8dd5bcc23

Change-Id: Ia44f9491f3951e3f7dda2c03e5d33452bb2e94d3
2020-01-21 20:39:02 -08:00
Benedict Wong
d040b254c5 Add new appop for Platform VPNs
This change introduces a new appop, ACTIVATE_PLATFORM_VPN, that is a
subset of the ACTIVATE_VPN appop. VPN apps that have been granted the
more dangerous ACTIVATE_VPN appop should be allowed to use platform
VPNs, as they are more restricted, and safer. However, the opposite
must not be true.

Bug: 144246835
Test: Compiles, FrameworksNetTests passing
Change-Id: I609e87e688432f957751058b09f350fa641753d7
Merged-In: I609e87e688432f957751058b09f350fa641753d7
2020-01-22 04:30:23 +00:00
Cody Kesting
b125776009 Add ConnectivityDiagnosticsManager to System Server.
ConnectivityDiagnosticsManager should be accessed through
Context#getService. In order for this to be possible, it needs to be
defined as a service inside SystemServiceRegistry.

Bug: 146444622
Test: compiles.
Test: CTS testing in aosp/1211164
Change-Id: I6fe29441ecc9967a04ceb394b3bbe54830bef079
2020-01-21 08:31:56 -08:00
Hall Liu
5dacbd482d Merge "Expose NotificationChannel#setBlockableSystem as SystemApi"
am: f3b914bd02

Change-Id: I63c8cc69791e1c3231b7e79584b383e5e6653f98
2020-01-17 13:09:53 -08:00
Hall Liu
f3b914bd02 Merge "Expose NotificationChannel#setBlockableSystem as SystemApi" 2020-01-17 20:25:50 +00:00
Hall Liu
b12609a432 Expose NotificationChannel#setBlockableSystem as SystemApi
Expose setBlockableSystem as a module-apps-only SystemApi.

Bug: 138401571
Test: atest android.app.cts.NotificationChannelTest
Change-Id: I0b6a14360e9278a092476ada6533e63a46d4e4fe
Merged-In: I0b6a14360e9278a092476ada6533e63a46d4e4fe
2020-01-16 17:43:10 -08:00
Xin Li
e13851556b DO NOT MERGE - Merge qt-qpr1-dev-plus-aosp-without-vendor (6129114) into stage-aosp-master
Bug: 146167222
Change-Id: Ifeb003ec9b3bf824f04d31a117aea65d517241fb
2020-01-15 16:15:41 -08:00
Philip P. Moltmann
47cc84875c DO NOT MERGE Fix AppOpsServiceTest
am: c03b32c406

Change-Id: Icb334aaa1f7a6ad6815fb034bbac27f3ace09cdb
2020-01-15 11:08:21 -08:00
Treehugger Robot
e88817bd42 Merge changes Ie816e0c6,I5b94e92a,I5391ac49,If074bed1
* changes:
  DO NOT MERGE Fix AppOpsServiceTest
  DO NOT MERGE Don't throw exception in AppOpsManager.checkOp
  DO NOT MERGE Remove unnecessary internal APIs.
  DO NOT MERGE SetMode: Don't call into PM with AppOps lock held
2020-01-15 19:01:15 +00:00
Neil Fuller
e9dafe541e Merge "Expose time / time zone system apis for telephony" 2020-01-15 16:19:16 +00:00
Treehugger Robot
d63ebcf807 Merge "DevicePolicyManager: annotate SystemApi" 2020-01-15 06:37:55 +00:00
Philip P. Moltmann
73e2690ede DO NOT MERGE Remove unnecessary internal APIs.
Test: Built
Bug: 146463528
Bug: 146590200
Bug: 147649036
Change-Id: I5391ac4989d7d5712982f5608f9fc28cf7935b00
2020-01-14 19:42:44 +00:00
Neil Fuller
efe063e5dc Expose time / time zone system apis for telephony
Expose system apis / permissions needed by the telephony module to
communicate with the system server for time and time zone detection.

There are also small improvements for @Nullable.

Bug: 147012511
Test: build only
Merged-In: I27e5aa4c594d5fbad0b6f043afb9e910dcba4349
Change-Id: I27e5aa4c594d5fbad0b6f043afb9e910dcba4349
(cherry picked from commit 2be7ac4531)
2020-01-14 19:30:40 +00:00
Remi NGUYEN VAN
fe1ce1e047 Add NETWORK_STACK_SERVICE to SystemServiceRegistry
The service is already registered in ServiceManager. It needs to be
accessible from SystemServiceRegistry so that other mainline modules
can communicate with it.

Bug: 147255753
Test: Dependent CLs using the service
Change-Id: I940c62064466c3b3b8d2a195b810e90eaade7e6c
Merged-In: I940c62064466c3b3b8d2a195b810e90eaade7e6c
2020-01-14 02:17:54 +00:00
Philip P. Moltmann
01883f3d02 DO NOT MERGE Remove unnecessary internal APIs.
Test: Built
Bug: 146463528
Bug: 146590200
Change-Id: I5391ac4989d7d5712982f5608f9fc28cf7935b00
2020-01-13 12:41:17 -08:00
junyulai
80831d2ff3 [SP03] support registerNetworkStatsProvider API
This change provides an API that allow external modules to
register a custom provider of NetworkStats to merge the
network statistics that cannot be seen by the kernel to system.

Test: atest FrameworksNetTests CtsUsageStatsTestCases
Test: atest NetworkPolicyManagerServiceTest
Test: m doc-comment-check-docs
Bug: 130855321

Change-Id: I265bc637c40666cde505fde5056d2d9bfc5fb204
2020-01-13 14:43:03 +08:00
junyulai
232b2edcfb [SP03.1] Replace com.android.internal.util.Preconditions.checkNotNull
Extracted from ag/9990011 to make NetworkStatsManager sync with internal
line, given that it is missing in aosp/1198084.

Bug: 126528330

Test: Treehugger
Change-Id: I77f50326869799f51d4636cb7c6d7c97daf531e6
Merged-In: I42117ebfb640e3b0b133183e5e146860bed8471a
2020-01-13 14:42:37 +08:00
Automerger Merge Worker
aa58c0d5c3 Merge "Rename android.util.TimestampedValue to android.os" am: 641fa6730a am: fee904a5fb
Change-Id: Ib439759dbee692a624491267d07f72b0d754779d
2020-01-10 09:18:38 +00:00
Neil Fuller
641fa6730a Merge "Rename android.util.TimestampedValue to android.os" 2020-01-10 08:11:14 +00:00
Automerger Merge Worker
b615fa46c9 Merge "Use new UnsupportedAppUsage annotation." am: 70129fc863 am: fe3063fb71
Change-Id: Iea82f97f0ba766ce3f435630175aea48ca47f12f
2020-01-09 16:15:31 +00:00
Neil Fuller
35cc296228 Rename android.util.TimestampedValue to android.os
Rename android.util.TimestampedValue to android.os to avoid dependency
from android.util onto android.os, which is disallowed by lint.

Bug: 147012511
Test: boot
Merged-In: I4b84db03c8ad24bbef63e45d6d15fb306a10364e
Change-Id: I4b84db03c8ad24bbef63e45d6d15fb306a10364e
(cherry picked from commit d159015e54)
2020-01-09 15:34:43 +00:00
Artur Satayev
d9b11b058c Use new UnsupportedAppUsage annotation.
Existing annotations in libcore/ and frameworks/ will deleted after the migration. This also means that any java library that compiles @UnsupportedAppUsage requires a direct dependency on "unsupportedappusage" java_library.

Bug: 145132366
Test: m && diff unsupportedappusage_index.csv
Change-Id: I8789f8499d4dca08580672e9e45ed9a7026dd686
Merged-In: I8789f8499d4dca08580672e9e45ed9a7026dd686
2020-01-09 13:56:05 +00:00
Automerger Merge Worker
e219088375 Merge "Add setDisabledForSimNetworkLock to StatusBarManager" am: f428f58080 am: 33d3e85975
Change-Id: Id3ea80c30e149588a6d97f02df978f258dda3495
2020-01-08 21:13:09 +00:00
Hall Liu
f428f58080 Merge "Add setDisabledForSimNetworkLock to StatusBarManager" 2020-01-08 20:54:48 +00:00
Automerger Merge Worker
ef100e45fe Merge "Change NetworkTimeUpdateServiceImpl behavior" am: 48247d9223 am: f11a45b756
Change-Id: Ie3b6457ba196f7aa00ffb6e2fa77e5acbb926374
2020-01-07 10:30:35 +00:00
Neil Fuller
48247d9223 Merge "Change NetworkTimeUpdateServiceImpl behavior" 2020-01-07 10:07:08 +00:00
Automerger Merge Worker
cccf7a2b84 Merge "Clean up SmsApplication and expose getDefaultSmsPackage" am: 2ada7fbac2 am: b128b793c7
Change-Id: Icee2c41d635883c6b9ede6bf6ec3bbfda22cdc1f
2020-01-07 01:01:54 +00:00
Hall Liu
2ada7fbac2 Merge "Clean up SmsApplication and expose getDefaultSmsPackage" 2020-01-07 00:36:51 +00:00
Hall Liu
9ded659a50 Add setDisabledForSimNetworkLock to StatusBarManager
Add a new @SystemApi disable utility method to allow telephony's
mainline module to disable the status bar when the device is SIM-locked

Bug: 146834818
Bug: 138956541
Test: atest StatusBarManagerTest
Change-Id: Id3757fc560c5b70bed553f19b050524a024b4c78
2020-01-06 15:47:45 -08:00
Automerger Merge Worker
ec776dfda9 Merge "Add new permissions" am: 62ace8c46a am: c0f9b27214
Change-Id: I2114c613729f0d84d773b7e8b58402cda302a8c8
2020-01-06 21:20:53 +00:00
Neil Fuller
62ace8c46a Merge "Add new permissions" 2020-01-06 19:38:25 +00:00
Automerger Merge Worker
fe03e4c510 docs: Fix typo in IMPORTANCE_SERVICE description am: 08a4e470b8 am: edcfda720b am: fc94ebae09
Change-Id: I24a825364458eafd6d101d47a1cd467d7401cc42
2020-01-06 18:41:36 +00:00
Automerger Merge Worker
fc94ebae09 docs: Fix typo in IMPORTANCE_SERVICE description am: 08a4e470b8 am: edcfda720b
Change-Id: Id0683ebab467f7baaac1650b15dd8e98f8057306
2020-01-06 18:24:58 +00:00
Automerger Merge Worker
edcfda720b docs: Fix typo in IMPORTANCE_SERVICE description am: 08a4e470b8
Change-Id: I32360f63be584c4223c6aae692beb48c0bdf4802
2020-01-06 18:13:01 +00:00
Kevin Hufnagle
08a4e470b8 docs: Fix typo in IMPORTANCE_SERVICE description
Test: make ds-docs -j32

Bug: 140783404

Change-Id: Ife86109eebefe9c87f7c9ed4a0587676e3392d90
Exempt-From-Owner-Approval: Docs-only change
2020-01-03 20:05:31 +00:00
Automerger Merge Worker
bbce9e0c5a Merge "Use ro.product.vndk.version for unbundled product apks" am: cbfcd44f68 am: e0e165f06e
Change-Id: I6507b31c3a1b36830a231064e560d978b9427f5c
2020-01-03 07:36:52 +00:00
Justin Yun
1ef374f98b Use ro.product.vndk.version for unbundled product apks
Instead of using "ro.product.apps.unbundled", use
"ro.product.vndk.version" to determine if product apks are unbundled.
"ro.product.vndk.version" will be defined by
PRODUCT_PRODUCT_VNDK_VERSION. If it is defined, all product apks must
be unbundled.

Bug: 144534640
Bug: 127738095
Bug: 128557860
Test: boot and check logs if product apps are loaded successfully
Change-Id: I6d0f7c20e131dfe12203c63a14e6254a8223893b
2020-01-02 06:30:02 +00:00
Hall Liu
35c243caa4 Clean up SmsApplication and expose getDefaultSmsPackage
- Clean up usages of hidden AppOpsManager APIs in SmsApplication
- Add unit tests for SmsApplication
- Expose RoleManager#getDefaultSmsPackage for use in SmsApplication.

Bug: 146834818
Test: atest SmsApplicationTest
Change-Id: I4ab49d7f6274389e7de7cd7223cab3c433936044
2019-12-31 14:41:02 -08:00
Automerger Merge Worker
08074c62b0 Merge "[Tether13] Move TetheringManager into framework" am: 2410d67357 am: 25cc1f47c5
Change-Id: I9ec25eb984e3b534ddcc9313836a319b21526998
2019-12-20 14:00:29 +00:00
Neil Fuller
4ab8a199de Change NetworkTimeUpdateServiceImpl behavior
This change moves some logic associated with time detection out of the
NetworkTimeUpdateServiceImpl and moves it to the TimeDetectorStrategy
called by the TimeDetectorService.

The TimeDetectorStategy implementation now decides when to use an
NTP-derived time instead. The logic implemented here is effectively the
same as it was: NITZ takes priority over NTP until the latest NITZ
signal becomes "too old".

The motivating reasons for the change:
1) The "what signal is used when several are available?" logic should be
in one place: the TimeDetectoryStrategy not scattered around the
platform. Centralizing will enable different strategies and time sources
to be introduced over time.

2) It will allow removal of the ACTION_NETWORK_SET_TIME intent in a
follow-up commit; this intent was used to coordinate the NTP vs NITZ
logic should no longer be required.

The "bonus" effect of this change is that NetworkTimeUpdateServiceImpl
becomes more general: It can now be the authority for the NTP time on a
device independently of how the system clock should be set. e.g. it
could be used in future to back the
AlarmManager.currentNetworkTimeMillis() API call.  Anything that needs a
"what is the best time according to NTP?" answer could use this service.

Note: The NetworkTimeUpdateServiceImpl still observes the AUTO_TIME
setting and will perform an NTP lookup "on demand" (if required) when
the user enables the setting. This should be a temporary state and
likely to be removed in future; knowledge of AUTO_TIME shouldn't be
required for the NTP info to be correct and if
NetworkTimeUpdateServiceImpl is doing the right thing.

Bug: 140712361
Test: atest com.android.server.timedetector
Test: atest android.app.timedetector
Change-Id: I4b2936a42c552c4dd4cb55010306bb81bca0c712
2019-12-19 19:21:47 +00:00
markchien
6d06f6d51a [Tether13] Move TetheringManager into framework
Move tethering out of ConnectivityService. All client would
use TetheringManager to talk with TetheringService directly.

Bug: 144320246
Test: -build, flash, boot
      -atest TetheringTests

Change-Id: Ib051bea724a256f9c4572b566e46ae7b9c4abe6e
Merged-In: Ib051bea724a256f9c4572b566e46ae7b9c4abe6e
2019-12-19 20:53:06 +08:00
Neil Fuller
09e8b7d841 Add new permissions
This adds new permissions required when setting the time /zone in
response to telephony signals and when setting the time / zone manually
along the lines of "principle of least privilege".

The intent is to later restrict the number of distinct processes that
can manipulate the device system clock / time zone property directly so
that all time changes go through the time / time zone detector services,
which can enforce policy, log the reasons for changes, and so on.

Bug: 140712361
Test: atest com.android.server.timedetector
Change-Id: Iabd3a5f449ad2ef2b6581475ef2535a4a8a88ef9
2019-12-19 11:11:48 +00:00
Patrick Baumann
de626c28d7 DO NOT MERGE: Adds artificial package handler latency
This change introduces a means of introducing an artificial long task to
the package handler to help reproduce timing issues related to it.

Bug: 141413692
Test: atest PackageManagerTest
Change-Id: I61ddee1fe8b94f5803d981a77babb4bb19e31662
2019-12-18 20:15:26 +00:00
Automerger Merge Worker
fb829df378 Merge "[RCS] Add IMS service into system service registry" am: 6a1d13f58e am: a962a65575
Change-Id: I61549d3d4da7ffdf5f2d497e52cd7a2fdd0f2c05
2019-12-17 00:10:51 +00:00