Tianjie Xu
8bdb13dd9a
DO NOT MERGE: resolve merge conflicts of 5346da02 to klp-modular-dev am: 4eb997d52b -s ours
...
am: 3591cb48f5 -s ours
Change-Id: I173c8f1c1f68b57b3046f91525c5ac3d3acf184d
2017-01-20 02:26:06 +00:00
Tianjie Xu
3591cb48f5
DO NOT MERGE: resolve merge conflicts of 5346da02 to klp-modular-dev
...
am: 4eb997d52b -s ours
Change-Id: If5c4537e910fffddd757be2a80ca9c949e93ed93
2017-01-20 02:19:36 +00:00
Tianjie Xu
4eb997d52b
DO NOT MERGE: resolve merge conflicts of 5346da02 to klp-modular-dev
...
Change-Id: Ie52a9abae416bbb84ddc61bb7159a531de778c15
2017-01-19 16:18:31 -08:00
Tianjie Xu
94c8b5e5a6
DO NOT MERGE: Add a checker for signature boundary in verifier am: f616da1726 am: 5346da0220 -s ours am: a41cc29447 -s ours
...
am: 051dfa7ec3 -s ours
Change-Id: I88ff80ef082f32825f4ed860af9b9d67d282e11a
2017-01-19 18:41:01 +00:00
Tianjie Xu
051dfa7ec3
DO NOT MERGE: Add a checker for signature boundary in verifier am: f616da1726 am: 5346da0220 -s ours
...
am: a41cc29447 -s ours
Change-Id: Ib3a827173380145bf7a3fcd7e4f8386571228699
2017-01-19 18:39:02 +00:00
Tianjie Xu
a41cc29447
DO NOT MERGE: Add a checker for signature boundary in verifier am: f616da1726
...
am: 5346da0220 -s ours
Change-Id: I2952d0746c6cc00837c90370d09a30049d462df3
2017-01-19 18:36:01 +00:00
Tianjie Xu
0a34b17c8b
Add a checker for signature boundary in verifier
...
am: 54ea136fde
Change-Id: Ide2da96e322c6a913b7f2e950e43c4d11278338e
2017-01-18 22:22:16 +00:00
Tianjie Xu
5346da0220
DO NOT MERGE: Add a checker for signature boundary in verifier
...
am: f616da1726
Change-Id: I05a1a6775229a1041e1a93388a86262d36d6581b
2017-01-18 22:22:16 +00:00
Tianjie Xu
f616da1726
DO NOT MERGE: Add a checker for signature boundary in verifier
...
The 'signature_start' variable marks the location of the signature
from the end of a zip archive. And a boundary check is missing where
'signature_start' should be within the EOCD comment field. This causes
problems when sideloading a malicious package. Also add a corresponding
test.
Bug: 31914369
Test: Verification fails correctly when sideloading recovery_test.zip on
angler.
Change-Id: I6ea96bf04dac5d8d4d6719e678d504f957b4d5c1
(cherry-picked from f69e6a9475 )
(cherry picked from commit 54ea136fde )
2016-12-19 16:46:44 -08:00
Tianjie Xu
54ea136fde
Add a checker for signature boundary in verifier
...
The 'signature_start' variable marks the location of the signature
from the end of a zip archive. And a boundary check is missing where
'signature_start' should be within the EOCD comment field. This causes
problems when sideloading a malicious package. Also add a corresponding
test.
Bug: 31914369
Test: Verification fails correctly when sideloading recovery_test.zip on
angler.
Change-Id: I6ea96bf04dac5d8d4d6719e678d504f957b4d5c1
(cherry-picked from f69e6a9475 )
2016-12-16 16:24:09 -08:00
Matt Sarett
1f814d7630
resolve merge conflicts of 86a28d0 to klp-modular-dev am: a5bc59620f
...
am: 36acff7d7e
* commit '36acff7d7e88549bbeab6a08488ab48596d7fbc5':
DO NOT MERGE Use updated libpng API
Change-Id: I7f01d932235ef69640ed4859d0e62344b3b774de
2016-05-19 23:06:06 +00:00
Matt Sarett
36acff7d7e
resolve merge conflicts of 86a28d0 to klp-modular-dev
...
am: a5bc59620f
* commit 'a5bc59620fd43c99621eb98ac84cbeea867d0c93':
DO NOT MERGE Use updated libpng API
Change-Id: I3d8d27b08fd1fd89c6b8d9c39b883a45aecb83ce
2016-05-19 23:03:35 +00:00
Matt Sarett
a5bc59620f
resolve merge conflicts of 86a28d0 to klp-modular-dev
...
Change-Id: Ic0b085e008155da3718dab8fd5a36be6d4059aee
2016-05-19 15:47:25 -04:00
Matt Sarett
86a28d0aaf
DO NOT MERGE Use updated libpng API
...
am: 839b4e592a
* commit '839b4e592a7c81bdebe08fae4eef6e909c89acd6':
DO NOT MERGE Use updated libpng API
Change-Id: I7bbece70a4129554d953fd22c71527b2ca11262e
2016-05-19 19:26:12 +00:00
Matt Sarett
839b4e592a
DO NOT MERGE Use updated libpng API
...
BUG:23265085
Change-Id: Ibc521fae11dad22283d8469329326ef79525b414
2016-05-17 20:28:54 +00:00
Yabin Cui
877dcba47a
Fix integer overflows in recovery procedure. am: 1273956e69
...
am: 5978a71d29
* commit '5978a71d2954c7df02cbd0c51582ce4063346f77':
Fix integer overflows in recovery procedure.
2016-02-23 06:35:46 +00:00
Yabin Cui
5978a71d29
Fix integer overflows in recovery procedure.
...
am: 1273956e69
* commit '1273956e69a7d1d5b636f269050b446e0ced3f9b':
Fix integer overflows in recovery procedure.
2016-02-23 06:33:20 +00:00
Yabin Cui
1273956e69
Fix integer overflows in recovery procedure.
...
Bug: 26960931
Change-Id: Ieae45caccfb4728fcf514f0d920976585d8e6caf
(cherry picked from commit 4f2df162c6 )
2016-02-22 17:42:02 -08:00
Narayan Kamath
0e804d542a
am d396b9db: am 710b6bb9: am ec4b58ad: (-s ours) am ec63d564: Track usage of Vector / SortedVector from libutils DO NOT MERGE
...
* commit 'd396b9dbd99924f7c8687227b22220a87c85d9c7':
Track usage of Vector / SortedVector from libutils DO NOT MERGE
2015-09-16 22:33:14 +00:00
Narayan Kamath
d396b9dbd9
am 710b6bb9: am ec4b58ad: (-s ours) am ec63d564: Track usage of Vector / SortedVector from libutils DO NOT MERGE
...
* commit '710b6bb9d7d36ce16453850efc3112016a77e9ff':
Track usage of Vector / SortedVector from libutils DO NOT MERGE
2015-09-12 06:30:01 +00:00
Narayan Kamath
710b6bb9d7
am ec4b58ad: (-s ours) am ec63d564: Track usage of Vector / SortedVector from libutils DO NOT MERGE
...
* commit 'ec4b58ad8a21b511bf6b136792bb924eb6e9e299':
Track usage of Vector / SortedVector from libutils DO NOT MERGE
2015-09-10 20:55:33 +00:00
Narayan Kamath
ec4b58ad8a
am ec63d564: Track usage of Vector / SortedVector from libutils DO NOT MERGE
...
* commit 'ec63d564a86ad5b30f75aa307b4bd271f6a96a56':
Track usage of Vector / SortedVector from libutils DO NOT MERGE
2015-09-10 18:26:12 +00:00
Narayan Kamath
ec63d564a8
Track usage of Vector / SortedVector from libutils DO NOT MERGE
...
bug: 22953624
Change-Id: Ifcc17e39433ac91ca41da5d336fb3006dfbb65a8
2015-09-09 10:42:10 +00:00
Andres Morales
c94fa0b01b
DO NOT MERGE Revert "Erase PST partition if its marked to be erased."
...
This now gets done at the framework level. Doing it here breaks the signature on the partition.
This reverts commit ee19387905 .
Bug: 19967123
Change-Id: I447b926b733ca145f11a916d9569ce39889db627
2015-04-01 22:43:35 +00:00
Tao Bao
18f371d814
updater: Check the return value from ApplyImagePatch / ApplyBSDiffPatch
...
Return NULL to abort the update process. Note that returning ""
won't stop the script.
Change-Id: Ifd108c1356f7c92a905c8776247a8842c6445319
2015-03-11 09:53:56 -07:00
Jesse Zhao
71c4542931
am f66bf339: am 3e91f691: Bump up max_map_count value.
...
* commit 'f66bf33956eebba26bedc7f098dedc8a2c1cf942':
Bump up max_map_count value.
2015-02-26 23:34:49 +00:00
Jesse Zhao
f66bf33956
am 3e91f691: Bump up max_map_count value.
...
* commit '3e91f691a6bf6b154ea98982b073e84e86328baf':
Bump up max_map_count value.
2015-02-26 23:20:35 +00:00
Jesse Zhao
3e91f691a6
Bump up max_map_count value.
...
Change-Id: Id3e2c0795b817db9a85bc84cba2aa05d20179d39
Bug: 18503789
(cherry picked from commit 5bf74b238b )
2015-02-25 22:47:26 +00:00
Jesse Zhao
5bf74b238b
Bump up max_map_count value.
...
Change-Id: Id3e2c0795b817db9a85bc84cba2aa05d20179d39
Bug: 18503789
2015-01-08 16:02:46 -08:00
Sungmin Choi
a72512cd05
Add O_CREAT option for open
...
Factory reset fails if there is no file, for example, RECOVERY_COMMAND_FILE_TMP.
So create file as adding O_CREAT option if it does not exist.
error log:
--------- beginning of crash
12-10 02:35:17.190 3059 3059 F libc : Fatal signal 11 (SIGSEGV), code 1, fault addr 0x30 in tid 3059 (uncrypt)
12-10 02:35:17.296 766 1528 W NativeCrashListener: Couldn't find ProcessRecord for pid 3059
12-10 02:35:17.296 191 191 I DEBUG : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
12-10 02:35:17.296 191 191 E DEBUG : AM write failure (32 / Broken pipe)
12-10 02:35:17.296 191 191 I DEBUG : Build fingerprint: 'Android/aosp_hammerhead/hammerhead:5.1/LMP/hopemini12052127:userdebug/test-keys'
12-10 02:35:17.296 191 191 I DEBUG : Revision: '10'
12-10 02:35:17.297 191 191 I DEBUG : ABI: 'arm'
12-10 02:35:17.297 191 191 I DEBUG : pid: 3059, tid: 3059, name: uncrypt >>> /system/bin/uncrypt <<<
12-10 02:35:17.297 191 191 I DEBUG : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x30
12-10 02:35:17.302 191 191 I DEBUG : r0 00000001 r1 be94b690 r2 fffffe90 r3 b6fdbf7c
12-10 02:35:17.302 191 191 I DEBUG : r4 00000000 r5 00000000 r6 b6fd8ca4 r7 be94b67c
12-10 02:35:17.302 191 191 I DEBUG : r8 00000000 r9 ffffffff sl b6ff582b fp be94b68d
12-10 02:35:17.302 191 191 I DEBUG : ip b6fcfd08 sp be94b648 lr b6f98fe5 pc b6f98fe4 cpsr 20070030
12-10 02:35:17.303 191 191 I DEBUG :
12-10 02:35:17.303 191 191 I DEBUG : backtrace:
12-10 02:35:17.303 191 191 I DEBUG : #00 pc 00032fe4 /system/lib/libc.so (fputs+29)
12-10 02:35:17.303 191 191 I DEBUG : #01 pc 000016a1 /system/bin/uncrypt
12-10 02:35:17.303 191 191 I DEBUG : #02 pc 0000114b /system/bin/uncrypt
12-10 02:35:17.303 191 191 I DEBUG : #03 pc 00012df5 /system/lib/libc.so (__libc_init+44)
12-10 02:35:17.303 191 191 I DEBUG : #04 pc 000013cc /system/bin/uncrypt
12-10 02:35:17.325 191 191 I DEBUG :
12-10 02:35:17.325 191 191 I DEBUG : Tombstone written to: /data/tombstones/tombstone_00
Bug: 18709330
Change-Id: Ib5dccdd366e829049938a188ea5f98d9e4e282db
2014-12-10 21:50:46 -08:00
Patrick Tjin
f59b994264
Add basic navigation controls to log viewer.
...
Bug: 18642766
Change-Id: I95a6c8edf83513d421a041e79c15111b5c991dde
Signed-off-by: Patrick Tjin <pattjin@google.com >
2014-12-10 05:18:05 +00:00
Patrick Tjin
cd055ee72a
Save kernel logs to /cache/recovery
...
Bug: 18642766
Change-Id: I6c8b7d8f9ffb688d3afdfe0d47c4142e711e421d
Signed-off-by: Patrick Tjin <pattjin@google.com >
2014-12-10 05:17:14 +00:00
Michael Runge
37ad1f1273
Merge "Force write to disk while doing uncrypt" into lmp-mr1-dev
2014-12-09 23:58:56 +00:00
Michael Runge
5b9c4ce5a1
am b278c252: Add support for tune2fs file operations
...
* commit 'b278c252e148798346f85fc92eeea6afeb33fbf0':
Add support for tune2fs file operations
2014-11-24 02:37:03 +00:00
Michael Runge
4b54239173
Force write to disk while doing uncrypt
...
This should reduce errors if the device reboots before the blocks
are commited to disk.
Bug: 18481902
Change-Id: I13cda1c78955e4c83522fbcf87ddb16cc9f97683
2014-11-21 16:27:28 -08:00
Michael Runge
b278c252e1
Add support for tune2fs file operations
...
This allows tune2fs to be executed from within OTA scripts,
allowing for file system modifications without formatting the
partition
Bug: 18430740
Change-Id: I0c2e05b5ef4a81ecea043e9b7b99b545d18fe5e6
2014-11-21 13:02:03 -08:00
Heather Lee Wilson
de27d4cbb7
am e5879c36: Byte swap to support BGRA in recovery mode
...
* commit 'e5879c3639789d61803605c12371a4f291e0b3cc':
Byte swap to support BGRA in recovery mode
2014-11-14 20:26:51 +00:00
Heather Lee Wilson
e5879c3639
Byte swap to support BGRA in recovery mode
...
Fixes color palate of recovery mode when double buffer enabled.
Bug: 18169447
Change-Id: Ia50b0fb9afd8001dfd740c09ce109fa421e691f7
2014-11-14 12:00:18 -08:00
Michael Runge
2020564f21
am be81e51c: Use more aggressive sync writing to applypatch.
...
* commit 'be81e51c171a0cf9b9b5045ee949282b7f36d779':
Use more aggressive sync writing to applypatch.
2014-10-29 20:23:58 +00:00
Michael Runge
be81e51c17
Use more aggressive sync writing to applypatch.
...
We have seen cases where the boot partition is patched, but upon
recovery the partition appears to be corrupted. Open up all
patched files/partitions with O_SYNC, and do not ignore the
errors from fsync/close operations.
Bug: 18170529
Change-Id: I392ad0a321d937c4ad02eaeea9170be384a4744b
2014-10-29 13:00:21 -07:00
Michael Runge
e908a45420
am 042c3cd0: Force sync files written by minzip.
...
* commit '042c3cd04ec3ef416019fa382cd5b1a942bd79e1':
Force sync files written by minzip.
2014-10-29 18:51:51 +00:00
Michael Runge
042c3cd04e
Force sync files written by minzip.
...
Some files appear to be missing their sync to disk.
Bug: 18145574
Change-Id: Ic858624a4dd65bbfc54d30f3a13c607078270345
2014-10-28 19:49:57 -07:00
Michael Runge
fe8563f4f2
am 5ddf4293: Log mount/unmount errors to UI
...
* commit '5ddf4293df45a051c7900eeb62fb5ec4950b6cb6':
Log mount/unmount errors to UI
2014-10-24 23:17:43 +00:00
Michael Runge
5ddf4293df
Log mount/unmount errors to UI
...
Bug: 18092022
Change-Id: I6c42038ebeb1cfc1e7ca0d3e12310fdce1b990b0
2014-10-24 14:14:41 -07:00
Nick Kralevich
915d661ccc
am 68802416: unconditionally apply SELinux labels to symlinks
...
* commit '688024169df70336cc128ea8cc929174c53a501e':
unconditionally apply SELinux labels to symlinks
2014-10-24 17:43:15 +00:00
Nick Kralevich
688024169d
unconditionally apply SELinux labels to symlinks
...
At the end of the OTA script, we walk through /system, updating
all the permissions on the filesystem, including the UID, GID,
standard UNIX permissions, capabilities, and SELinux labels.
In the case of a symbolic link, however, we want to skip most of
those operations. The UID, GID, UNIX permissions, and capabilities
don't meaningfully apply to symbolic links.
However, that's not true with SELinux labels. The SELinux label on
a symbolic link is important. We need to make sure the label on the
symbolic link is always updated, even if none of the other attributes
are updated.
This change unconditionally updates the SELinux label on the symbolic
link itself. lsetfilecon() is used, so that the link itself is updated,
not what it's pointing to.
In addition, drop the ENOTSUP special case. SELinux has been a
requirement since Android 4.4. Running without filesystem extended
attributes is no longer supported, and we shouldn't even try to handle
non-SELinux updates anymore. (Note: this could be problematic if
these scripts are ever used to produce OTA images for 4.2 devices)
Bug: 18079773
Change-Id: I87f99a1c88fe02bb2914f1884cac23ce1b385f91
2014-10-23 20:46:33 -07:00
Michael Runge
da500cecf5
am 168f7778: Allow passing of mount args to mountFn
...
* commit '168f77787700f0e9f66675beef33c593a777e64e':
Allow passing of mount args to mountFn
2014-10-23 21:56:52 +00:00
Brian Carlstrom
4da9cdeab9
am 473967d8: Merge "Log to UI any metadata setting errors" into lmp-dev
...
* commit '473967d87ff9fc7a541c16ebdc56364c285d2862':
Log to UI any metadata setting errors
2014-10-23 21:56:52 +00:00
Michael Runge
168f777877
Allow passing of mount args to mountFn
...
Bug: 18079773
Bug: 18092222
Change-Id: Ifc3f3e123de729dfbb2f49414b3207afa96268d5
2014-10-23 18:13:26 +00:00
Brian Carlstrom
473967d87f
Merge "Log to UI any metadata setting errors" into lmp-dev
2014-10-23 17:18:13 +00:00