chromium/components/ip_protection/common/ip_protection_config_http.cc

// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "components/ip_protection/common/ip_protection_config_http.h"

#include <optional>
#include <string>
#include <string_view>

#include "base/strings/strcat.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_split.h"
#include "base/strings/string_util.h"
#include "base/types/expected.h"
#include "net/base/features.h"
#include "services/network/public/cpp/resource_request.h"
#include "services/network/public/cpp/resource_request_body.h"
#include "services/network/public/cpp/shared_url_loader_factory.h"
#include "services/network/public/cpp/simple_url_loader.h"
#include "services/network/public/mojom/url_response_head.mojom.h"

namespace ip_protection {

namespace {
constexpr net::NetworkTrafficAnnotationTag kGetTokenTrafficAnnotation =;

// The maximum size of the IP Protection requests - 256 KB (in practice these
// should be much smaller than this).
const int kIpProtectionRequestMaxBodySize =;
const char kProtobufContentType[] =;

}  // namespace

IpProtectionConfigHttp::IpProtectionConfigHttp(
    scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory)
    :{}

IpProtectionConfigHttp::~IpProtectionConfigHttp() = default;

void IpProtectionConfigHttp::DoRequest(
    quiche::BlindSignMessageRequestType request_type,
    std::optional<std::string_view> authorization_header,
    const std::string& body,
    quiche::BlindSignMessageCallback callback) {}

void IpProtectionConfigHttp::OnDoRequestCompleted(
    std::unique_ptr<network::SimpleURLLoader> url_loader,
    quiche::BlindSignMessageCallback callback,
    std::unique_ptr<std::string> response) {}

}  // namespace ip_protection