This removes a blocker to BoringSSL marking the RSA struct opaque.
Sadly, OpenSSL's RSA_set0_key setter is a little tedious to use
correctly with error-handling, but it works.
Along the way, replace the byte reversing code with BoringSSL's native
little-endian BIGNUM conversion functions.
Test: libcrypto_utils_test passes
Change-Id: I298a6360d76fc7793462cd55bd57bc673c4975b3
The A/B version of this tool takes in a payload.bin file (from an OTA
package), and converts it into COWs in the new format. It uses the
CowWriter API to do this. This tool can be used to precisely see the
size of a COW relative to an OTA. Since there is one COW per partition,
it also takes an output folder:
make_cow_from_ab_ota payload.bin ./ota-cows/
If the payload is incremental, a source target-files package is needed.
It must be the exact package used to build the OTA, otherwise, the
conversion is likely to fail. Example:
make_cow_from_ab_ota -source_tf target-files-XYZ.zip \
payload.bin ./ota-cows/
Bug: 162274240
Test: manual tests
Change-Id: I22c86546f4166ee9df99165399646b7daa3519d5
This is an initial prototype of the new COW format. It does not have
support for merge sequencing or merge state tracking.
The reader and writer APIs have pure virtual interfaces to support
mocking. The writer implementation performs compression, but the reader
interface does not (yet), it only supports iterating over metadata and
performing basic validation.
Bug: 162274240
Test: manual tests
cow_api_test gtest
Change-Id: Ib9fddc1f210700688e6786917b023dfabd5fb3d9
create new profiles to allowing thawing and freezing back the freezer
cgroup
Bug: 151225245
Test: Manually verified that using the SetTaskProfiles method on the
profiles thaws and freezes back the freezer cgroup.
Change-Id: I7f3e193ebe79b49c1f6ac52b6138ff4ec26fc570
On devices without sdcardfs, these are only writable by the owning UID,
and/or the ext_data_rw/ext_obb_rw groups respectively.
Bug: 161134565
Bug: 162810387
Test: try to write to /sdcard/Android/data/ from shell uid
Change-Id: Idb4e07f967c8e888d95afa6c4a71595e0910ba0e
Fix odd bug that TranformFstabForDsu doesn't emplace entry to fstab.
.avb_keys should be set to "/avb", the directory that stores all DSU
avbpubkeys, instead of appending.
Bug: 165471299
Test: Boot a multipartition DSU package
Change-Id: I62ee2f8bf7113f6d2af8cc34ef19c9743029ea0a
Introduce a new systrace tag, TRACE_TAG_SYSPROP, for use with
system property.
Bug: 147275573
Test: build
Change-Id: I6f85f3f52f6580bab4ff43fc1dc0e87c689b054e
Merged-In: I6f85f3f52f6580bab4ff43fc1dc0e87c689b054e
(cherry picked from commit 573fc58bad)
Currently, while evaluating a Dwarf section, even pseudoregisters are
saved in regs_info. Since pseudoregisters are stored separately from
ordinary registers, trying to read them the usual way will result in
an out-of-bounds read. There's no memory corruption as regs_info is
big enough to store all existing pseudoregisters.
With this patch, pseudoregisters are simply not saved in regs_info.
Added new unit tests to cover the pseudo register cases.
Test: libunwindstack_test
Change-Id: If21b2a79f2fcca85644eec430f3d22e354b001ec
This was introduced years ago but never gained any users.
Test: build
Merged-In: Id2deb6de1839f995970c6350a1970a872f0b51cf
Change-Id: Id2deb6de1839f995970c6350a1970a872f0b51cf
I stumbled across this because of the `#ifdef __cplusplus` inside an
unguarded `namespace`, but this whole file should be deprecated and
removed in favor of static_assert.
Test: treehugger
Change-Id: I2b65db67e694115e915f0cc9d762b0fd41a7d2af
This reverts commit c935d0c450.
Reason for revert: invalid test, let's change it instead of breaking incremental installations
Change-Id: Ie5fb318c26d3a74cd2dbb16e09bda018efece211
Move responsibility for setting ro.crypto.type into fs_mgr_mount_all,
so that even if setting up the filesystem fails, the type is set
correctly and so errors are appropriately handled.
Bug: 162289984
Test: simulate a failure and check that it's set.
Change-Id: Ib061a454e7e21d7206c3c1fa8e88e16618099581
AudioHAL and SoundtriggerHAL is separeted HAL but running in thread with
same process id.
So, if both HAL try to open netlink socket using uevent_open_socket(),
secondly opening socket receives already-in-use error.
To prevent situation, set 0 to socket port id.
By the LINUX man page, "The kernel assigns the process ID to the first
netlink socket the process opens and assigns a unique nl_pid to every
netlink socket that the process subsequently creates."
Bug:163008274
Test: tested by opening netlink socket in AudioHAL and
SoundtriggerHAL both.
Signed-off-by: Gyeongtaek Lee <gt82.lee@samsung.com>
Change-Id: I5f9859e8dac749bf5d0998e825043c9988c202ba
not exist.
Bug: 163382088
Test: Ensure that, if the ./capacity_level does not exist,
that the device will shut down at 0 % SOC in an Health 2.1
implementation
Change-Id: I00822b4bfba5d823c1a30163ea6824e59d3aae32
This way, the profilers will know they have to reparse maps.
Bug: 163130539
Test: Verified updated unit tests pass.
Change-Id: I88a801ffdda12811eab5e4833dcf472f2d75c09a
Previously, chatty had logic that would skip a certain number of log
entries to satify pruning, but otherwise keep the reader connected.
This was a best-effort attempt at helping pruning and had additional
logic that handled further disruptions, if logd's memory was 2x the
allotted memory.
The new logic has two components:
1) memcpy() each individual log message in FlushTo() such that there
are no references to the underlying log data without a lock held.
Note, that this memcpy is completely negligible for performance.
2) In Prune(), immediately delete all log chunks required to reduce
memory to the allotted amount, which is now safe given 1). If readers
will lose logs, continue to print a warning.
This additionally makes the Clear() logic deterministic. It was
previously best effort in chatty, but will immediately and always
clear all logs for SerializedLogBuffer.
Bug: 163617910
Test: logging unit tests
Test: Prune() immediately frees buffers during high log pressure
Test: Clear() immediately frees buffers during high log pressure
Change-Id: I40fe9b791312af3dc256b166e5c34425f4ca51ac