blob: 5b18e87b63dfb516a096e42f278eabf355a47b2a [file] [log] [blame] [edit]
// 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 "cryptohome/flatbuffer_schemas/enumerations.fbs";
// Our Python generator removes the "_serialized_" namespace when generating
// the code, to avoid symbol clash with the code generated by flatc.
namespace cryptohome._serialized_;
// Defined the attributes that may be used in this schema file.
attribute "serializable";
// Policies applying to a specific auth factor type.
table SerializedUserAuthFactorTypePolicy {
// The type which this policy applies to. If this is unset then the policy
// is invalid and should be discarded.
type:SerializedAuthFactorType = null (id: 0);
// Intents which are explicitly enabled and disabled for this type. In a
// properly serialized policy intents should only appear in at most one of
// these lists but if an intent appears in both then the disable takes
// precedence over the enable.
enabled_intents:[SerializedAuthIntent] (id: 1);
disabled_intents:[SerializedAuthIntent] (id: 2);
}
// The persistent structure used to capture all user-global policy.
table SerializedUserPolicy (serializable) {
// A list of per-AuthFactorType policies. Each type should have at most one
// entry in this list, but if multiple entries appear the the last one in
// the list take precedence.
auth_factor_type_policy:[SerializedUserAuthFactorTypePolicy] (id: 0);
}
root_type SerializedUserPolicy;