diff options
author | lloyd <[email protected]> | 2010-09-13 12:28:27 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2010-09-13 12:28:27 +0000 |
commit | 27d79c87365105d6128afe9eaf8a82383976ed44 (patch) | |
tree | 9a4f0e1d5ae7ecd5c058c0293d9b546191990cdb /src/constructs/tss | |
parent | 9acfc3a50b31044e48d8dee5fc8030ad7f4518d4 (diff) |
Anywhere where we use MemoryRegion::begin to get access to the raw pointer
representation (rather than in an interator context), instead use &buf[0],
which works for both MemoryRegion and std::vector
Diffstat (limited to 'src/constructs/tss')
-rw-r--r-- | src/constructs/tss/tss.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/constructs/tss/tss.cpp b/src/constructs/tss/tss.cpp index ad45cfcec..1ae027a78 100644 --- a/src/constructs/tss/tss.cpp +++ b/src/constructs/tss/tss.cpp @@ -192,8 +192,8 @@ RTSS_Share::reconstruct(const std::vector<RTSS_Share>& shares) if(shares[i].size() < RTSS_HEADER_SIZE) throw Decoding_Error("Missing or malformed RTSS header"); - if(!same_mem(shares[0].contents.begin(), - shares[i].contents.begin(), RTSS_HEADER_SIZE)) + if(!same_mem(&shares[0].contents[0], + &shares[i].contents[0], RTSS_HEADER_SIZE)) throw Decoding_Error("Different RTSS headers detected"); } @@ -250,7 +250,7 @@ RTSS_Share::reconstruct(const std::vector<RTSS_Share>& shares) hash->update(secret, secret_len); SecureVector<byte> hash_check = hash->final(); - if(!same_mem(hash_check.begin(), secret + secret_len, hash->OUTPUT_LENGTH)) + if(!same_mem(&hash_check[0], secret + secret_len, hash->OUTPUT_LENGTH)) throw Decoding_Error("RTSS hash check failed"); return SecureVector<byte>(secret, secret_len); |