Commit Graph

19954 Commits

Author SHA1 Message Date
Elisa Pascual Trevino ac6e24e5b1 Update Security String to 2019-09-05
Bug: 137199979
2019-07-11 22:26:27 +00:00
Elisa Pascual Trevino 4364982766 Update Security String to 2019-09-01
Bug: 137199979
2019-07-11 22:20:00 +00:00
Justin Yun 25065c44cc Do not allow building product_services image
product_services partition is designed for the test purpose only. It
must not be included in the target devices.

Bug: 134359158
Test: Build configuration for product_services partition must return
      error message.

Change-Id: I6f8cdf73d18ad3174c7b31edb5d5ee10df75a776
2019-07-05 20:38:01 +09:00
Adam Seaton 0c355124bf Revert "Update Security String from 08-05 to 2019-08-01 Bug:126590667"
This reverts commit ef7c2c7915.

Reason for revert: Resolve string downgrade issue

Change-Id: I28831f2592bba09907b76c7d5ac46326a9c1e9f8
2019-06-17 17:03:51 +00:00
Paul Scovanner ef7c2c7915 Update Security String from 08-05 to 2019-08-01 Bug:126590667
am: ead61ed19e

Change-Id: Iaf434bf5690c3c50371bb11266d300ab7d335184
2019-06-14 13:22:34 -07:00
Paul Scovanner 3a25bc8b55 Update Security String to 2019-08-05 Bug:126590667
am: a3e1c57a95

Change-Id: I0b10bab75834759c3bd216fc77c38c84b445c4e2
2019-06-12 16:06:18 -07:00
Paul Scovanner ead61ed19e Update Security String from 08-05 to 2019-08-01
Bug:126590667
2019-06-12 22:51:45 +00:00
Paul Scovanner a3e1c57a95 Update Security String to 2019-08-05
Bug:126590667
2019-06-11 19:46:33 +00:00
Tao Bao 97a6690a23 Rebuild recovery-from-boot patch when calling add_img_to_target_files.
When using Verified Boot 2.0, releasetools specifies a salt value based
on build fingerprint, so that to give idempotent images.

However, the change that removed static `ro.build.fingerprint` [1] broke
the behavior, as common.LoadInfoDict still relies on fingerprints.
Without a fixed salt, the first call to make_recovery_patch.py and the
second one (which writes IMAGES/{boot,recovery}.img) will see different
images, which leads to install-recovery.sh failure.

Note that currently there's a dependency that requires getting bootable
images through two separate calls. make_recovery_patch.py has to happen
first to get (placeholder) files in the system image. We then generate
canned fs_config files, and finally use add_img_to_target_files.py to
write the images.

This CL adds a quick workaround to force rebuilding the
recovery-from-boot patch while calling add_img_to_target_files.py.

[1] https://android-review.googlesource.com/c/platform/build/+/892933

Bug: 134123803
Bug: 134525174
Test: TreeHugger
Test: Build a non-A/B target that uses AVB. Run validate_target_files.py
      on the generated target_files.zip.
Change-Id: I5859e30be63bfd54398cf41fd2d907f15285f560
Merged-In: I5859e30be63bfd54398cf41fd2d907f15285f560
(cherry picked from commit 4978fa99d1)
2019-06-05 22:04:47 -07:00
Alan Viverette c45849fc0c Remove obsolete Support Library guidance from version_defaults.mk
Test: n/a docs only
Fixes: 133228727
Change-Id: I10cdd9a4dfe8c508417f7b80320e308c236f2c8e
2019-05-30 16:57:25 +00:00
TreeHugger Robot f862715103 Merge "Allow for the DTB image to be built by the Android build system." into qt-dev 2019-05-24 17:34:27 +00:00
Hridya Valsaraju 5b8f78fbe8 Allow for the DTB image to be built by the Android build system.
The current solution expects BOARD_PREBUILT_DTBIMAGE_DIR to
contain prebuilt DTB files that are concatenated by the build system
to create $OUT/dtb.img. In order to accommodate devices that build
the dtb image locally, when BOARD_PREBUILT_DTBIMAGE_DIR is undefined,
make boot.img creation depend only on $OUT/dtb.img.

Bug: 133161451
Test: Build with BOARD_PREBUILT_DTBIMAGE_DIR undefined and verify
using unpack_bootimg.py that $OUT/dtb.img was included in boot.img.

Change-Id: Iae2c634ccdc1d83589b26d382882f75fb8565a31
Merged-In: Iae2c634ccdc1d83589b26d382882f75fb8565a31
2019-05-22 15:55:47 -07:00
Bowgo Tsai 33ff602070 Moving /odm/build.prop to /odm/etc/buid.prop
In device root directory, we have the following symlinks:
  - /odm/app -> /vendor/odm/app
  - /odm/bin -> /vendor/odm/bin
  - /odm/etc -> /vendor/odm/etc
  ...

This allows the Generic System Image (GSI) to be used on both devices:
  1) Has a physical odm partition, where those symlink will be hidden
     when /odm is used as the mount point
  2) Has no physical odm partition and fallback to /vendor/odm/.

We can't just have the symlink /odm -> /vendor/odm, because the former
devices won't have /vendor/odm directory, which leads to mount failure
when the mount point /odm is resolved to /vendor/odm.

The existing /vendor/odm/build.prop won't be loaded in the latter
devices, because there is no symlink:
    - /odm/build.prop -> /vendor/odm/build.prop.

Note that init blocks reading through direct symlinks (O_NOFOLLOW) so
the above symlink won't work either. This CL moves the odm build.prop
to /odm/etc/build.prop for init to load it (symlinks in earlier
components of the path will still be followed by O_NOFOLLOW).

Bug: 132128501
Test: boot a device and checks /odm/etc/build.prop is loaded
Test: make dist with an odm.img, checks $OUT/odm/etc/build.prop is loaded
Change-Id: I6f88763db755c9ec6068bfdd9cee81c19d72e9d7
Merged-In: I6f88763db755c9ec6068bfdd9cee81c19d72e9d7
(cherry picked from commit 6c62884000)
2019-05-22 16:14:53 +08:00
Bowgo Tsai ce8b063507 Appending per-partition os_version into AVB props
os_version is important for keymaster version binding, where it
refuses to perform operations with a key that is bound to an old
system version.  This ensures that an attacker who discovers a
weakness in an old version of system or TEE software cannot roll a
device back to the vulnerable version and use keys created with the
newer version.

Previously, os_version for system.img is added into boot.img header
for bootloader to read the value then pass to TEE before booting the
HLOS. However, with project Treble to modularize each partition, all
images are now in the trajectory to be built independently (still
on-going). Also, in the Generic System Image (GSI) compliance test,
the os_version in OEM's boot.img cannot reflect the actual version of
GSI.

This CL adds per-partition os_versions into AVB metadata, which is
readable by bootloader via libavb without file system dependency. It's
still unclear for how os_version in non-system partition should be used.
We just add them for completeness here.

See more details in:
https://source.android.com/security/keystore/version-binding

Bug: 132233601
Test: build and avbtool info_image $OUT/vbmeta.img
      - Prop: com.android.build.boot.os_version -> '10'
      - Prop: com.android.build.system.os_version -> '10'
      - Prop: com.android.build.system.security_patch -> '2019-06-05'
      - Prop: com.android.build.vendor.os_version -> '10'
      - Prop: com.android.build.vendor.security_patch -> '2019-06-05'
      - Prop: com.android.build.product.os_version -> '10'
      - Prop: com.android.build.product.security_patch -> '2019-06-05'

Change-Id: I21a77420f2e8a3456f7a8cae5158eb8fc41319e7
Merged-In: I21a77420f2e8a3456f7a8cae5158eb8fc41319e7
(cherry picked from commit 9b54801b58)
2019-05-16 21:46:53 +08:00
Anton Hansson 43b86c0182 Merge "Move default setting of a product variable" into qt-dev 2019-05-16 09:27:29 +00:00
Ian Pedowitz 122a1136e6 Merge "Revert "Revert "Updating the platform sdk version for Q""" into qt-dev 2019-05-15 16:28:53 +00:00
Ian Pedowitz 89e4c9da7a Merge "Android Q is now REL" into qt-dev 2019-05-15 16:28:53 +00:00
Anton Hansson 584d3726b6 Move default setting of a product variable
Should be in product_config.mk, before the variables are readonly'd, or
the default will fail to work.

(cherry picked from commit 269dd013a5)

Bug: 131576555
Test: set PRODUCT_SHIPPING_API_LEVEL := 29 in mainline_arm64.mk && lunch
Change-Id: I25faee7ec0a3fff17e1d08b834d868834effda36
Merged-In: I25faee7ec0a3fff17e1d08b834d868834effda36
2019-05-15 11:30:29 +01:00
Paul Scovanner 2813ebc21d Update Security String to 2019-07-05 Bug:132634503 am: 0718f458a1 am: 67f7ba7d9c am: 2ec2e55239
am: f01785c0a8

Change-Id: I92f844d235420335ccd7a29a07b8d6ea9757fedd
2019-05-14 15:03:19 -07:00
Paul Scovanner f01785c0a8 Update Security String to 2019-07-05 Bug:132634503 am: 0718f458a1 am: 67f7ba7d9c
am: 2ec2e55239

Change-Id: I1164c5fd489d282c2c297c78e59a3d937adb4e2f
2019-05-14 14:59:06 -07:00
Paul Scovanner 2ec2e55239 Update Security String to 2019-07-05 Bug:132634503 am: 0718f458a1
am: 67f7ba7d9c

Change-Id: Id153c7f78dcf9cb5f0aacf261837bff9844f9cbf
2019-05-14 14:52:55 -07:00
Paul Scovanner 67f7ba7d9c Update Security String to 2019-07-05 Bug:132634503
am: 0718f458a1

Change-Id: Ice3a0dc3f425217138d881543aaae1c4c412d7db
2019-05-14 14:45:50 -07:00
Paul Scovanner 3caec84292 Update Security String to 2019-07-01 Bug:132634503 am: 95bee0f53e am: 2f15ff97b7 am: 58c2ebf84b
am: d51234a521

Change-Id: I713c98262d85d9dfac5e372284f9f93e7dbce7d9
2019-05-14 11:23:11 -07:00
Paul Scovanner d51234a521 Update Security String to 2019-07-01 Bug:132634503 am: 95bee0f53e am: 2f15ff97b7
am: 58c2ebf84b

Change-Id: Ic30bcfffb5ff71afd8d59fe9cfb1a0402b55c4c3
2019-05-14 11:18:01 -07:00
Paul Scovanner 58c2ebf84b Update Security String to 2019-07-01 Bug:132634503 am: 95bee0f53e
am: 2f15ff97b7

Change-Id: I7a8fabadfa32356443305953ec91665037f7aa28
2019-05-14 11:10:59 -07:00
Paul Scovanner 2f15ff97b7 Update Security String to 2019-07-01 Bug:132634503
am: 95bee0f53e

Change-Id: If6ac58537bc1e8359a0774a5dd9513813900a6c2
2019-05-14 11:04:42 -07:00
Paul Scovanner 0718f458a1 Update Security String to 2019-07-05
Bug:132634503
2019-05-14 00:02:43 +00:00
Paul Scovanner 95bee0f53e Update Security String to 2019-07-01
Bug:132634503
2019-05-13 20:36:29 +00:00
Ian Pedowitz bed3e5262e Revert "Revert "Updating the platform sdk version for Q""
This reverts commit 842119ab3a.

Reason for revert: Rolling forward for Q-Finalization

Bug: 129975435
Bug: 129943426
Test: Build
Change-Id: I651e3ec68a765d3867be5341751cd536ccbe604a
2019-05-11 10:01:39 -07:00
Ian Pedowitz 883ad4c8b2 Android Q is now REL
Bug: 129943426
Test: Build
Change-Id: I99d58a4afeaf38c51a93cc95d9ea1f5666797602
Merged-In: I352e02484fa73ee924c84846913b93f7713c77ef
2019-05-11 08:33:31 -07:00
Martin Stjernholm 6311b83cc2 Extend library absence check to Bionic libs and all ART debug libs.
(cherry picked from commit c2e0205927)

Test: m systemimage
Test: build_test on Forrest
Bug: 132289438
Merged-In: I1a25d8d45668638b7eb0d39ded9cad3ed30db33c
Change-Id: I5b89aa33d35022fdca7f19c98f1bae51c173a876
2019-05-10 16:14:58 +00:00
Martin Stjernholm e954e3e47d Add the library absence check as a kati stage check.
(cherry picked from commit a5181f67a7)

Test: m systemimage
Test: build_test on Forrest
Bug: 132289438
Merged-In: I7a93cc0ac4480404a3d56c75eb43ae499e8a3a05
Change-Id: I6012e16bb02d4fea1cff51b20de94560da7a8d09
2019-05-10 16:14:50 +00:00
Martin Stjernholm 4c62151f8e Add libs that have been resolved to the library absence check.
(cherry picked from commit 7a2dde8bd5)

Test: m systemimage
Test: build_test on Forrest
Bug: 132289438
Merged-In: I9e517d3c2344b39cf2743a34723572e646675677
Change-Id: Id39a947c1522cf3a226ff1a4430c57bf7d861141
2019-05-10 16:14:29 +00:00
Martin Stjernholm 4a901c6d41 Ignore vndk-* subdirectories in the library absence check.
(cherry picked from commit 8222ce45dd)

Test: m systemimage
Test: build_test on Forrest
Bug: 132289438
Merged-In: I059c9d0edb78e52838a25cef0472807847d77417
Change-Id: I57359dc9f1aa2230acd3252118aaf41f42b7a913
2019-05-10 16:14:20 +00:00
Martin Stjernholm b4e549bfb7 Exclude lib/arm(64) from the library absence check.
(cherry picked from commit 4655206209)

Test: m systemimage
Test: build_test on Forrest
Bug: 132289438
Merged-In: I5dfb534aa2bc24a8d0a75fde31b139a6ed86e6a5
Change-Id: Ied158548f391d67f44ca31b74a3711d1cb5216fe
2019-05-10 16:13:54 +00:00
TreeHugger Robot cfca3e591d Merge "Move ro.boot.dynamic_partitions to vendor/build.prop" into qt-dev 2019-05-08 23:28:51 +00:00
Hridya Valsaraju ccd6279bef Move ro.boot.dynamic_partitions to vendor/build.prop
Bug: 132197773
Test: property present in vendor/build.prop

Currently, the property resides in product partition which gets
overwritten by the GSI image. Moving it to vendor will ensure
that the property is set even when a GSI image is flashed on the device.

Change-Id: I4d4a3c473194e15ba124a121f89bbb3ec1a73d19
Merged-In: I4d4a3c473194e15ba124a121f89bbb3ec1a73d19
2019-05-08 21:40:26 +00:00
Jiyong Park 18411a42f0 Ensure TARGET_FLATTEN_APEX == true when ro.apex.updatable is not set
TARGET_FLATTEN_APEX and ro.apex.updatable cannot be independently set.
For a device where updating APEXes is not supported, ro.apex.updatable
should not be set (or set to false) and TARGET_FLATTEN_APEX should be
set to true. For APEX-supporting devices, it is the opposite;
ro.apex.updatable == true and TARGET_FLATTEN_APEX is false (or not set).

To ensure this relationship, TARGET_FLATTEN_APEX is by default set to
true, and overridden to false when updatable_apex.mk is inherited.

Bug: 130623080
Test: choosecombo to Pixels 2 and later; get_build_var
TARGET_FLATTEN_APEX returns false.
choosecombo to the original Pixel and other non-Pixel targets;
get_build_var TARGET_FLATTEN_APEX returns true.
choosecombo to the cuttlefish; get_build_var TARGET_FLATTEN_APEX
returns false

Change-Id: Id73a594dd9838457e68e2793122592c11a84fc83
2019-05-08 20:51:21 +09:00
Bowgo Tsai 30a4eb54fc Using a test key to sign boot-debug.img if needed
When /boot partition is chained in AVB signing, libavb will try to
read AVB footer from the end of /boot partition, even if the device is
unlocked. However, this makes device unbootable when the unsigned
boot-debug.img is flashed on /boot partition. This CL uses a test key
from external/avb to sign the boot-debug.img if /boot partition is
chained.

Bug: 126493225
Bug: 129508966
Test: Enables chain partition for boot.img, `make bootimage_debug` then
      checks `avbtool info_image --image $OUT/boot-debug.img`
Test: `make bootimage_debug-nodeps`
Test: boot a device with a chained boot-debug.img

Change-Id: I870cb70c70b7d4d7a30b77bed58cbca6e007d5e3
Merged-In: I870cb70c70b7d4d7a30b77bed58cbca6e007d5e3
(cherry picked from commit 26b0a26e3e)
2019-05-07 17:27:43 +08:00
bohu c73e9b70dc emulator: support dynamic partitions
BUG: 125540538

Change-Id: I9d486f57ac4ec11b1bbe9ab97890d12441c3054e
Merged-In: I9d486f57ac4ec11b1bbe9ab97890d12441c3054e
2019-05-03 03:36:53 +00:00
Anton Hansson 669a9dbd99 Merge "Remove unneeded bootimage properties" into qt-dev 2019-05-02 08:24:48 +00:00
Ian Pedowitz 277bf1ae79 Merge "Revert "RESTRICT AUTOMERGE Updating the platform sdk version for Q"" into qt-dev 2019-05-02 00:59:09 +00:00
Ian Pedowitz 842119ab3a Revert "RESTRICT AUTOMERGE Updating the platform sdk version for Q"
This reverts commit 5e0226b816.

Reason for revert: QT SDK Finalization. Will be merged again on/after May 13th

Bug: 129975435
Change-Id: Ia3693b2a4907c4ca9be56cfe18fda35b8545abba
2019-05-02 00:55:38 +00:00
Ian Pedowitz 72cb9c892d Merge "RESTRICT AUTOMERGE Updating the platform sdk version for Q" into qt-dev 2019-05-02 00:53:29 +00:00
Yifan Hong d8900299d7 Merge "Add BOARD_SUPER_IMAGE_IN_UPDATE_PACKAGE flag." into qt-dev 2019-05-01 18:00:33 +00:00
TreeHugger Robot 258fbef820 Merge "Skip unneeded notice files for ETC modules." into qt-dev 2019-05-01 12:55:39 +00:00
Pete Bentley feef8d4af5 Merge "Remove libjavacrypto from system image." into qt-dev 2019-05-01 11:27:29 +00:00
Jaewoong Jung 48483a6903 Skip unneeded notice files for ETC modules.
Non-installable, non-library modules can still have notice files
attached if they are bundled in an apex module, in which case the
current make setting would generate an error. This change makes it just
ignore them silently if the module is ETC. Other classes will still
trigger an error.

Bug: 130138217
Test: manual build + TreeHugger
Merged-In: Ic7931f990369f744c8de62956a1a0a9c0451d6ab
Change-Id: Ic7931f990369f744c8de62956a1a0a9c0451d6ab
(cherry picked from commit dca3186b84)
2019-05-01 00:40:50 +00:00
Mathieu Chartier b5ce621e6b Merge "Add PRODUCT_DEX_PREOPT_RESOLVE_STARTUP_STRINGS" into qt-dev 2019-04-30 20:03:52 +00:00
Pete Bentley 5a78b371ed Remove libjavacrypto from system image.
The only copy needed is the one in the Conscrypt APEX.

Bug: 123925742
Test: m
Change-Id: Ieea8549d047750cf3580d6fe0204fdf55b6b8394
Merged-In: Ieea8549d047750cf3580d6fe0204fdf55b6b8394
2019-04-30 20:36:18 +01:00