Commit f38d1f74 authored by Timo Teräs's avatar Timo Teräs

fix xattr hash to be sha1

The hash type was accidentally changed in previous commit. Currently
csum->data cannot hold longer hash, so fix the hash.
parent beab8545
......@@ -632,7 +632,7 @@ void apk_fileinfo_hash_xattr_array(struct apk_xattr_array *xattrs, const EVP_MD
qsort(xattrs->item, xattrs->num, sizeof(xattrs->item[0]), cmp_xattr);
EVP_DigestInit_ex(mdctx, EVP_sha256(), NULL);
EVP_DigestInit_ex(mdctx, EVP_sha1(), NULL);
foreach_array_item(xattr, xattrs) {
hash_len_data(mdctx, strlen(xattr->name), xattr->name);
hash_len_data(mdctx, xattr->value.len, xattr->value.ptr);
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment