chromium/components/webauthn/core/browser/passkey_model_utils_unittest.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/webauthn/core/browser/passkey_model_utils.h"

#include "components/sync/protocol/webauthn_credential_specifics.pb.h"
#include "components/webauthn/core/browser/passkey_model.h"
#include "crypto/ec_private_key.h"
#include "testing/gtest/include/gtest/gtest.h"

namespace webauthn::passkey_model_utils {
namespace {

constexpr std::array<uint8_t, 32> kTestKey =;
constexpr int32_t kTestKeyVersion =;
constexpr std::string_view kRpId =;
static const PasskeyModel::UserEntity kTestUser(std::vector<uint8_t>{},
                                                "[email protected]",
                                                "Example User");

// Test decryption of the `encrypted` case for
// `WebAuthnCredentialSpecifics.encrypted_data`.
TEST(PasskeyModelUtilsTest, DecryptWebauthnCredentialSpecificsData_Encrypted) {}

// Test decryption of the `private_key` case for
// `WebAuthnCredentialSpecifics.encrypted_data`.
TEST(PasskeyModelUtilsTest, DecryptWebauthnCredentialSpecificsData_PrivateKey) {}

TEST(PasskeyModelUtilsTest, DecryptWebauthnCredentialSpecificsData_NotSet) {}

TEST(PasskeyModelUtilsTest, EncryptWebauthnCredentialSpecificsData) {}

TEST(PasskeyModelUtilsTest, GeneratePasskeyAndEncryptSecrets) {}

}  // namespace
}  // namespace webauthn::passkey_model_utils