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

Unified Diff: payload_signer.h

Issue 3592008: AU: Verify delta payload signature and signed hash. (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/update_engine.git
Patch Set: move /tmp files to /var/run Created 10 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « omaha_hash_calculator_unittest.cc ('k') | payload_signer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: payload_signer.h
diff --git a/payload_signer.h b/payload_signer.h
index 781a513d1aa4479ac62622843f3dd343039d1550..59affd3d438babbaf91ca20e1a635d3b5fa9cb9d 100644
--- a/payload_signer.h
+++ b/payload_signer.h
@@ -28,6 +28,12 @@ class PayloadSigner {
static bool SignatureBlobLength(const std::string& private_key_path,
uint64_t* out_length);
+ // Returns false if the payload signature can't be verified. Returns true
+ // otherwise and sets |out_hash| to the signed payload hash.
+ static bool VerifySignature(const std::vector<char>& signature_blob,
+ const std::string& public_key_path,
+ std::vector<char>* out_hash_data);
+
private:
// This should never be constructed
DISALLOW_IMPLICIT_CONSTRUCTORS(PayloadSigner);
« no previous file with comments | « omaha_hash_calculator_unittest.cc ('k') | payload_signer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698