History log of /external/vboot_reference/tests/vb2_api_tests.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
62d482ecddf5735076a085859cf40fcfa24671ee 29-Jan-2015 Daisuke Nojiri <dnojiri@chromium.org> add vb2api_get_pcr_digest

this api allows firmware to get the digest indicating boot mode status.

BUG=chromium:451609
TEST=VBOOT2=1 make run2tests
BRANCH=tot

Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org>
Change-Id: Idca7bc5f6aed947689ad7cf219805aad35047c7d
Reviewed-on: https://chromium-review.googlesource.com/244542
/external/vboot_reference/tests/vb2_api_tests.c
73e5eb38821d693244f841ce4f0a14546e5b6361 26-Jan-2015 Bill Richardson <wfrichar@chromium.org> vboot2: fix alignment issues on 32-bit architectures

We were assuming 8-byte alignment for buffers. That's not true on
32-bit architectures. We should make the alignment requirements
explicit (and correct) for all architectures.

BUG=chromium:452179
BRANCH=ToT
CQ-DEPEND=CL:243380
TEST=manual

USE=vboot2 FEATURES=test emerge-x86-alex vboot_reference

Change-Id: I120f23e9c5312d7c21ff9ebb6eea2bac1e430e37
Signed-off-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/243362
Reviewed-by: Randall Spangler <rspangler@chromium.org>
/external/vboot_reference/tests/vb2_api_tests.c
6f1b82ac14f341d9733d6e95d518b3ee352002ef 03-Dec-2014 Randall Spangler <rspangler@chromium.org> vboot2: Move old struct handling to lib20/

This is part 4 of a series of changes to rearrange the vboot2 library
so that it's possible to start using the new-style data structs. This
change moves knowledge of the old vboot1 data structs into lib20; 2lib
now contains only code which is common to both vboot2.x libraries
(that is, code which is data structure version agnostic).

No functional changes; just rearranging code and tests.

BUG=chromium:423882
BRANCH=none
TEST=make runtests && VBOOT2=1 make runtests (works with/withoug VBOOT2 flag)
And compile firmware for veyron_pinky
CQ-DEPEND=CL:233051

Change-Id: I8f9e67157575e5be14952ef4809c3dfafd92596d
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/233021
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
/external/vboot_reference/tests/vb2_api_tests.c
efa37b87f2b4cd4b4f515e96201502ae0408cec7 13-Nov-2014 Randall Spangler <rspangler@chromium.org> vboot2: Add api-level functions to use new data structures

And associated unit tests.

And fix a memory overwrite in the old vb_api_tests.c, which apparently
didn't touch a critical piece of the shared work buffer, but was still
wrong. (This was a problem in the test, not in the code being
tested.)

BUG=chromium:423882
BRANCH=none
TEST=VBOOT2=1 make runtests

Change-Id: I322fb7e6bb5214b0adcf5d6d48a0cd238abba88e
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/229738
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
/external/vboot_reference/tests/vb2_api_tests.c
a063a43ad776c9831051e62565c0136ce36d0b09 05-Nov-2014 Randall Spangler <rspangler@chromium.org> vboot2: pass const work buffers, and clarify min_offset output

When a work buffer is passed to a function, and duplicated inside that
function, allocations made against the duplicate are automatically
freed when the duplicate goes out of scope. Make that explicit in the
comments. And pass in const struct workbuf * instead of struct
workbuf *, to make it clear that the passed-in work buffer pointer is
not being altered by the function.

Also, comment that the value of min_offset becomes undefined if
vb2_verify_common_member() or vb2_verify_common_subobject() fails.

BUG=chromium:423882
BRANCH=none
TEST=VBOOT2=1 make runtests

Change-Id: Icc6010e6ef786f78cd2176a59d4d0e6e14905a11
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/227524
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
/external/vboot_reference/tests/vb2_api_tests.c
941e25fa59816cf6ae32a585b013f671eccbd813 29-Oct-2014 Aaron Durbin <adurbin@chromium.org> vb2: parse dev mode in phase1

The rest of the system software expects dev mode to be
orthogonal to recovery mode. However, vb2_fw_phase1() was
only checking recovery mode. The caller would then not
call vb2_fw_phase2() which checked the developer mode settings.
Fix this by doing the necessary steps in vb2_fw_phase1().

BUG=chrome-os-partner:33264
BRANCH=None
TEST=None yet.

Change-Id: I06da388c3ca33754ddb5937a2877fbc287946490
Signed-off-by: Aaron Durbin <adurbin@chromium.org>
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://chromium-review.googlesource.com/225906
Tested-by: Furquan Shaikh <furquan@chromium.org>
Commit-Queue: Furquan Shaikh <furquan@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Reviewed-by: Benson Leung <bleung@chromium.org>
Tested-by: Benson Leung <bleung@chromium.org>
/external/vboot_reference/tests/vb2_api_tests.c
f18038b750c43c2185e64db38d0d244c6810083b 24-Oct-2014 Randall Spangler <rspangler@chromium.org> vboot2: Move and rename functions

Move packed key functions to their own file, in preparation for
introducing support for vb2_packed_key2.

Rename the awfully-named vb2_verify_fw_preamble2() function to
vb2_load_fw_premable(), since the new structs actually have a
vb2_fw_preamble2 struct and that would be very confusing.

Rename vb2_verify_fw_keyblock() to vb2_load_fw_keyblock(), so it
matches.

No functional changes, just renaming.

BUG=chromium:423882
BRANCH=none
TEST=VBOOT2=1 make runtests

Change-Id: Ia914e48e6c5814ab3205b999ceda1aa2452206ff
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/225458
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
/external/vboot_reference/tests/vb2_api_tests.c
c8c2f023a4914a498c11b855210ef05d4e035d41 23-Oct-2014 Randall Spangler <rspangler@chromium.org> vboot2: use enum signature algorithm

This changes the internals of vboot2 to use the enumerated type for
signature algorithm. The conversion from crypto algorithm is done
only when unpacking the key. This is preparation for the vboot2 data
types, which separate signature and hash algorithms into their own
fields.

There is no external change in the calling API to vboot, and no change
to the external data structures.

BUG=chromium:423882
BRANCH=none
TEST=VBOOT2=1 make runtests

Change-Id: I2e176d186d88cc7541644e001e720b4aee456be0
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/225209
/external/vboot_reference/tests/vb2_api_tests.c
4eef812d68f64cc501d795131d95f8a2f27223b1 23-Oct-2014 Randall Spangler <rspangler@chromium.org> vboot2: use enum hash algorithm

This changes the internals of vboot2 to use the enumerated type for
hash algorithm. The conversion from crypto algorithm is done only
when unpacking the key (and ok, in checking the rsa padding, but that
goes away in the next change). This is preparation for the vboot2
data types, which separate signature and hash algorithms into their
own fields.

There is no external change in the calling API to vboot, and no change
to the external data structures.

BUG=chromium:423882
BRANCH=none
TEST=VBOOT2=1 make runtests

Change-Id: I9c6de08d742dab941beb806fbd2bfc1e11c01e2c
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/225208
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
/external/vboot_reference/tests/vb2_api_tests.c
9504754fee346569b4cdcaae9f54fa65cf3005d9 18-Oct-2014 Randall Spangler <rspangler@chromium.org> vboot2: move verify digest to 2common

This removes code duplicated between 2common.c and 2rsa.c. This is in
preparation for adding new unsigned hash algorithms.

BUG=chromium:423882
BRANCH=none
TEST=VBOOT2=1 make -j runtests

Change-Id: Ic9c542ae14d3b7f786129c1d52f8963847a94fb8
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/224780
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
/external/vboot_reference/tests/vb2_api_tests.c
a7ab8b50b8923afcfd7a9e6181892c4c8a2de250 11-Jun-2014 Randall Spangler <rspangler@chromium.org> vboot2: api-level routines

I'm breaking the last chunk of vboot2 into smaller pieces as I add
tests. This has the api-level routines actually called by depthcharge.

BUG=chromium:370082
BRANCH=none
TEST=make clean && VBOOT2=1 COV=1 make

Change-Id: Ic7c082fc5faa0b874b2fa5a15ebda7135dcafe0b
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/200151
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
/external/vboot_reference/tests/vb2_api_tests.c