#include "components/web_package/signed_web_bundles/signed_web_bundle_id.h"
#include <ostream>
#include <string_view>
#include "base/containers/span.h"
#include "base/functional/bind.h"
#include "base/ranges/algorithm.h"
#include "base/strings/string_util.h"
#include "base/strings/stringprintf.h"
#include "base/types/expected.h"
#include "components/base32/base32.h"
#include "crypto/random.h"
namespace web_package {
base::expected<SignedWebBundleId, std::string> SignedWebBundleId::Create(
std::string_view encoded_id) { … }
SignedWebBundleId SignedWebBundleId::CreateForPublicKey(
const Ed25519PublicKey& public_key) { … }
SignedWebBundleId SignedWebBundleId::CreateForPublicKey(
const EcdsaP256PublicKey& public_key) { … }
SignedWebBundleId SignedWebBundleId::CreateForProxyMode(
base::span<const uint8_t, kProxyModeKeyLength> data) { … }
SignedWebBundleId SignedWebBundleId::CreateRandomForProxyMode() { … }
SignedWebBundleId::SignedWebBundleId(Type type, std::string_view encoded_id)
: … { … }
SignedWebBundleId::SignedWebBundleId(const SignedWebBundleId& other) = default;
SignedWebBundleId& SignedWebBundleId::operator=(
const SignedWebBundleId& other) = default;
SignedWebBundleId::~SignedWebBundleId() = default;
std::ostream& operator<<(std::ostream& os, const SignedWebBundleId& id) { … }
}