<feed xmlns='http://www.w3.org/2005/Atom'>
<title>frameworks_base/tests, branch replicant-10</title>
<subtitle>Fork of frameworks/base
</subtitle>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/'/>
<entry>
<title>Merge "Fix PermissionMonitor issues" into qt-dev am: 97baed2635</title>
<updated>2020-01-09T05:59:27+00:00</updated>
<author>
<name>Automerger Merge Worker</name>
<email>android-build-automerger-merge-worker@system.gserviceaccount.com</email>
</author>
<published>2020-01-09T05:59:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=cd35d79a7cd3594c58d244fa595cf87a9ea5063d'/>
<id>cd35d79a7cd3594c58d244fa595cf87a9ea5063d</id>
<content type='text'>
Change-Id: Ia955c4304c2e623b291c111615c65f012b7c3028
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Change-Id: Ia955c4304c2e623b291c111615c65f012b7c3028
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge "Fix parceling of LinkProperties Inet6Addr" into qt-qpr1-dev</title>
<updated>2019-12-20T08:27:55+00:00</updated>
<author>
<name>Remi NGUYEN VAN</name>
<email>reminv@google.com</email>
</author>
<published>2019-12-20T08:27:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=6b6a9b1972af44deae1e8f8d5e9d321e2870f981'/>
<id>6b6a9b1972af44deae1e8f8d5e9d321e2870f981</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix parceling of LinkProperties Inet6Addr</title>
<updated>2019-12-19T08:55:00+00:00</updated>
<author>
<name>Automerger Merge Worker</name>
<email>android-build-automerger-merge-worker@system.gserviceaccount.com</email>
</author>
<published>2019-12-19T03:29:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=92b21561384738ca113e9e728600e4876b946c9e'/>
<id>92b21561384738ca113e9e728600e4876b946c9e</id>
<content type='text'>
IPv6 addresses parceled for DNS servers, private DNS servers, PCSCF
servers were parceled without the scope. This causes issues with
link-local DNS servers.

Test: atest FrameworksNetTests
Bug: 145181158
(cherry picked from commit 091f1d790cffc7c0d3ea8c85f540755584df4077)
Merged-In: Ie5b7782d788717dd1cc440e502d6cdf2d1c18eaa

Change-Id: I51313f50de8220988c2c1d26981c27d07dfb55f9
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
IPv6 addresses parceled for DNS servers, private DNS servers, PCSCF
servers were parceled without the scope. This causes issues with
link-local DNS servers.

Test: atest FrameworksNetTests
Bug: 145181158
(cherry picked from commit 091f1d790cffc7c0d3ea8c85f540755584df4077)
Merged-In: Ie5b7782d788717dd1cc440e502d6cdf2d1c18eaa

Change-Id: I51313f50de8220988c2c1d26981c27d07dfb55f9
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix PermissionMonitor issues</title>
<updated>2019-12-19T05:43:40+00:00</updated>
<author>
<name>Paul Hu</name>
<email>paulhu@google.com</email>
</author>
<published>2019-11-25T18:35:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=9352cb24b1afaec657faeffdb0d40ed96d4d912b'/>
<id>9352cb24b1afaec657faeffdb0d40ed96d4d912b</id>
<content type='text'>
PermissionMonitor#hasPermission only checks permssions that app
requested but it doesn't check whether the permission can be
granted to this app. If requested permission doens't be granted
to app, this method still returns that app has this permission.
Then PermissionMonitor will pass this info to netd that means
this app still can use network even restricted network without
granted privileged permission like CONNECTIVITY_INTERNAL or
CONNECTIVITY_USE_RESTRICTED_NETWORKS.

PermissionMonitor#hasUseBackgroundNetworksPermission only uses
the first package name of the uid for checking permission.
This is incorrect since each package declared different
permissions. So using the mApps which already checked both
network and using restricted network permissions. If uid is in
the mApps list that means uid has one of permission at least.

Bug: 144679405
Test: Build, flash, manual test
      atest FrameworksNetTests

Change-Id: I2da730feda4d7ebed1f158b073167bb3964b3e7d
Merged-In: I8b03c9e23ffc9ff46264d6307fb841a7eda76a76
Merged-In: Ib08a940a6e5d3365c392ab7174d8484c197e0947
(cherry picked from commit 2e1da35b3b903f4aa01435c46b7014b88a41328d)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
PermissionMonitor#hasPermission only checks permssions that app
requested but it doesn't check whether the permission can be
granted to this app. If requested permission doens't be granted
to app, this method still returns that app has this permission.
Then PermissionMonitor will pass this info to netd that means
this app still can use network even restricted network without
granted privileged permission like CONNECTIVITY_INTERNAL or
CONNECTIVITY_USE_RESTRICTED_NETWORKS.

PermissionMonitor#hasUseBackgroundNetworksPermission only uses
the first package name of the uid for checking permission.
This is incorrect since each package declared different
permissions. So using the mApps which already checked both
network and using restricted network permissions. If uid is in
the mApps list that means uid has one of permission at least.

Bug: 144679405
Test: Build, flash, manual test
      atest FrameworksNetTests

Change-Id: I2da730feda4d7ebed1f158b073167bb3964b3e7d
Merged-In: I8b03c9e23ffc9ff46264d6307fb841a7eda76a76
Merged-In: Ib08a940a6e5d3365c392ab7174d8484c197e0947
(cherry picked from commit 2e1da35b3b903f4aa01435c46b7014b88a41328d)
</pre>
</div>
</content>
</entry>
<entry>
<title>Add package failure flags to Package Watchdog</title>
<updated>2019-12-18T14:39:12+00:00</updated>
<author>
<name>Gavin Corkery</name>
<email>gavincorkery@google.com</email>
</author>
<published>2019-11-27T15:46:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=cdc5524f79ecbd6e7052e0526aa2ea2d7a086c58'/>
<id>cdc5524f79ecbd6e7052e0526aa2ea2d7a086c58</id>
<content type='text'>
This is a prerequisite for adding additional logging of
the Watchdog-triggered rollback reason. Add flags which
indicate the failure observed (native, crash, ANR, explicit
health check). These will be used in the future by
RollbackPackageHealthObserver to map the failure type to the
(new) set of available logging metrics.

Test: atest PackageWatchdogTest
Bug: 146415463
Change-Id: I7e7c5e5399011e2761dada2b989a95c2013307e9
Merged-In: I7e7c5e5399011e2761dada2b989a95c2013307e9
(cherry picked from commit f305f4def072363087595a610043852127c399e2)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is a prerequisite for adding additional logging of
the Watchdog-triggered rollback reason. Add flags which
indicate the failure observed (native, crash, ANR, explicit
health check). These will be used in the future by
RollbackPackageHealthObserver to map the failure type to the
(new) set of available logging metrics.

Test: atest PackageWatchdogTest
Bug: 146415463
Change-Id: I7e7c5e5399011e2761dada2b989a95c2013307e9
Merged-In: I7e7c5e5399011e2761dada2b989a95c2013307e9
(cherry picked from commit f305f4def072363087595a610043852127c399e2)
</pre>
</div>
</content>
</entry>
<entry>
<title>Make the default user the current user (not 0)</title>
<updated>2019-10-30T16:51:59+00:00</updated>
<author>
<name>Heemin Seog</name>
<email>hseog@google.com</email>
</author>
<published>2019-10-24T16:36:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=2ddd339d88682fc49dc516979f631436d4c36e96'/>
<id>2ddd339d88682fc49dc516979f631436d4c36e96</id>
<content type='text'>
In #clearValuesAndCheck, values are placed in the value map based on a
key that depends on the current user. When these values are checked
in #call, it uses default user 0 (unless CALL_METHOD_USER_KEY is
populated).

Considering we don't even use getStringForUser when checking the values,
it seems to make sense to check against the userId used to set the
values in #clearValuesAndCheck.

Bug: 143529292
Bug: 143480221
Test: atest VolumeDialogControllerImplTest before and after the patch
Merged-In: I0ee9313b1394515d9405344482dc1779d15c0819
Change-Id: I0ee9313b1394515d9405344482dc1779d15c0819
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In #clearValuesAndCheck, values are placed in the value map based on a
key that depends on the current user. When these values are checked
in #call, it uses default user 0 (unless CALL_METHOD_USER_KEY is
populated).

Considering we don't even use getStringForUser when checking the values,
it seems to make sense to check against the userId used to set the
values in #clearValuesAndCheck.

Bug: 143529292
Bug: 143480221
Test: atest VolumeDialogControllerImplTest before and after the patch
Merged-In: I0ee9313b1394515d9405344482dc1779d15c0819
Change-Id: I0ee9313b1394515d9405344482dc1779d15c0819
</pre>
</div>
</content>
</entry>
<entry>
<title>InetDiagSocketTest: ignore test that times out</title>
<updated>2019-10-17T10:25:49+00:00</updated>
<author>
<name>Jeff Vander Stoep</name>
<email>jeffv@google.com</email>
</author>
<published>2019-10-01T07:49:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=dadd2112f0db1333a8f8988d6a3600d5fb8ee592'/>
<id>dadd2112f0db1333a8f8988d6a3600d5fb8ee592</id>
<content type='text'>
Test: atest InetDiagSocketTest
Change-Id: Ieef0ca291924c0d81b1110bd25020d57fa9f0fec
Merged-In: Ieef0ca291924c0d81b1110bd25020d57fa9f0fec
Bug: 141870193
Bug: 141459241
(cherry picked from commit 69b83c9b3c58999f2638857d5f36d1aae48195bb)
Clean cherry pick.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Test: atest InetDiagSocketTest
Change-Id: Ieef0ca291924c0d81b1110bd25020d57fa9f0fec
Merged-In: Ieef0ca291924c0d81b1110bd25020d57fa9f0fec
Bug: 141870193
Bug: 141459241
(cherry picked from commit 69b83c9b3c58999f2638857d5f36d1aae48195bb)
Clean cherry pick.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix FD leak in ConnectivityManager.getConnectionOwnerUid</title>
<updated>2019-10-17T09:22:24+00:00</updated>
<author>
<name>Jeff Vander Stoep</name>
<email>jeffv@google.com</email>
</author>
<published>2019-09-26T11:56:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=cc7e09cbc2d52dcccc2a0747c9474d00dca6ca41'/>
<id>cc7e09cbc2d52dcccc2a0747c9474d00dca6ca41</id>
<content type='text'>
Add unit tests to verify that bug has been fixed.

Re-enable testGetConnectionOwnerUid() unit tests in presubmit. These
were disabled due to test flakiness caused by expected failures passing
as a result of other sockets on the system. This is fixed by checking
that failures do not have the UID of the calling process instead of
INVALID_UID since previously some Qualcomm telephony sockets were
causing lookup successes.

Test: atest InetDiagSocketTest#testGetConnectionOwnerUid
Test: ls -1 /proc/&lt;pid of system_server&gt;/fd | wca
Test: atest --generate-new-metrics 200 InetDiagSocketTest#testGetConnectionOwnerUid
   To verify flakes have been cleaned up.
Bug: 141603906
Bug: 141459241
Change-Id: Ib76674f10e4bd24952c557bac7b9c65fba42fdb2
Merged-In: Ib76674f10e4bd24952c557bac7b9c65fba42fdb2
(cherry picked from commit 59940afb16782d2cad2a7a1adbe653c2f5eb9812)
Clean cherry pick.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add unit tests to verify that bug has been fixed.

Re-enable testGetConnectionOwnerUid() unit tests in presubmit. These
were disabled due to test flakiness caused by expected failures passing
as a result of other sockets on the system. This is fixed by checking
that failures do not have the UID of the calling process instead of
INVALID_UID since previously some Qualcomm telephony sockets were
causing lookup successes.

Test: atest InetDiagSocketTest#testGetConnectionOwnerUid
Test: ls -1 /proc/&lt;pid of system_server&gt;/fd | wca
Test: atest --generate-new-metrics 200 InetDiagSocketTest#testGetConnectionOwnerUid
   To verify flakes have been cleaned up.
Bug: 141603906
Bug: 141459241
Change-Id: Ib76674f10e4bd24952c557bac7b9c65fba42fdb2
Merged-In: Ib76674f10e4bd24952c557bac7b9c65fba42fdb2
(cherry picked from commit 59940afb16782d2cad2a7a1adbe653c2f5eb9812)
Clean cherry pick.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge "Disable flaky testBadApkOnly test." into qt-r1-dev</title>
<updated>2019-08-30T09:07:57+00:00</updated>
<author>
<name>Richard Uhler</name>
<email>ruhler@google.com</email>
</author>
<published>2019-08-30T09:07:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=c617be6fd6b6b7c3fbcce1e41abcb6f89219be45'/>
<id>c617be6fd6b6b7c3fbcce1e41abcb6f89219be45</id>
<content type='text'>
am: 8e8a2d0cb3

Change-Id: I67579f545adaf2b045d7512825e4154001202a1c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
am: 8e8a2d0cb3

Change-Id: I67579f545adaf2b045d7512825e4154001202a1c
</pre>
</div>
</content>
</entry>
<entry>
<title>Disable flaky testBadApkOnly test.</title>
<updated>2019-08-28T09:23:51+00:00</updated>
<author>
<name>Richard Uhler</name>
<email>ruhler@google.com</email>
</author>
<published>2019-08-28T09:19:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.replicant.us/replicant-next/frameworks_base/commit/?id=d283dc938f482d38cd62a469c4f523d8e053396f'/>
<id>d283dc938f482d38cd62a469c4f523d8e053396f</id>
<content type='text'>
A proper fix for the flakiness has been submitted to more recent
versions of the RollbackTest.

Bug: 139108668
Bug: 139175593

Test: atest StagedRollbackTest

Change-Id: Iad20ac3744b0cf4adf0355150ce957de2a24304c
Merged-In: Iaaa728aa58d894ba546677e8295faba2ebfc5e64
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
A proper fix for the flakiness has been submitted to more recent
versions of the RollbackTest.

Bug: 139108668
Bug: 139175593

Test: atest StagedRollbackTest

Change-Id: Iad20ac3744b0cf4adf0355150ce957de2a24304c
Merged-In: Iaaa728aa58d894ba546677e8295faba2ebfc5e64
</pre>
</div>
</content>
</entry>
</feed>
