Commit graph

56214 commits

Author SHA1 Message Date
Tao Bao
dc2f0b0abd Merge "Include per-partition fingerprint as AVB prop." 2019-10-14 14:53:46 +00:00
Anton Hansson
2ce82aea1a Merge "Document SYSTEM_OTHER_ODEX_FILTER matching" am: 3cc4fa6394
am: bde786ca70

Change-Id: Ia10a14e43e24bb19985631275fb43bbb497521d3
2019-10-14 02:45:57 -07:00
Anton Hansson
bde786ca70 Merge "Document SYSTEM_OTHER_ODEX_FILTER matching"
am: 3cc4fa6394

Change-Id: I6e243dc057ce23913a9a33f97a7ecd35c9714de1
2019-10-14 02:40:35 -07:00
Anton Hansson
3cc4fa6394 Merge "Document SYSTEM_OTHER_ODEX_FILTER matching" 2019-10-14 09:29:10 +00:00
Jooyung Han
172c8e6de0 install VNDK APEX instead of VNDK libs
VNDK APEX replaces VNDK libs under /system/libs/vndk[-sp].

For current VNDK (vndk_package), com.android.vndk.current APEX is
installed instead of VNDK libraries.

For older versions of VNDK (vndk_snapshot_package),
com.android.vndk.v## APEXes are installed along with prebuilt VNDK libs.
The reason why phony targets of VNDK prebuilts are still installed is
that phony targets install the required *.libraries.##.txt files to
/system/etc.

After those .txt files are moved to APEXes, then we can remove those phony
targets.(b/141450808)

Bug: 141451661
Test: m && boot (tested with cuttlefish)

Change-Id: Ibfa06d42ec0081fa7010091ef097bb940bacf8d6
2019-10-13 04:18:05 +09:00
Tianjie Xu
21e6deb647 Call delta_generator to get the signature size
The signature size is needed during payload hashing and signing.
We used to sign the update_engine's payload with RSA keys only. In
this case, the signature size always equals the key size. But the
assumption is no longer true for EC keys, whose DER-encoded signature
size is a variant with a maximum size.

Therefore, we always give the maximum signature size to the delta
generator, who then add paddings to the real signature if necessary.
The maximum signature size is calculated by calling the delta_generator
with the new option '--calculate_signature_size'. For custom payload
signers, we also deprecate the '--payload_signer_key_size' and replace
it with '--payload_signer_maximum_signature_size'.

The EC key in the test is generated with:
The EC key in the unittest is generated with the command:
openssl ecparam -name prime256v1 -genkey -noout -out prime256v1-key.pem
openssl pkey -in prime256v1-key.pem -out testkey_EC.key

Bug: 141244025
Test: sign and verify a payload
Change-Id: Ife6e269d8aa3d870405aca20086330f1795e167f
2019-10-12 00:36:54 +00:00
Evgenii Stepanov
eb3ade924b Define ro.sanitize.<name> properties in SANITIZE_TARGET builds.
This will let us quickly check the system image build type,
and modify *.rc behavior based on that.

Bug: 142430632
Test: adb shell getprop ro.sanitize.hwaddress in hwasan build

Change-Id: If2eb99dee93f0652cada5cb2e02fda963d00a7eb
2019-10-11 16:59:27 -07:00
Steven Moreland
3b9d2dc689 Merge "mainline_system: libhwbinder/libhidltransport" am: 2ce54fa76a
am: a84540e557

Change-Id: I74d9e246243ff2c93ab60b92b61aee1ae6b6dd43
2019-10-11 13:56:23 -07:00
Steven Moreland
a84540e557 Merge "mainline_system: libhwbinder/libhidltransport"
am: 2ce54fa76a

Change-Id: Icf8f192120bbd9f8ee186a52f90f336700cd1704
2019-10-11 13:49:24 -07:00
Steven Moreland
2ce54fa76a Merge "mainline_system: libhwbinder/libhidltransport" 2019-10-11 20:19:13 +00:00
Tao Bao
afd92a8689 releasetools: Set the search path based on the current executable.
We used to mimic the behavior of build system, to find the default
search path based on OUT_DIR_COMMON_BASE or OUT_DIR. These variables
should be internal to build system.

Since we've switched releasetools script to hermetic Python executables
(e.g. `m -j ota_from_target_files`, then run the binary at
`out/host/linux-x86/bin/ota_from_target_files`), we can set the search
path in relative to the path of the current executable.

Bug: 133126366
Test: TreeHugger
Test: 1. Build aosp_x86, by "lunch aosp_x86; m -j"
      2. Inject errors to the executables under out/host/linux-x86/bin,
         e.g.  to `lpmake`.
      3. Set up OUT_DIR (e.g., to /tmp/out) and build the same product
         again by "export OUT_DIR=/tmp/out; lunch aosp_x86; m -j". Check
         that the second run finishes successfully (with the binaries at
         /tmp/out as opposed to out/; otherwise it would fail the build
         due to the invalid binaries from step 2).
Test: lunch a target;
      `atest --host releasetools_test releasetools_py3_test`
Change-Id: I366099c3dfd5fa4282745ef258a8cf35338e1e42
2019-10-11 08:53:41 -07:00
Colin Cross
011d40c669 Merge "Remove stray ZIPALIGN_PAGE_ALIGN_FLAGS" am: d6d27517f7
am: 30124b4e1e

Change-Id: I2b415e12eca7a870bbc2aff04b1e3556084b4ede
2019-10-11 06:26:57 -07:00
Colin Cross
30124b4e1e Merge "Remove stray ZIPALIGN_PAGE_ALIGN_FLAGS"
am: d6d27517f7

Change-Id: I6bd69722e8f5fa9b1333b9dc9e374e255d11e234
2019-10-11 06:20:52 -07:00
Victor Chang
d272f0ed6f Add libicu_jni into ART APEX
Bug: 138994281
Test: device boots
Change-Id: Ic61d374ef87634ebaa1bb55b2a36176d3606f3d2
2019-10-11 14:20:38 +01:00
Treehugger Robot
d6d27517f7 Merge "Remove stray ZIPALIGN_PAGE_ALIGN_FLAGS" 2019-10-11 13:12:29 +00:00
Lev Proleev
e4f453394b Add NeuralNetworks HAL v1.3
Bug: 139120468
Test: m check-vndk-list
Test: m
Change-Id: I2f5d1a66c12509440293c7b5916c337ff1bbe88c
Merged-In: I2f5d1a66c12509440293c7b5916c337ff1bbe88c
(cherry picked from commit fde53f4e3e)
2019-10-11 12:54:46 +01:00
dianlujitao
a620ad1ff1 Merge "Fix odm output directory for devices w/o vendor partition" am: 46cfab96d8
am: eec39a95f3

Change-Id: I9b91b105e926a9da8279b23e7b1aad09a7b1058a
2019-10-11 04:20:07 -07:00
dianlujitao
eec39a95f3 Merge "Fix odm output directory for devices w/o vendor partition"
am: 46cfab96d8

Change-Id: Ia132212a1b1cfb909a3f8539ca42af0bdd9c9939
2019-10-11 04:14:06 -07:00
Treehugger Robot
46cfab96d8 Merge "Fix odm output directory for devices w/o vendor partition" 2019-10-11 10:46:43 +00:00
Xin Li
7180291ccc [automerger skipped] Merge "DO NOT MERGE - Merge QP1A.191005.007 into master" am: 51a7d20229 -s ours
am: 13c9a00e30 -s ours
am skip reason: change_id I063f0430347d9f1e6ea5a8133204585833ed5ddc with SHA1 84633edb22 is in history

Change-Id: Ib4a6fa4e6cf666a4c88460a115483d231769d56e
2019-10-10 21:32:01 -07:00
Xin Li
656c9fcf1b [automerger skipped] DO NOT MERGE - Merge QP1A.191005.007 into master am: 66ec993fe5 -s ours
am: 39124f2240 -s ours
am skip reason: change_id I063f0430347d9f1e6ea5a8133204585833ed5ddc with SHA1 84633edb22 is in history

Change-Id: I116f24077289c2251b30a158e50b62ebbbee8280
2019-10-10 21:21:16 -07:00
Xin Li
13c9a00e30 [automerger skipped] Merge "DO NOT MERGE - Merge QP1A.191005.007 into master"
am: 51a7d20229 -s ours
am skip reason: change_id I063f0430347d9f1e6ea5a8133204585833ed5ddc with SHA1 84633edb22 is in history

Change-Id: Id2e7eaeb1ad6dd8ad7f9d5ebaf8d4e8f5c0511e0
2019-10-10 21:19:44 -07:00
Xin Li
39124f2240 [automerger skipped] DO NOT MERGE - Merge QP1A.191005.007 into master
am: 66ec993fe5 -s ours
am skip reason: change_id I063f0430347d9f1e6ea5a8133204585833ed5ddc with SHA1 84633edb22 is in history

Change-Id: I794691b6e2f321e6073be08803291871cd2c414c
2019-10-10 21:10:46 -07:00
Xin Li
51a7d20229 Merge "DO NOT MERGE - Merge QP1A.191005.007 into master" 2019-10-11 02:56:40 +00:00
Elliott Hughes
af11c50e67 Revert "-D__ANDROID_NDK__ for SDK builds."
This reverts commit 401a84071b.

Reason for revert: fixed in bionic instead (https://android-review.googlesource.com/c/platform/bionic/+/1135146).

Change-Id: I85e2ef241684c34fc968fd0e7230b8a88ea3209a
2019-10-11 01:24:39 +00:00
Harpreet "Eli" Sangha
0838439f88 Merge "Add Vibrator HAL 1.4" am: 0ffe0c6248
am: 4a27b4e3fe

Change-Id: Ia79ced4513561f3324f6825e6dadd31ef5d16eca
2019-10-10 17:49:14 -07:00
Harpreet "Eli" Sangha
4a27b4e3fe Merge "Add Vibrator HAL 1.4"
am: 0ffe0c6248

Change-Id: Icc4968fb4f33b173484c5e3ecc028b65fcb0279f
2019-10-10 17:43:10 -07:00
Treehugger Robot
0ffe0c6248 Merge "Add Vibrator HAL 1.4" 2019-10-11 00:35:05 +00:00
Xin Li
66ec993fe5 DO NOT MERGE - Merge QP1A.191005.007 into master
Bug: 142297020
Merged-In: I063f0430347d9f1e6ea5a8133204585833ed5ddc
Change-Id: I6fe9ad3f71b30ba7c1cf9d6941450809cfc66909
2019-10-10 22:54:06 +00:00
Tao Bao
04530d41c3 Merge "AVB: decouple vbmeta.img from recovery.img for non-A/B devices" am: 549325427b
am: 97c1c9aaa3

Change-Id: I1ed2a4e004f7bf9a9ae1b0aa2e4b41c5c733124e
2019-10-10 13:44:11 -07:00
Tao Bao
97c1c9aaa3 Merge "AVB: decouple vbmeta.img from recovery.img for non-A/B devices"
am: 549325427b

Change-Id: Iebb05accc055147051cfecfc2729fbe8cca0a0d1
2019-10-10 13:38:13 -07:00
Tao Bao
549325427b Merge "AVB: decouple vbmeta.img from recovery.img for non-A/B devices" 2019-10-10 20:18:35 +00:00
Josh Gao
5f96f5ce35 Move remount to PRODUCT_PACKAGES_DEBUG.
required seems to conflict with apex with the following error:

    build/make/core/main.mk:1338: warning: build/make/target/product/aosp_x86_64.mk produces files inside build/make/target/product/mainline_system.mks artifact path requirement.

Test: treehugger
Change-Id: Ifb1072b4585a94355909b33e3b8129455c35714a
2019-10-10 13:12:13 -07:00
Colin Cross
bf086436b0 Remove stray ZIPALIGN_PAGE_ALIGN_FLAGS
Iae26e4676c29c68fa3f76187512c82786bfa0522 removed the definition
of ZIPALIGN_PAGE_ALIGN_FLAGS in favor of always using the -p flag,
but left accidentaly left one usage.  Replace it with -p.

Bug: 141212627
Test: m checkbuild
Change-Id: Ica69d9195426f8f30039da211ed1a0ad5dffe8e8
2019-10-10 12:52:13 -07:00
Steven Moreland
bf4fd54cee mainline_system: libhwbinder/libhidltransport
Bug: 135686713
Test: artifact whitelist requirement no longer complaining
Change-Id: Ia142f8e67c31f66f86386b65e009d4faee502c11
Merged-In: Ia142f8e67c31f66f86386b65e009d4faee502c11
2019-10-10 19:51:46 +00:00
David Anderson
d4976a85ed Merge "Add boot@1.1 to VNDK" am: 5ff715d088
am: f44a1e6c67

Change-Id: I8af4025bb1fe7812bf294ffdcd083e60e76a5884
2019-10-10 12:38:37 -07:00
David Anderson
f44a1e6c67 Merge "Add boot@1.1 to VNDK"
am: 5ff715d088

Change-Id: I3fa8cad413879b7ee81591eaf2d4f6c1b0d9c9f4
2019-10-10 12:31:41 -07:00
David Anderson
5ff715d088 Merge "Add boot@1.1 to VNDK" 2019-10-10 19:19:49 +00:00
cfig
1aeef725a7 AVB: decouple vbmeta.img from recovery.img for non-A/B devices
For following cases:
Case 1: A/B devices: no change
Case 2: non-A/B devices, with unsigned recovery image:
    not allowed anymore by mandating BOARD_AVB_RECOVERY_KEY_PATH
Case 3: non-A/B devices, with signed recovery image:
    vbmeta.img should not include ChainPartitionDescriptor of recovery.img,
    otherwise device can not even boot into normal mode if recovery partition
    is damaged

This CL will cause a build break if BOARD_AVB_RECOVERY_KEY_PATH
is not set for non-A/B targets with recovery.img
The following is an example to fix the build break by specifying
AVB signing configs for the recovery.img.

BOARD_AVB_RECOVERY_KEY_PATH := external/avb/test/data/testkey_rsa2048.pem
BOARD_AVB_RECOVERY_ALGORITHM := SHA256_RSA2048
BOARD_AVB_RECOVERY_ROLLBACK_INDEX := $(PLATFORM_SECURITY_PATCH_TIMESTAMP)
BOARD_AVB_RECOVERY_ROLLBACK_INDEX_LOCATION := 2

Also note that libavb in bootloader needs an update to include this
commit Iaa886037edb18c2ff6c60fa2a7f883ab7303ba1a, to support verifying
recovery.img independently (not through vbmeta.img).

Bug: 130351427
Test (Case 3):
  normal   mode: avb_slot_verify(flags=AVB_SLOT_VERIFY_FLAGS_NONE)
  recovery mode: avb_slot_verify(flags=AVB_SLOT_VERIFY_FLAGS_NO_VBMETA_PARTITION)
Test: PYTHONPATH=build/make/tools/releasetools \
    python -m unittest test_validate_target_files
Test: Use a lunch'd target. `atest --host releasetools_test releasetools_py3_test`
Test: validate_target_files.py with Case-3 target files
Change-Id: I2a73252b385fa463b4abd444923a8acc473df0b4
2019-10-10 14:28:34 +00:00
Lev Proleev
a163c720ed Merge "Revert "Add NeuralNetworks HAL v1.3"" am: f5f487be03
am: 176c4afae7

Change-Id: Ia864ea8826543b42990f3af4f7b2915c1363b36f
2019-10-10 07:26:49 -07:00
Lev Proleev
176c4afae7 Merge "Revert "Add NeuralNetworks HAL v1.3""
am: f5f487be03

Change-Id: Iaa860c79d101168b73c8ee867c3259758fbffc6d
2019-10-10 07:20:00 -07:00
Lev Proleev
f5f487be03 Merge "Revert "Add NeuralNetworks HAL v1.3"" 2019-10-10 14:06:42 +00:00
Lev Proleev
f1cec4b4a4 Revert "Add NeuralNetworks HAL v1.3"
This reverts commit bace8c091c.

Reason for revert: the topic breaks git_qt-dev-plus-aosp

Change-Id: Idf87926dd40b56b9d6acc2e207be785463f6830a
2019-10-10 13:54:21 +00:00
Lev Proleev
165a75575f Merge "Add NeuralNetworks HAL v1.3" am: 4b49e75a40
am: 5195c4cf99

Change-Id: I24075ca160667b2edfdd0465fbae25857f35235a
2019-10-10 05:20:52 -07:00
Lev Proleev
5195c4cf99 Merge "Add NeuralNetworks HAL v1.3"
am: 4b49e75a40

Change-Id: I62a994d9f8eec83e42623836b9eed269b889f2a3
2019-10-10 05:07:25 -07:00
Lev Proleev
4b49e75a40 Merge "Add NeuralNetworks HAL v1.3" 2019-10-10 10:25:21 +00:00
Tao Bao
19b02fe8e5 Include per-partition fingerprint as AVB prop.
This allows querying per-partition fingerprint via libavb (in
particular, avb_property_lookup).

Bug: 80097573
Test: `m dist`; `avbtool info_image --image /path/to/image` to check the
      written prop.
Test: `atest --host releasetools_test releasetools_py3_test`
Test: Run sign_target_files_apks to sign a target_files.zip that's built
      with the change. Check the AVB prop in the signed images.
Change-Id: Id4f06df82c29e77aca128439c8c11f0367fe587e
2019-10-09 21:25:19 -07:00
dianlujitao
339ef4cf3f Fix odm output directory for devices w/o vendor partition
Change-Id: Iba6c169630ea6bf61b9057a9994e5eb824915304
2019-10-10 09:55:09 +08:00
Bowgo Tsai
234df13a98 Merge "Adding boot-test-harness.img" am: 818df7b0d0
am: 68130ccb4a

Change-Id: I44cf65c1c90bc20813708db7af97f162ab3a5659
2019-10-09 17:39:10 -07:00
Bowgo Tsai
68130ccb4a Merge "Adding boot-test-harness.img"
am: 818df7b0d0

Change-Id: I550d6e5eebe84f9e1971ef23a21c40d22de0d0b8
2019-10-09 17:32:04 -07:00