Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(95)

Issue 2523001: Implemented ReadObjectsFromSlot() to populate pkcs11.slots on initialization. (Closed)

Created:
10 years, 6 months ago by stevenjb
Modified:
9 years, 7 months ago
Reviewers:
rginda, Nathan Williams
CC:
chromium-os-reviews_chromium.org, Will Drewry
Base URL:
ssh://git@chromiumos-git/entd.git
Visibility:
Public.

Description

Implemented ReadObjectsFromSlot() to populate pkcs11.slots on initialization.

Patch Set 1 #

Total comments: 2

Patch Set 2 : Small change from feedback #

Unified diffs Side-by-side diffs Delta from patch set Stats (+241 lines, -73 lines) Patch
M js_object_wrapper.h View 1 chunk +1 line, -1 line 0 comments Download
M pkcs11.h View 3 chunks +6 lines, -0 lines 0 comments Download
M pkcs11.cc View 1 19 chunks +234 lines, -72 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
stevenjb
Medium sized changeset to read and parse objects in the TPM so that we know ...
10 years, 6 months ago (2010-06-02 22:57:14 UTC) #1
Nathan Williams
lgtm
10 years, 6 months ago (2010-06-02 23:37:13 UTC) #2
rginda
http://codereview.chromium.org/2523001/diff/1/3 File pkcs11.cc (right): http://codereview.chromium.org/2523001/diff/1/3#newcode1390 pkcs11.cc:1390: memcpy(&bytes.front(), idstrp, bytes.size()); Can you not construct the Blob ...
10 years, 6 months ago (2010-06-02 23:53:05 UTC) #3
stevenjb
10 years, 6 months ago (2010-06-03 00:48:41 UTC) #4
One small change to avoid memcpy.

http://codereview.chromium.org/2523001/diff/1/3
File pkcs11.cc (right):

http://codereview.chromium.org/2523001/diff/1/3#newcode1390
pkcs11.cc:1390: memcpy(&bytes.front(), idstrp, bytes.size());
On 2010/06/02 23:53:06, rginda wrote:
> Can you not construct the Blob with
>   chromeos::Blog bytes(idstrp, idstrlen);
> 
> rather than resorting to memcpy?

Ah, almost. I forgot that a vector::iterator can be implicitly constructed from
a T*, so Blob(idstrp, idstrp+idstrlen) is valid. (range is [A,B) ).

Done.

Powered by Google App Engine
This is Rietveld 408576698