chromium/chrome/browser/sync/test/integration/password_sharing_invitation_helper.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 "chrome/browser/sync/test/integration/password_sharing_invitation_helper.h"

#include <memory>
#include <optional>
#include <vector>

#include "base/containers/span.h"
#include "base/uuid.h"
#include "components/sync/engine/nigori/cross_user_sharing_public_key.h"
#include "components/sync/nigori/cryptographer_impl.h"

namespace password_sharing_helper {

namespace {
constexpr char kSignonRealm[] =;
constexpr char kOrigin[] =;
constexpr char kUsernameElement[] =;
constexpr char kPasswordElement[] =;
constexpr char kPasswordDisplayName[] =;
constexpr char kPasswordAvatarUrl[] =;

constexpr char kSenderEmail[] =;
constexpr char kSenderDisplayName[] =;
constexpr char kSenderProfileImageUrl[] =;

constexpr int kDefaultKeyVersion =;

sync_pb::CrossUserSharingPublicKey PublicKeyToProto(
    const syncer::CrossUserSharingPublicKey& public_key) {}

std::unique_ptr<syncer::CryptographerImpl> InitializeCryptographer(
    const syncer::CrossUserSharingPublicPrivateKeyPair& key_pair) {}

// Encrypts the invitation data to simulate the sending client.
std::vector<uint8_t> EncryptInvitationData(
    const sync_pb::PasswordSharingInvitationData& unencrypted_password_data,
    const sync_pb::CrossUserSharingPublicKey& recipient_public_key,
    const syncer::CrossUserSharingPublicPrivateKeyPair& sender_key_pair) {}
}  // namespace

sync_pb::PasswordSharingInvitationData DecryptInvitationData(
    const std::string& encrypted_data,
    const sync_pb::CrossUserSharingPublicKey& sender_public_key,
    const syncer::CrossUserSharingPublicPrivateKeyPair& recipient_key_pair) {}

sync_pb::IncomingPasswordSharingInvitationSpecifics
CreateEncryptedIncomingInvitationSpecifics(
    const sync_pb::PasswordSharingInvitationData& invitation_data,
    const sync_pb::UserDisplayInfo& sender_display_info,
    const sync_pb::CrossUserSharingPublicKey& recipient_public_key,
    const syncer::CrossUserSharingPublicPrivateKeyPair& sender_key_pair) {}

sync_pb::PasswordSharingInvitationData CreateDefaultIncomingInvitation(
    const std::string& username_value,
    const std::string& password_value) {}

sync_pb::UserDisplayInfo CreateDefaultSenderDisplayInfo() {}

}  // namespace password_sharing_helper