Don't use temp file for public key.
If using public key from Omaha response, we wrote it to a temp file
which will be read back, this is unnecessary since we can keep it in
memory.
Test: update_engine_unittests
Change-Id: Ib9f7a9292b71b9d91a0b24c687cc989b79d3812b
diff --git a/payload_consumer/payload_metadata.h b/payload_consumer/payload_metadata.h
index 8748f6f..1b4c5c8 100644
--- a/payload_consumer/payload_metadata.h
+++ b/payload_consumer/payload_metadata.h
@@ -22,7 +22,7 @@
#include <string>
#include <vector>
-#include <base/files/file_path.h>
+#include <base/macros.h>
#include <brillo/secure_blob.h>
#include "update_engine/common/error_code.h"
@@ -66,8 +66,8 @@
// to the payload server doesn't exploit any vulnerability in the code that
// parses the protocol buffer.
ErrorCode ValidateMetadataSignature(const brillo::Blob& payload,
- std::string metadata_signature,
- base::FilePath path_to_public_key) const;
+ const std::string& metadata_signature,
+ const std::string& pem_public_key) const;
// Returns the major payload version. If the version was not yet parsed,
// returns zero.