Commit Graph

4802 Commits

Author SHA1 Message Date
Pavel Maltsev
518c3decff Merge "Add OEM_PAID capability to system api" into pi-dev
am: 62e4efeee2

Change-Id: Ic164c4a29cd449a31b2f1c12c8c345bcc5dc77fa
2018-03-30 18:30:23 +00:00
Jeff Sharkey
6c5e373f30 Merge "API council requested tweaks to NetworkRequest." into pi-dev
am: 66b0087e58

Change-Id: I0d090ebb7d57689a061badcf593ae9a37d88f7ce
2018-03-30 18:22:13 +00:00
Pavel Maltsev
62e4efeee2 Merge "Add OEM_PAID capability to system api" into pi-dev 2018-03-30 16:32:52 +00:00
Jeff Sharkey
66b0087e58 Merge "API council requested tweaks to NetworkRequest." into pi-dev 2018-03-30 16:30:24 +00:00
Paul Jensen
ef15944d4f Merge "Fix socket leaks in various android.net.Network methods." into pi-dev
am: 4baa5d48e3

Change-Id: I2a2254ce65c2176ae0be1d6276034b1bb0cad987
2018-03-30 16:22:51 +00:00
Chalard Jean
6d4976a3b8 Merge "Limit the number of routes for performance" into pi-dev
am: 3957f6dc0d

Change-Id: Ida402ad8f864400561bba0e07cfd5fe766ee08bd
2018-03-30 16:10:31 +00:00
Chalard Jean
a20d1d7ff3 Merge "Clarify documentation for getActiveNetworkInfo and friends" into pi-dev
am: 7db624228a

Change-Id: Iab75c8d432ca68031bcf7cbf22baf8269169a908
2018-03-30 16:05:29 +00:00
Remi NGUYEN VAN
2f940f48f5 [automerger skipped] Merge "Allow null subscriberId in NetworkStatsManager." into pi-dev
am: d1b38d88cd  -s ours

Change-Id: I6e8983cc087a8a42e1404bb5f99bcd297b0ff313
2018-03-30 15:55:32 +00:00
Lorenzo Colitti
9e0b6ce895 Merge "Add Network.fromNetworkHandle()" into pi-dev
am: c0b767a937

Change-Id: I22e68ab29982690dee5b2c0c6e1fbd47df0b0326
2018-03-30 14:55:48 +00:00
TreeHugger Robot
4baa5d48e3 Merge "Fix socket leaks in various android.net.Network methods." into pi-dev 2018-03-30 09:47:51 +00:00
Lorenzo Colitti
1f594309aa Merge "Mark networks with OEM_PAID always restricted" am: 99613ff80b
am: 88650629fa

Change-Id: I88500f6add4f1a6c8a77eb976a489c11c7dc5b6d
2018-03-30 09:05:09 +00:00
Chalard Jean
cc039fddf8 Merge "Limit the number of routes for performance" am: 9b4dc28bd3
am: 782450b691

Change-Id: I1fcf34b553b4a7cbadd0a2a7bf697140e948243e
2018-03-30 08:58:44 +00:00
Chalard Jean
ef6b974a62 Merge "Clarify documentation for getActiveNetworkInfo and friends" am: a47ebd7f70
am: fc45f0749c

Change-Id: I339bb71182723907ed078e8be739c4d4ea2d1da5
2018-03-30 08:51:38 +00:00
TreeHugger Robot
3957f6dc0d Merge "Limit the number of routes for performance" into pi-dev 2018-03-30 08:48:25 +00:00
Lorenzo Colitti
88650629fa Merge "Mark networks with OEM_PAID always restricted"
am: 99613ff80b

Change-Id: I4ffcf01e1f79c8a3570ea2b819688b55904939fe
2018-03-30 08:47:25 +00:00
Chalard Jean
782450b691 Merge "Limit the number of routes for performance"
am: 9b4dc28bd3

Change-Id: If4de2779b24560f75a7bb977dbb0f996115a0648
2018-03-30 08:42:42 +00:00
Chalard Jean
fc45f0749c Merge "Clarify documentation for getActiveNetworkInfo and friends"
am: a47ebd7f70

Change-Id: I167776fb6ec44aff4b35b58378b54e3b55907427
2018-03-30 08:36:58 +00:00
TreeHugger Robot
7db624228a Merge "Clarify documentation for getActiveNetworkInfo and friends" into pi-dev 2018-03-30 08:22:29 +00:00
Lorenzo Colitti
63c49de81c Merge "Require explicitly supplied truncation length" am: 83f01be8d5
am: 8c65f40004

Change-Id: I347bfd43be54d162dea831770ab08d792ea1443f
2018-03-30 07:45:04 +00:00
Remi NGUYEN VAN
d1b38d88cd Merge "Allow null subscriberId in NetworkStatsManager." into pi-dev 2018-03-30 07:39:23 +00:00
Lorenzo Colitti
99613ff80b Merge "Mark networks with OEM_PAID always restricted" 2018-03-30 07:00:54 +00:00
Pavel Maltsev
fa0f612d29 Mark networks with OEM_PAID always restricted
Bug: 68762530
Exempt-From-Owner-Approval: OWNERS have approved, but gerrit doesn't see it
Test: runtest -x frameworks/base/tests/net/ -c android.net.NetworkCapabilitiesTest
Change-Id: Ieadef7c42634d890281543226203530fb18eb0a3
2018-03-30 07:00:39 +00:00
Lorenzo Colitti
8c65f40004 Merge "Require explicitly supplied truncation length"
am: 83f01be8d5

Change-Id: I20f7f910f4f0369e38eebd0b7fe6970331763e85
2018-03-30 06:48:22 +00:00
Lorenzo Colitti
4424759827 Merge "Clarify UDP encapsulation socket API" am: b676aef03c
am: 9ef3a6cf3f

Change-Id: I5fcf79691c670e710e46b3a9eac8a580c44028fb
2018-03-30 06:48:17 +00:00
Chalard Jean
e876507ce9 Limit the number of routes for performance
In evaluating whether "most" of the addressing space is
covered, the list of routes are obtained from a third-party
app, so it's possbile the system service stalls unless
some limit is enforced on how much work it has to do.
This change limits the number of routes to 400, as determined
by time measurement on various devices.

Bug: 74176086
Test: runtest framework-net
Change-Id: Ie4a96098bc044ade87b188839586f14dd101c100
2018-03-30 15:41:50 +09:00
Chalard Jean
9b4dc28bd3 Merge "Limit the number of routes for performance" 2018-03-30 06:40:29 +00:00
Chalard Jean
a47ebd7f70 Merge "Clarify documentation for getActiveNetworkInfo and friends" 2018-03-30 06:37:22 +00:00
Lorenzo Colitti
9ef3a6cf3f Merge "Clarify UDP encapsulation socket API"
am: b676aef03c

Change-Id: Ie1e7ea81440afee2618211d989989cf5daff3e1e
2018-03-30 06:35:22 +00:00
Lorenzo Colitti
83f01be8d5 Merge "Require explicitly supplied truncation length" 2018-03-30 04:59:22 +00:00
Lorenzo Colitti
b676aef03c Merge "Clarify UDP encapsulation socket API" 2018-03-30 04:58:47 +00:00
Chalard Jean
7c85ba400c Clarify documentation for getActiveNetworkInfo and friends
For VPNs it's unobvious what these methods do, so document that.

Bug: 70917007
Test: Comment changes only. Checkdoc passes.
Change-Id: I31ec1aea356d88d969eaf9fc7d8c2ed13ce924eb
2018-03-30 12:22:06 +09:00
Remi NGUYEN VAN
42e2185505 Allow null subscriberId in NetworkStatsManager.
Use a MATCH_MOBILE_WILDCARD template to avoid filtering by
subscriberId when querying statistics from NetworkStatsService.

Bug: 74038898
Change-Id: I8296220472a9ba37044dd1a5ede9bdb45d3ed339
Fixes: 74038898
Test: runtest frameworks-net, CTS tests pass
Merged-In: I1e4e283c6eaecf33d12488e41e0c524f6ff83954
Merged-In: Ia84d2c7cc63bf8b8bf30f133e0382fd7103bf490
(cherry-picked from aosp I4b39e7031416cb33b23d89aa36ff0f774eaa942f)
2018-03-30 12:18:23 +09:00
Paul Jensen
75184ed674 Fix socket leaks in various android.net.Network methods.
Bug: 72124526
Test: make CtsNetTestCases
Change-Id: I3398b67272360f894e01a8cdfbc47b17d77c2330
2018-03-29 07:43:01 -04:00
Paul Jensen
bcf88e4576 Add Network.fromNetworkHandle()
This is the counterpart to Network.getNetworkHandle() and facilitates
native code calling back to Java with network handle values from
getNetworkHandle.

Bug: 77210159
Bug: 64148938
Test: make CtsNetTestCases

Change-Id: I032b959d84180c063a79ddd97c35e7384b0f50a1
2018-03-29 07:24:59 -04:00
Chalard Jean
0764935893 Limit the number of routes for performance
In evaluating whether "most" of the addressing space is
covered, the list of routes are obtained from a third-party
app, so it's possbile the system service stalls unless
some limit is enforced on how much work it has to do.
This change limits the number of routes to 400, as determined
by time measurement on various devices.

Bug: 74176086
Test: runtest framework-net
Change-Id: Ie4a96098bc044ade87b188839586f14dd101c100
2018-03-29 18:13:23 +09:00
Chalard Jean
ba7a3467fd Clarify documentation for getActiveNetworkInfo and friends
For VPNs it's unobvious what these methods do, so document that.

Bug: 70917007
Test: Comment changes only. Checkdoc passes.
Change-Id: I31ec1aea356d88d969eaf9fc7d8c2ed13ce924eb
2018-03-29 18:10:56 +09:00
Remi NGUYEN VAN
12cfe2edc0 Merge "Fix network usage stats on 464xlat tethered." am: 83088dcd8e
am: 10cb43f1de

Change-Id: I016722f3a0ae2ae0a1d48bfacc4fe07ee3578ef7
2018-03-29 07:46:34 +00:00
Remi NGUYEN VAN
10cb43f1de Merge "Fix network usage stats on 464xlat tethered."
am: 83088dcd8e

Change-Id: I0e13c2a6b9f6b5d0701a073ddc835781d5d2aace
2018-03-29 07:36:21 +00:00
Benedict Wong
b0571f55db Require explicitly supplied truncation length
Instead of providing default truncation lengths (based on RFC or
otherwise), this change imposes a restriction that the truncation length
must be supplied for all auth or aead algorithms.

Bug: 77204048
Test: Updated tests, ran on walleye
Change-Id: I4a0e2e71aa97259e56f44e7c8a2ce53135708d97
2018-03-28 18:02:54 -07:00
Jeff Sharkey
fc5a07fe83 API council requested tweaks to NetworkRequest.
If you put values into the Builder, you should be able to observe
those values on the built object.

Test: atest android.net.cts.NetworkRequestTest
Bug: 74945408
Change-Id: I9aacceb82c98f7881f0eb5e1106d89d469b816a7
2018-03-28 14:02:00 -06:00
Pavel Maltsev
0b2e0b0280 Add OEM_PAID capability to system api
Some system apps should be able to request OEM_PAID networks.  This
makes a lot of sense when Android is used as in-vehicle infotainment
systems.

Bug: 68762530

Test: runtest -x frameworks/base/tests/net/ -c android.net.NetworkCapabilitiesTest

Change-Id: Ic916de7522a9f803a2410bc4e3e82101fd9d0dbd
2018-03-27 23:17:14 -07:00
Pavel Maltsev
093afe8b8e Merge "Merge "Minor clean-up in NetworkCapabilities" am: 98dc002acc am: 6d8274ebf1 am: fbb48a210f" into pi-dev
am: 601861fd1c

Change-Id: I6605aad319ea268827f47d95fb6aef7c4c07ae93
2018-03-28 05:28:17 +00:00
Remi NGUYEN VAN
dbee0f8554 Fix network usage stats on 464xlat tethered.
Usage stats corrections for 464xlat in NetworkStatsFactory are not applied
to tethered traffic. Add adjustments in NetworkStatsService. After
migrating external callers off NetworkStatsFactory, we will be able to
only apply adjustments in NetworkStatsService and remove stacked
interface tracking from NetworkStatsFactory.
Bug: 72107146
Fixes: 72107146
Test: runtest frameworks-net & manual - checked corrected network usage

Change-Id: I5ce450e616b4fddf21f2a491fe5d0c9e9f969bda
2018-03-28 12:14:14 +09:00
Benedict Wong
9660f605b6 Clarify UDP encapsulation socket API
This change updates the getSocket() methods for IPsec to improve clarity
of the return types, both for public APIs, and internal-only methods.

Bug: 72473753
Test: APIs updated, CTS + unit tests ran.
Change-Id: I0afebd432c5d04c47c93daa1ce616d712aa323d7
2018-03-27 19:46:50 -07:00
Pavel Maltsev
3585034ec9 Merge "Minor clean-up in NetworkCapabilities" am: 98dc002acc am: 6d8274ebf1
am: fbb48a210f

Bug: 72828388
Test: frameworks/base/tests/net/ -c android.net.NetworkCapabilitiesTest

Change-Id: I2f45d2c70c7c0142ae3b3ce9e6329c5f25b63380
(cherry picked from commit feb8d1498a822730e29cf346fe3382e3f5293a58)
2018-03-27 22:45:49 +00:00
Tony Mak
e589c20e3c Merge "Get application info in the correct user id" into pi-dev
am: d5bff7f0dd

Change-Id: I763a8fae339cb9ca56b713c695d3e97e3c46c3d5
2018-03-26 17:15:29 +00:00
Tony Mak
d5bff7f0dd Merge "Get application info in the correct user id" into pi-dev 2018-03-26 17:04:47 +00:00
Ricky Wai
a635ed5a99 Merge "Improve ConnectivityManager.getNetworkWatchlistConfigHash() javadoc" into pi-dev
am: 9bf657d1e7

Change-Id: Ic3de4d136a995a8291fb43c780a311e423aeb9b7
2018-03-26 17:01:45 +00:00
Michael West
dd1f48c399 Merge "add airplane mode shell commands to connectivity" into pi-dev
am: 83c1f9e33b

Change-Id: I81fd444f1364c394d17759c261798b3a3f85b826
2018-03-26 16:51:00 +00:00
Ricky Wai
9bf657d1e7 Merge "Improve ConnectivityManager.getNetworkWatchlistConfigHash() javadoc" into pi-dev 2018-03-26 16:46:20 +00:00