// Copyright 2019 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // // `certificate_tag` manipulates "tags" in Authenticode-signed Windows binaries. // // This library handles "superfluous certificate" tags. These are mock // certificates, inserted into the PKCS#7 certificate chain, that can contain // arbitrary data in extensions. Since they are also not hashed when verifying // signatures, that data can also be changed without invalidating it. // // The library supports PE32 exe files and MSI files. #ifndef CHROME_UPDATER_CERTIFICATE_TAG_H_ #define CHROME_UPDATER_CERTIFICATE_TAG_H_ #include <cstdint> #include <memory> #include <optional> #include <vector> #include "base/containers/span.h" namespace updater { namespace tagging { class BinaryInterface { … }; std::unique_ptr<BinaryInterface> CreatePEBinary( base::span<const uint8_t> contents); std::unique_ptr<BinaryInterface> CreateMSIBinary( base::span<const uint8_t> contents); } // namespace tagging } // namespace updater #endif // CHROME_UPDATER_CERTIFICATE_TAG_H_