| Index: delta_performer.cc
|
| diff --git a/delta_performer.cc b/delta_performer.cc
|
| index 54a69fb132f234dbb57088df09086ba8b64a4ca8..f973bc7d7a5bc3cd2dc997f6aeba73874cb0b0f4 100644
|
| --- a/delta_performer.cc
|
| +++ b/delta_performer.cc
|
| @@ -572,7 +572,8 @@ bool DeltaPerformer::ExtractSignatureMessage(
|
| bool DeltaPerformer::VerifyPayload(
|
| const string& public_key_path,
|
| const std::string& update_check_response_hash,
|
| - const uint64_t update_check_response_size) {
|
| + const uint64_t update_check_response_size,
|
| + bool* signature_failed) {
|
| string key_path = public_key_path;
|
| if (key_path.empty()) {
|
| key_path = kUpdatePayloadPublicKeyPath;
|
| @@ -604,7 +605,16 @@ bool DeltaPerformer::VerifyPayload(
|
| vector<char> hash_data = signed_hasher.raw_hash();
|
| PayloadSigner::PadRSA2048SHA256Hash(&hash_data);
|
| TEST_AND_RETURN_FALSE(!hash_data.empty());
|
| - TEST_AND_RETURN_FALSE(hash_data == signed_hash_data);
|
| + if (hash_data != signed_hash_data) {
|
| + LOG(ERROR) << "Public key verificaion failed. This is non-fatal. "
|
| + "Attached Signature:";
|
| + utils::HexDumpVector(signed_hash_data);
|
| + LOG(ERROR) << "Computed Signature:";
|
| + utils::HexDumpVector(hash_data);
|
| + if (signature_failed) {
|
| + *signature_failed = true;
|
| + }
|
| + }
|
| return true;
|
| }
|
|
|
|
|