blob: c38e52a4a3a609792d99b918cc6066d58561a8f4 [file] [log] [blame] [edit]
// Copyright 2023 The ChromiumOS Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CRYPTOHOME_AUTH_FACTOR_FLATBUFFER_H_
#define CRYPTOHOME_AUTH_FACTOR_FLATBUFFER_H_
#include <optional>
#include "cryptohome/auth_factor/type.h"
#include "cryptohome/flatbuffer_schemas/enumerations.h"
namespace cryptohome {
// Convert AuthFactorType to and from the serialized flatbuffer type.
std::optional<SerializedAuthFactorType> SerializeAuthFactorType(
AuthFactorType type);
AuthFactorType DeserializeAuthFactorType(SerializedAuthFactorType type);
} // namespace cryptohome
#endif // CRYPTOHOME_AUTH_FACTOR_FLATBUFFER_H_