1/* Hey Emacs use -*- mode: C -*- */
2/*
3 * Copyright (c) 2016 Cisco and/or its affiliates.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at:
7 *
8 *     http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17option version = "1.0.0";
18
19/** \brief Proof of Transit(POT): Set POT profile
20    @param id - id of the profile 
21    @param validator - True/False to indicate if this is verifier
22    @param secret_key - Verification key
23    @param secret_share - Share of the 1st polynomial
24    @param prime - Prime number used for modulo operation
25    @param max_bits - Max bits to be used for Random number generation
26    @param lpc - Lagrange basis polynomial
27    @param polynomial_public - pre-evaluated public polynomial 
28    @param list_name - name of this profile list
29*/
30autoreply define pot_profile_add {
31  u32 client_index;
32  u32 context;
33  u8 id;
34  u8 validator;
35  u64 secret_key;
36  u64 secret_share;
37  u64 prime;
38  u8  max_bits;
39  u64 lpc;
40  u64 polynomial_public;
41  string list_name[];
42};
43
44/** \brief Proof of Transit(POT): Activate POT profile in the list
45    @param id - id of the profile 
46    @param list_name - name of this profile list
47*/
48autoreply define pot_profile_activate {
49  u32 client_index;
50  u32 context;
51  u8 id;
52  string list_name[];
53};
54
55/** \brief Delete POT Profile 
56    @param client_index - opaque cookie to identify the sender
57    @param context - sender context, to match reply w/ request
58    @param list_name - name of profile list to delete
59*/
60autoreply define pot_profile_del {
61  u32 client_index;
62  u32 context;
63  string list_name[];
64};
65
66/** \brief Show POT Profiles
67    @param client_index - opaque cookie to identify the sender
68    @param context - sender context, to match reply w/ request
69    @param id - id of the profile
70*/
71define pot_profile_show_config_dump {
72  u32 client_index;
73  u32 context;
74  u8 id;
75};
76
77/** \brief Show POT profile reply
78    @param id - id of the profile
79    @param validator - True/False to indicate if this is verifier
80    @param secret_key - Verification key
81    @param secret_share - Share of the 1st polynomial
82    @param prime - Prime number used for modulo operation
83    @param max_bits - Max bits to be used for Random number generation
84    @param lpc - Lagrange basis polynomial
85    @param polynomial_public - pre-evaluated public polynomial
86    @param list_name_len - length of the name of this profile list
87    @param list_name - name of this profile list
88*/
89define pot_profile_show_config_details {
90  u32 context;
91  i32 retval;
92  u8 id;
93  u8 validator;
94  u64 secret_key;
95  u64 secret_share;
96  u64 prime;
97  u64 bit_mask;
98  u64 lpc;
99  u64 polynomial_public;
100};
101