// 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. #ifndef COMPONENTS_MEDIA_DEVICE_SALT_MEDIA_DEVICE_SALT_DATABASE_H_ #define COMPONENTS_MEDIA_DEVICE_SALT_MEDIA_DEVICE_SALT_DATABASE_H_ #include <optional> #include "base/files/file_path.h" #include "base/sequence_checker.h" #include "base/time/time.h" #include "base/types/expected.h" #include "content/public/browser/storage_partition.h" #include "sql/database.h" namespace blink { class StorageKey; } // namespace blink namespace media_device_salt { // Utility to create a random salt. std::string CreateRandomSalt(); // Helper class that encapsulates the database logic for storing media device // salts. These salts are used to generate persistent media device IDs used by // APIs such as getUserMedia(), enumerateDevices() and some extension APIs. // // This class must be constructed and used on a sequence that allows blocking. class MediaDeviceSaltDatabase { … }; } // namespace media_device_salt #endif // COMPONENTS_MEDIA_DEVICE_SALT_MEDIA_DEVICE_SALT_DATABASE_H_