diff options
| author | Sami Tolvanen <samitolvanen@google.com> | 2014-11-14 00:03:40 +0000 |
|---|---|---|
| committer | Android Git Automerger <android-git-automerger@android.com> | 2014-11-14 00:03:40 +0000 |
| commit | 2dfadac1569126d72b2da42233afc908b7ec10a7 (patch) | |
| tree | 2fdc3064d474a16b9712caefe8afb4855b518668 /fs_mgr | |
| parent | 509f1c9aeee4fb2c5dd97bb4deeedcf8de0da900 (diff) | |
| parent | 9573a13bbc015c555adff1e4e0fbef2a18963111 (diff) | |
| download | core-2dfadac1569126d72b2da42233afc908b7ec10a7.tar.gz core-2dfadac1569126d72b2da42233afc908b7ec10a7.tar.bz2 core-2dfadac1569126d72b2da42233afc908b7ec10a7.zip | |
am 9573a13b: DO NOT MERGE: Switch fs_mgr to use SHA-256 instead of SHA-1
* commit '9573a13bbc015c555adff1e4e0fbef2a18963111':
DO NOT MERGE: Switch fs_mgr to use SHA-256 instead of SHA-1
Diffstat (limited to 'fs_mgr')
| -rw-r--r-- | fs_mgr/fs_mgr_verity.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs_mgr/fs_mgr_verity.c b/fs_mgr/fs_mgr_verity.c index ef7cf6e7d..f02781cb7 100644 --- a/fs_mgr/fs_mgr_verity.c +++ b/fs_mgr/fs_mgr_verity.c @@ -86,11 +86,11 @@ static RSAPublicKey *load_key(char *path) static int verify_table(char *signature, char *table, int table_length) { RSAPublicKey *key; - uint8_t hash_buf[SHA_DIGEST_SIZE]; + uint8_t hash_buf[SHA256_DIGEST_SIZE]; int retval = -1; // Hash the table - SHA_hash((uint8_t*)table, table_length, hash_buf); + SHA256_hash((uint8_t*)table, table_length, hash_buf); // Now get the public key from the keyfile key = load_key(VERITY_TABLE_RSA_KEY); @@ -104,7 +104,7 @@ static int verify_table(char *signature, char *table, int table_length) (uint8_t*) signature, RSANUMBYTES, (uint8_t*) hash_buf, - SHA_DIGEST_SIZE)) { + SHA256_DIGEST_SIZE)) { ERROR("Couldn't verify table."); goto out; } |
