Commit graph

16 commits

Author SHA1 Message Date
Almaz Mingaleev
773ec2744a Add java.util.random to the allowed package list.
This is part of OpenJDK17 update.

Bug: 282678719
Bug: 270674727
Bug: 308103782

Test: m
Change-Id: I9be31ef257ee94bd731220ba31b74ebfb0562fd3
2023-10-31 16:05:52 +00:00
Almaz Mingaleev
2429776555 Add jdk.internal.access to the allowed package list.
This is part of OpenJDK17 update.

Bug: 270674727
Test: m
Change-Id: I0708ee286cd7c3c6eef593784affaeffbdf0a76c
2023-05-03 07:21:27 +00:00
Sorin Basca
93bca1585e Merge changes from topic "java17-record-support"
* changes:
  Allow java.lang.runtime in boot image
  Emit record annotation
2023-03-03 15:12:28 +00:00
Victor Chang
7c05d2d185 Allowlist java.lang.constant in libcore
Bug: 270028670
Test: m droid
Change-Id: I7612998fd518442defd5f9f00115e6a16e261b18
2023-02-20 17:27:18 +00:00
Sorin Basca
4025390468 Allow java.lang.runtime in boot image
Test: m
Change-Id: Icb208bb235f9c6ac97492c54c32a3174982756ae
2023-02-10 07:31:51 +00:00
Almaz Mingaleev
8b04d82ff1 Add jdk.internal.util.jar in the allowed package list.
This is part of OpenJDK17 update. sun.misc.JarIndex was moved to
jdk.internal.util.jar.

Bug: 260718199
Test: m
Change-Id: I7107f980d6afe500acff88164b1e6cb04cded896
2023-02-03 11:42:46 +00:00
Nikita Iashchenko
a4676f5de6 Add jdk.internal.ref to package_allowed_list.txt (OpenJDK 11)
This is part of merging upstream changes from OpenJDK 11.28. New classes
have been added to core-oj, so there is a new path added to
package_allowed_list.txt:

 * jdk.internal.ref

Bug: 198792576
Test: atest CtsLibcoreOjTestCases
Change-Id: I19a40447bbb060612e0c2f3ef0770568345a7405
2021-11-24 17:15:30 +00:00
Sorin Basca
ca4ab1a7a8 Adding jdk.internal in the allowed package list
This is needed for adding jdk.internal.HotSpotIntrinsicCandidate as a no-op

Bug: 202495224
Test: m
Change-Id: Ib97a7fe955d920aca93630d1d5b04fedff1af960
2021-11-01 14:20:33 +00:00
Sorin Basca
87f33ea80b OpenJDK 11: Adding jdk.internal.reflect to allowed package list
As part of the migration to OpenJDK 11, sun.reflect has moved to
jdk.internal.reflect. For now we'll have both packages available
as new code uses the jdk.internal version.

Test: m
Bug: 188889082
Bug: 190791083
Change-Id: Ib03c9c8c346daebd7d97387817b506095f5ec693
2021-09-27 15:39:06 +00:00
Sorin Basca
1bb6d6a2c9 Adding jdk.internal.misc in the allowed packages
Updating OpenJDK 11 means that there is a dependency on
jdk.internal.misc, which is renamed from sun.misc. The new
package is added to the allowed list.

Bug: 190470684
Bug: 190791083
Test: m
Change-Id: I174df7bad5c5ec4286c35998e16c26bcd0737612
2021-09-22 15:18:45 +00:00
Spandan Das
96d5424440 Merge "Apply pylint to check_boot_jars.py" 2021-09-08 18:32:02 +00:00
Nikita Iashchenko
15c1387710 Add jdk.internal.math to package_allowed_list.txt (OpenJDK 11)
This is part of merging upstream changes from OpenJDK 11.28. This CL
adds jdk.internal.math to package_allowed_list.txt

Bug: 199067710
Test: atest CtsLibcoreOjTestCases
Change-Id: I343bed53ce6b52a6b373a75828b3234073b9cba8
2021-09-06 17:38:34 +01:00
Spandan Das
2c0af22ea8 Apply pylint to check_boot_jars.py
1. Run pyformat scripts/check_boot_jars/check_boot_jars.py -s 4
--force_quote_type none -i to fix formatting.
3. use pylint: disable=<X> where fixes are not obvious

Test: m check_boot_jars
Test: pylint --rcfile tools/repohooks/tools/pylintrc
scripts/check_boot_jars/check_boot_jars.py
Bug: 195738175

Change-Id: I0f86d95e0d174c9f87a2872dedaa65cd3e814246
2021-09-03 18:01:49 +00:00
Paul Duffin
cd4f673ceb Switch boot jars package check to use dexdump xml output
The xml output from dexdump is more stable than the text output so this
change switches to use that.

Bug: 171479578
Test: m check-boot-jars - for failing and passing cases
Change-Id: Ie347b1b685951524d5ae09db280248c61b4228ee
2020-11-16 17:46:16 +00:00
Paul Duffin
2d8e1a7e59 Switch boot jars package check to using dex jars
The switch to use dex jars instead of class jars means that a boot jar
that is defined by a dex_import module will now be checked against the
package_allowed_list.txt so it is possible that it will detect
previously unreported problems.

Test: m check-boot-jars - for failing and passing cases
Bug: 171479578
Bug: 125517186
Change-Id: Ie614898dade0fb43c9418d7afb9138169db6f097
2020-11-10 17:37:43 +00:00
Paul Duffin
9a89a2a0ea Move boot jars package check from make
Adds a singleton that traverses the module variants finding the ones
that are in the list (updatable and non-updatable) of boot jars and
add a ninja rule to ensure that they only contain packages from an
allowed list.

Replaces a hack that ignored any prebuilt boot jars supplied as dex
file with an equivalent one to ensure that they are still ignored.
A follow up change that switches to checking dex jars will allow the
hack to be removed.

The boot jars check can be strict or lax. If strict then all the boot
jars listed in the configuration must be found, otherwise it will only
check the ones it finds. It is strict by default unless
TARGET_BUILD_UNBUNDLED=true or ALLOW_MISSING_DEPENDENCIES=true.

Moves the script and data file from build/make.

Test: m check-boot-jars - for failing and passing cases
      SKIP_BOOT_JARS_CHECK=true - no check-boot-jars target created
	  ALLOW_MISSING_DEPENDENCIES=true - not strict
	  TARGET_BUILD_UNBUNDLED=true - not strict
      verified manually that apart from path differences the same
      files (same check sum) were checked in both old make checks and
      the new Soong ones
      EMMA_INSTRUMENT=true EMMA_INSTRUMENT_FRAMEWORK=true m check-boot-jars
Bug: 171479578
Change-Id: I9d81d6650ba64fc0d48d2dab4ba5a3ba8dd03dec
2020-10-29 17:20:06 +00:00