chromium/services/network/restricted_udp_socket.h

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

#ifndef SERVICES_NETWORK_RESTRICTED_UDP_SOCKET_H_
#define SERVICES_NETWORK_RESTRICTED_UDP_SOCKET_H_

#include "base/component_export.h"
#include "net/base/address_list.h"
#include "net/base/net_error_details.h"
#include "net/dns/public/host_resolver_results.h"
#include "services/network/public/mojom/restricted_udp_socket.mojom.h"

#if BUILDFLAG(IS_CHROMEOS)
#include "services/network/public/mojom/socket_connection_tracker.mojom.h"
#endif  // BUILDFLAG(IS_CHROMEOS)

namespace network {

class UDPSocket;
class SimpleHostResolver;

// Forwards requests from the Renderer to the connected UDPSocket.
// We do not expose the UDPSocket directly to the Renderer, as that
// would allow a compromised Renderer to contact other end points.
class COMPONENT_EXPORT(NETWORK_SERVICE) RestrictedUDPSocket
    : public mojom::RestrictedUDPSocket {};

}  // namespace network

#endif  // SERVICES_NETWORK_RESTRICTED_UDP_SOCKET_H_