e08cdbf2e13d91d433ad13dd3f24336ca8b009d1 |
|
27-Oct-2017 |
Sen Jiang <senj@google.com> |
Remove duplicates in ab_partitions.txt am: 34c711a0bd am: c4b29b8f79 Change-Id: I4eb223f5eac637d5f7f07ab83187b039191ecac4
|
34c711a0bd9d8ff0650ce18cbcaa436c6720fd6a |
|
26-Oct-2017 |
Sen Jiang <senj@google.com> |
Remove duplicates in ab_partitions.txt ab_partitions.txt is populated by AB_OTA_PARTITIONS which might be appended in multiple makefiles resulting in duplicates, currently this will result in payload being larger because it will include the operations for that partition twice and the client will write that partition twice when applying that payload. This patch uses awk in brillo_update_payload when reading ab_partitions.txt to remove the duplicates. Test: generate a payload with duplicated entries in ab_partitions.txt Change-Id: I07bd2401a64fbc77bbdc632901016e3860dee8d9
/system/update_engine/scripts/brillo_update_payload
|
8e768e9359d01008b286db1f6c54a6c3972a56b9 |
|
29-Jun-2017 |
Sen Jiang <senj@google.com> |
Add maximum timestamp to the payload. Added a new field max_timestamp in the protobuf, from now on update_engine will reject any payload without this field. If the OS build timestamp is newer than the max_timestamp, the payload will also be rejected to prevent downgrade. Bug: 36232423 Test: update_engine_unittests Merged-In: Ib20f5f35aaf41165013bada02bc8720917358237 Change-Id: Ib20f5f35aaf41165013bada02bc8720917358237 (cherry picked from commit 5011df680621eb477cad8b34f03fba5b542cc2f9)
/system/update_engine/scripts/brillo_update_payload
|
a566cb638023f12c9a64df31d83c464c13cf4d92 |
|
23-Aug-2017 |
Amin Hassani <ahassani@google.com> |
update_engine: fix verify for brillo major version Currently since the major version is checked before the apply payload (for brillo_update_payload verify), then it fails if there are more or less than two partitions. This patch forces the major version to whatever the target image is. This will not impact any production procedure. BUG=none TEST=brillo_update_payload verify --payload=payload.delta --source_image=25-4k-gzip.img --target_image=61-4k-gzip.img Change-Id: I0af9a56f9ad52c6b0670f7ace6c307d6071a1d7a Reviewed-on: https://chromium-review.googlesource.com/629638 Commit-Ready: Amin Hassani <ahassani@chromium.org> Tested-by: Amin Hassani <ahassani@chromium.org> Reviewed-by: Ben Chan <benchan@chromium.org> Reviewed-by: Sen Jiang <senj@chromium.org> (cherry picked from commit 70fce1e37af598f1bd28ae2bcdb62d597b64930d)
/system/update_engine/scripts/brillo_update_payload
|
1352093b7e5f1134ebfa99ad1991753ff4f3f33a |
|
26-Jul-2017 |
Amin Hassani <ahassani@google.com> |
update_engine: Add "verify" support to brillo_update_payload This change adds a new command "verify" to brillo_update_payload to verify the process of update by applying a delta or full payload to temporary target partitions and comparing them with the original target partitions. This is specially usefull when manually debuggin/testing delta performer operations. BUG=none TEST=brillo_update_payload verify --payload=payload.delta --source_image=link_8872.49.bin --target_image=link_9000.82.bin Change-Id: I4b30bc8a1088f4f72b681c6095cca6863a715078 Reviewed-on: https://chromium-review.googlesource.com/585565 Commit-Ready: Amin Hassani <ahassani@chromium.org> Tested-by: Amin Hassani <ahassani@chromium.org> Reviewed-by: Ben Chan <benchan@chromium.org> Reviewed-by: Sen Jiang <senj@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
a7ee9d0e6297a16d0f10cc7825c3b68867f19b24 |
|
03-Jun-2017 |
Andrey Ulanov <andreyu@google.com> |
update_engine: Remove zlib fingerprint checking This is not needed as imgdiff is not being used and will be replaced by puffin. Presence of this code makes updating to newer version of zlib impossible. (e.g. 1.2.8->1.2.11 update introduces some changes in compression algorithm which make compressed output different). BUG=None TEST="ebuild zlib.ebuild test" Change-Id: I50793f552a44faaba5771271fdcf2b4f4aeba6e4 Reviewed-on: https://chromium-review.googlesource.com/522949 Commit-Ready: Andrey Ulanov <andreyu@google.com> Tested-by: Andrey Ulanov <andreyu@google.com> Reviewed-by: Ben Chan <benchan@chromium.org> Reviewed-by: Sen Jiang <senj@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
04c2305d79b65a3013e3d5b329f1fcc128874479 |
|
13-Apr-2017 |
Alex Deymo <deymo@google.com> |
Ignore source partitions smaller than 4 KiB. When rounding down source partitions to the nearest 4 KiB boundary we hit an error condition that checks for empty partitions. This patch ignores partitions that are less than 4 KiB. Bug: 37266429 Test: ota_from_target_files -i target_files-3901180.zip target_files-3903096.zip ota.zip Change-Id: I165a3f9a9f73044d7520d042727caf1cf63a80c7
/system/update_engine/scripts/brillo_update_payload
|
5fbb110c73158e443efe1fcac87e6648c631b4c0 |
|
12-Jan-2017 |
Alex Deymo <deymo@google.com> |
Use ${TMPDIR} as the default working directory. This patch uses ${TMPDIR} as the default working directory, falling back to the old behaviour is /tmp was not set. This also passes the desired working directory to delta_generator as a TMPDIR env variable. Bug: 34250932 Test: `strace -e trace=open -f -- brillo_update_payload generate --payload pay.bin --target_image tf.zip --work_dir /tmp/foobar 2>&1 | grep tmp` only shows access to /tmp/foobar, not /tmp Change-Id: I4972a4010d7eed73b2fd1cc9c782b0775509b50c
/system/update_engine/scripts/brillo_update_payload
|
20bdc70e540e021c4a26553dfdbfd2fabe8ea432 |
|
08-Dec-2016 |
Alex Deymo <deymo@google.com> |
Parse Android .map files for unknown filesystem. When generating a filesystem during the Android build, we also generate a text file with .map extension with the list of files and the blocks in the filesystem they are located. For filesystems unsupported in delta_generator (like squashfs) we use this text file to produce efficient delta payloads. Bug: 28150981 Test: Added unittest for parsing. Generated a delta payload of a squashfs image. Change-Id: I154e72ac785c6f508290daa901fa7958b446c010
/system/update_engine/scripts/brillo_update_payload
|
135197526b9c0f5a9acac57a05129339f311bbca |
|
03-Aug-2016 |
Sen Jiang <senj@google.com> |
brillo_update_payload: Show correct error when delta_generator not found. If delta_generator is not in PATH, $(which delta_generator) will return 1 and then the script just go ahead to cleanup because trap is set on ERR, but the error message never got a chance to be showed. Bug: None Test: run brillo_update_payload without delta_generator in PATH. Change-Id: Ie7a6943f174f69e11ca795351d72c20516792f6f
/system/update_engine/scripts/brillo_update_payload
|
d0e9a893163bb6f70b2bb003cda238d7e1a532ed |
|
23-Jul-2016 |
Sen Jiang <senj@google.com> |
Call truncate through perl. The binary is not available, and we can't pack it in otatools in AOSP, have to use an alternative. Bug: 27880501 Test: Generate a payload for boot.img which is not multiple of 4KiB. Change-Id: I693e6cf441e3c9ea863d27704d6a31889c05cce6
/system/update_engine/scripts/brillo_update_payload
|
53f04d74f32397d8bffea9f020aaac2cafaab049 |
|
14-Jul-2016 |
Sen Jiang <senj@google.com> |
Remove extra "error:" in error message. die() will print "error:", results in double "error:". For example: $ brillo_update_payload generate brillo_update_payload: error: Error: you must specify an output filename with --payload FILENAME Test: brillo_update_payload generate Bug: None Change-Id: I4d2adc492b217be9b02362a9934e8563c61ae113
/system/update_engine/scripts/brillo_update_payload
|
a479a4d0039308fcfdda21f2a8ec8d040fd716f2 |
|
12-May-2016 |
Alex Deymo <deymo@google.com> |
Truncate source partitions to a multiple of 4 KiB. When flashing partitions that aren't a multiple of 4 KiB using fastboot, the last block of these partitions would not be padded with zeros. Full and incremental paylaods will pad with zeros and write them on the new target partitions, but the first incremental package after flashing a device would fail. This patch truncates the source partitions that aren't multiple of 4 KiB, discarding the data on the last partial 4 KiB block. Bug: 28626303 TEST=`brillo_update_payload generate ..` a null-incremental payload; boot.img includes mostly SOURCE_COPY and one REPLACE operation at the end. Change-Id: I25e0172fb074392488d96cd00e711c68adfa0e7f
/system/update_engine/scripts/brillo_update_payload
|
e0d04282910d423ddc950dd38224c001efc41d42 |
|
01-Mar-2016 |
Sen Jiang <senj@google.com> |
Check if zlib is compatible. Add a --zlib_fingerprint flag in delta_generator to check if the zlib of source image is compatible, and only enable IMGDIFF operation if it is. Test: Added unittest to check /etc/zlib_fingerprint Bug: 27156099 Change-Id: Ida346a99430c95cdc8a43e1055d6efa08f07ca25
/system/update_engine/scripts/brillo_update_payload
|
788c2d9b4b4da52f0874c391bda59610625e66aa |
|
09-Mar-2016 |
Sen Jiang <senj@google.com> |
brillo_update_payload: Keep the partitions order. The order in associative array is based on hash, but we need to make sure it's always rootfs and then kernel for Chrome OS. This patch adds a PARTITIONS_ORDER array and pass it to extract_image() for target image. For Android/Brillo, it will use ab_partitions_list.txt if found, for Chrome OS, it's always ( "system" "boot" ). Bug: None Test: Generated payload for edison and peppy. Change-Id: I29672befa14045573cba497784b67629a21578bf
/system/update_engine/scripts/brillo_update_payload
|
98e691cc6debda3ef671acba001bebd45da36377 |
|
05-Feb-2016 |
Alex Deymo <deymo@google.com> |
New "properties" sub-command to export payload properties. The new brillo_update_payload sub-command "properties" dumps a list of properties for a given signed or unsigned payload. These properties are normally included in the Omaha response, and extracted from python in chromite. This new sub-command helps to encapsulate the properties used by the server side wehn serving a payload and to let the Android application pass these required properties. The properties include the payload and metadata hash and size. Bug: 26991255 TEST=FEATURES=test emerge-link update_engine TEST=mmma system/update_engine TEST=`brillo_update_payload properties` for signed and unsigned payloads. Change-Id: I4602ea4b8dc269e4cc66df4293ef9765d8dd031d
/system/update_engine/scripts/brillo_update_payload
|
61e1fa89e01952d772f4aca843fa817a7a30fe66 |
|
20-Jan-2016 |
Alex Deymo <deymo@google.com> |
brillo_update_payload: Disable Brillo deltas for minor version <= 2. Support for deltas in the client landed for Brillo with minor version 3. While there shouldn't be any clients using such old version, developpers may have upload these images to our server and deltas are expected to fail. This CL makes brillo_update_payload exit with error code 100 when the source image does not support deltas. Bug: 26193066 TEST=`brillo_update_payload` from old image failed and returned exit code 100. Change-Id: Ia092316e73e5f5fce5a560e5eb19cf7f1ed1d0d2
/system/update_engine/scripts/brillo_update_payload
|
6f7b22c69bef53d33ae2bbb80b6682ff7ea8006e |
|
13-Nov-2015 |
Sen Jiang <senj@chromium.org> |
brillo_update_payload: Pass postinstall config file to delta_generator. If the target_files.zip contains META/postinstall_config.txt, then extract it and pass the path to delta_generator. BUG=b:24537566 TEST=Called brillo_update_payload with a target_files.zip that contains postinstall_config.txt Change-Id: I593c449e0194f3f72f4bcf712a03be472e12076d Reviewed-on: https://chromium-review.googlesource.com/312550 Commit-Ready: Sen Jiang <senj@chromium.org> Tested-by: Sen Jiang <senj@chromium.org> Reviewed-by: Sen Jiang <senj@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
f514c54ce3b91a00abcfb2eededa5d38af8008ce |
|
06-Nov-2015 |
Jason Kusuma <jkusuma@google.com> |
brillo_payload_generator: Adding warn function and flag verification - Adding warn function - Add check to verify that metadata_hash_file flag is set BUG=b:25479363 TEST=brillo_payload_generator called successfully in local env Change-Id: I1920c85c06be69cee93be74ef21d4f912714048d Reviewed-on: https://chromium-review.googlesource.com/310889 Reviewed-by: Alex Deymo <deymo@chromium.org> Tested-by: Jason Kusuma <jkusuma@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
168b535ceaeef22d501b5c14a167d323758e4ed6 |
|
04-Nov-2015 |
Alex Deymo <deymo@chromium.org> |
brillo_payload_generator: Pass the list of partitions to the generator. The list of A/B partitions is specified in ab_partitions.txt in the .zip file. This patch parses and passes that list to the delta_generator. BUG=b:24387863 TEST=brillo_payload_generator logs out passing the new flags. Change-Id: I6c9955054efd3df4a72a0b1d33f2da9b59771f02 Reviewed-on: https://chromium-review.googlesource.com/310921 Trybot-Ready: Alex Deymo <deymo@chromium.org> Tested-by: Alex Deymo <deymo@chromium.org> Reviewed-by: Jason Kusuma <jkusuma@chromium.org> Commit-Queue: Alex Deymo <deymo@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
83f2f70dd3aa3e4c8f16273bdd026b1f452b33a1 |
|
14-Oct-2015 |
Alex Deymo <deymo@chromium.org> |
Pass the correct major_version when generating updates. All Chrome OS updaters support major payload version 1 (or newer) and all Brillo updaters support major payload version 2, so this patch passes those version numbers to the delta_generator. When generating delta payloads, we use the major_version specified by the old updater. BUG=b:22024447 TEST=`brillo_generate_update_payload` generate, hash and sign for a recent build. Change-Id: Ib7509296a3bab79868e4fd718a0aaac163b29f69 Reviewed-on: https://chromium-review.googlesource.com/306101 Commit-Ready: Alex Deymo <deymo@chromium.org> Tested-by: Alex Deymo <deymo@chromium.org> Reviewed-by: Jason Kusuma <jkusuma@chromium.org> Reviewed-by: Gilad Arnold <garnold@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
bf1266fec223275ff19ef9624651946be9b9112a |
|
26-Oct-2015 |
Sen Jiang <senj@chromium.org> |
Pass out_hash_file to delta_generator. delta_generator now requires out_hash_file flag to be set if out_metadata_hash_file flag is set, so that it can calculate both hash in one pass. BUG=b:25234653 TEST=cros_generate_update_payload --out_metadata_hash_file ... Change-Id: If5a556717e722fc5a1c0f077aa2b1eebab7eb40d Reviewed-on: https://chromium-review.googlesource.com/308960 Commit-Ready: Alex Deymo <deymo@chromium.org> Tested-by: Sen Jiang <senj@chromium.org> Reviewed-by: Alex Deymo <deymo@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
957ce12832240c1e8a66af425d8524a3cbfdfd97 |
|
15-Oct-2015 |
Gilad Arnold <garnold@chromium.org> |
brillo_update_payload: Drop common.sh. This releases us from pulling in unnecessary dependencies, which is useful in some situations (like running this script in a Moblab image): 1) Source shflags directly. Look at the default location, then crosutils (chroot), then the current directory (for au-generator.zip). 2) Define a die function locally. BUG=b:24909273 TEST=Script runs in Moblab. Change-Id: Id4c8764ee20635b4822fa71b3719690a46c44f4a Reviewed-on: https://chromium-review.googlesource.com/305759 Commit-Ready: Gilad Arnold <garnold@chromium.org> Tested-by: Gilad Arnold <garnold@chromium.org> Reviewed-by: Mike Frysinger <vapier@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
9a4cae24e671face0c8786ff87e9d3de405cf4c8 |
|
09-Oct-2015 |
Jason Kusuma <jkusuma@google.com> |
brillo_update_payload: Add metadata_size_file flag Add optional metadata_size_file flag to output metadata size to the specified file. BUG=b:24751934 TEST=brillo_update_payload with the new flag specified Change-Id: Ic43dcadbb3624bdca824e55834b287151f00c75f Reviewed-on: https://chromium-review.googlesource.com/304932 Commit-Ready: Jason Kusuma <jkusuma@chromium.org> Tested-by: Jason Kusuma <jkusuma@chromium.org> Reviewed-by: Alex Deymo <deymo@chromium.org> Reviewed-by: Sen Jiang <senj@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
c64ffd591d1f4f4f7bacce0670bc0fce70830f36 |
|
26-Sep-2015 |
Alex Deymo <deymo@chromium.org> |
brillo_update_payload: Improve help message and flags. Different sub-commands have different flags. This patch improves the help message of each sub-command including only the flag used by that sub-command. BUG=None TEST=`brillo_update_payload command --help` for the different commands. Change-Id: I2a1d5c0f0a7cb04bf6d0f4495de83fb66e134c1b Reviewed-on: https://chromium-review.googlesource.com/302625 Commit-Ready: Alex Deymo <deymo@chromium.org> Tested-by: Alex Deymo <deymo@chromium.org> Reviewed-by: Jason Kusuma <jkusuma@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
c97df43fdc7c4fcfe06a76274f43211e6aa9255c |
|
26-Sep-2015 |
Alex Deymo <deymo@chromium.org> |
brillo_update_payload: Parse minor version from the metadata. META/update_engine_config.txt contains KEY=value config options with the supported version. This patch uses the supported minor version from the source image to generate the right delta payload. BUG=b:24406755 TEST=brillo_update_payload with old/new taget_files including and not including the update_engine_config.txt file. Change-Id: I3dacaeeeda9bbde3991a95fbf7834542af0b5780 Reviewed-on: https://chromium-review.googlesource.com/302624 Commit-Ready: Alex Deymo <deymo@chromium.org> Tested-by: Alex Deymo <deymo@chromium.org> Reviewed-by: Jason Kusuma <jkusuma@chromium.org> Reviewed-by: Mike Frysinger <vapier@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
48b502ab0cd56bf948602a45b990448f51e3e6b5 |
|
18-Sep-2015 |
Alex Deymo <deymo@chromium.org> |
brillo_update_payload: Extract Android target_files.zip. When generating payloads for Brillo, we need to extract the partitions from the target_files.zip image. This patch detects the format of the old/new image and extract them accordingly. CQ-DEPEND=CL:300654 BUG=b:23599483 TEST=brillo_update_payload generate --target_image dragonboard-target_files-2238075.zip --payload full-2238075.bin Change-Id: I6e38bad35ef9d904e12232a10947f379fcd2acd7 Reviewed-on: https://chromium-review.googlesource.com/300626 Commit-Ready: Alex Deymo <deymo@chromium.org> Tested-by: Alex Deymo <deymo@chromium.org> Reviewed-by: Jason Kusuma <jkusuma@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
89ff9e3221c358977f9c3124930ee6b559853740 |
|
16-Sep-2015 |
Alex Deymo <deymo@chromium.org> |
brillo_update_payload: Refactor code to extract_image_cros To support extracting images from either Android or Chrome OS format, this patch refactors the partition extraction function to a new extract_image_cros function called twice. This will then be wrapped with a extract_image function that will handle either format. The function stores the partition name->filename mapping in a bash associative array which then will be used to pass the filenames and partition names to delta_generator. This patch also includes the missing --metadata_signature_file flags. BUG=b:23599483 TEST=Ran brillo_update_payload generate with various full/delta images. Change-Id: I55e0c6f951b12e6b3e89ffb9fcd2240a2e2593cc Reviewed-on: https://chromium-review.googlesource.com/299971 Commit-Ready: Alex Deymo <deymo@chromium.org> Tested-by: Alex Deymo <deymo@chromium.org> Reviewed-by: Mike Frysinger <vapier@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|
be998f47ccb02c5f118f73e79729e9187c39e919 |
|
04-Sep-2015 |
Jason Kusuma <jkusuma@google.com> |
Initial implemetation of brillo_update_payload script BUG=b:23599483 TEST=Run locally with various commands/args combinations Change-Id: I9d8449450cc215b65cf199e0d0b221ca450ccd8e Reviewed-on: https://chromium-review.googlesource.com/297600 Commit-Ready: Jason Kusuma <jkusuma@chromium.org> Tested-by: Jason Kusuma <jkusuma@chromium.org> Reviewed-by: Alex Deymo <deymo@chromium.org>
/system/update_engine/scripts/brillo_update_payload
|