summaryrefslogtreecommitdiff
path: root/fuzz/pinweaver/pinweaver.proto
blob: 91aa273a0fe6d183a2565a53a09316ba190f39d2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
// Copyright 2018 The ChromiumOS Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

syntax = "proto3";

package fuzz.pinweaver;

import public "google/protobuf/wrappers.proto";

message ResetTree {
  uint32 bits_per_level = 1;
  uint32 height = 2;
}

message InsertLeaf {
  uint64 label = 1;
  bytes delay_schedule = 2;
  bytes low_entropy_secret = 3;
  bytes high_entropy_secret = 4;
  bytes reset_secret = 5;
  bytes path_hashes = 6;
}

message RemoveLeaf {
  uint64 label = 1;
  bytes leaf_hmac = 2;
  bytes path_hashes = 3;
}

message TryAuth {
  uint64 label = 1;
  bytes low_entropy_secret = 2;
  bytes unimported_leaf_data = 3;
}

message ResetAuth {
  uint64 label = 1;
  bytes reset_secret = 2;
  bytes unimported_leaf_data = 3;
}

message GetLog {
  uint32 index_of_root = 1;
}

message LogReplay {
  uint32 index_of_root = 1;
  bytes unimported_leaf_data = 2;
}

message Request {
  // A work around to provide the has_version() function.
  google.protobuf.UInt32Value version = 1;
  oneof request {
    ResetTree reset_tree = 2;
    InsertLeaf insert_leaf = 3;
    RemoveLeaf remove_leaf = 4;
    TryAuth try_auth = 5;
    ResetAuth reset_auth = 6;
    GetLog get_log = 7;
    LogReplay log_replay = 8;
  }
}