tlv.h
1 
22 #ifndef NDN_TLV_H
23 #define NDN_TLV_H
24 
25 #ifdef __cplusplus
26 extern "C" {
27 #endif
28 
29 enum {
30  ndn_Tlv_Interest = 5,
31  ndn_Tlv_Data = 6,
32  ndn_Tlv_Name = 7,
33  ndn_Tlv_ImplicitSha256DigestComponent = 1,
34  ndn_Tlv_NameComponent = 8,
35  ndn_Tlv_Selectors = 9,
36  ndn_Tlv_Nonce = 10,
37  // ndn_Tlv_<Unassigned> = 11,
38  ndn_Tlv_InterestLifetime = 12,
39  ndn_Tlv_MinSuffixComponents = 13,
40  ndn_Tlv_MaxSuffixComponents = 14,
41  ndn_Tlv_PublisherPublicKeyLocator = 15,
42  ndn_Tlv_Exclude = 16,
43  ndn_Tlv_ChildSelector = 17,
44  ndn_Tlv_MustBeFresh = 18,
45  ndn_Tlv_Any = 19,
46  ndn_Tlv_MetaInfo = 20,
47  ndn_Tlv_Content = 21,
48  ndn_Tlv_SignatureInfo = 22,
49  ndn_Tlv_SignatureValue = 23,
50  ndn_Tlv_ContentType = 24,
51  ndn_Tlv_FreshnessPeriod = 25,
52  ndn_Tlv_FinalBlockId = 26,
53  ndn_Tlv_SignatureType = 27,
54  ndn_Tlv_KeyLocator = 28,
55  ndn_Tlv_KeyLocatorDigest = 29,
56  ndn_Tlv_SelectedDelegation = 32
57 };
58 
59 enum {
60  ndn_Tlv_SignatureType_DigestSha256 = 0,
61  ndn_Tlv_SignatureType_SignatureSha256WithRsa = 1,
62  ndn_Tlv_SignatureType_SignatureSha256WithEcdsa = 3,
63  ndn_Tlv_SignatureType_SignatureHmacWithSha256 = 4
64 };
65 
66 enum {
67  ndn_Tlv_ContentType_Default = 0,
68  ndn_Tlv_ContentType_Link = 1,
69  ndn_Tlv_ContentType_Key = 2
70 };
71 
72 enum {
73  ndn_Tlv_NfdCommand_ControlResponse = 101,
74  ndn_Tlv_NfdCommand_StatusCode = 102,
75  ndn_Tlv_NfdCommand_StatusText = 103
76 };
77 
78 enum {
79  ndn_Tlv_ControlParameters_ControlParameters = 104,
80  ndn_Tlv_ControlParameters_FaceId = 105,
81  ndn_Tlv_ControlParameters_Uri = 114,
82  ndn_Tlv_ControlParameters_LocalControlFeature = 110,
83  ndn_Tlv_ControlParameters_Origin = 111,
84  ndn_Tlv_ControlParameters_Cost = 106,
85  ndn_Tlv_ControlParameters_Flags = 108,
86  ndn_Tlv_ControlParameters_Strategy = 107,
87  ndn_Tlv_ControlParameters_ExpirationPeriod = 109
88 };
89 
90 enum {
91  ndn_Tlv_LpPacket_LpPacket = 100,
92  ndn_Tlv_LpPacket_Fragment = 80,
93  ndn_Tlv_LpPacket_Sequence = 81,
94  ndn_Tlv_LpPacket_FragIndex = 82,
95  ndn_Tlv_LpPacket_FragCount = 83,
96  ndn_Tlv_LpPacket_Nack = 800,
97  ndn_Tlv_LpPacket_NackReason = 801,
98  ndn_Tlv_LpPacket_NextHopFaceId = 816,
99  ndn_Tlv_LpPacket_IncomingFaceId = 817,
100  ndn_Tlv_LpPacket_CachePolicy = 820,
101  ndn_Tlv_LpPacket_CachePolicyType = 821,
102  ndn_Tlv_LpPacket_IGNORE_MIN = 800,
103  ndn_Tlv_LpPacket_IGNORE_MAX = 959
104 };
105 
106 enum {
107  ndn_Tlv_Link_Preference = 30,
108  ndn_Tlv_Link_Delegation = 31
109 };
110 
111 enum {
112  ndn_Tlv_Encrypt_EncryptedContent = 130,
113  ndn_Tlv_Encrypt_EncryptionAlgorithm = 131,
114  ndn_Tlv_Encrypt_EncryptedPayload = 132,
115  ndn_Tlv_Encrypt_InitialVector = 133
116 };
117 
118 // For RepetitiveInterval.
119 enum {
120  ndn_Tlv_Encrypt_StartDate = 134,
121  ndn_Tlv_Encrypt_EndDate = 135,
122  ndn_Tlv_Encrypt_IntervalStartHour = 136,
123  ndn_Tlv_Encrypt_IntervalEndHour = 137,
124  ndn_Tlv_Encrypt_NRepeats = 138,
125  ndn_Tlv_Encrypt_RepeatUnit = 139,
126  ndn_Tlv_Encrypt_RepetitiveInterval = 140
127 };
128 
129 // For Schedule.
130 enum {
131  ndn_Tlv_Encrypt_WhiteIntervalList = 141,
132  ndn_Tlv_Encrypt_BlackIntervalList = 142,
133  ndn_Tlv_Encrypt_Schedule = 143
134 };
135 
136 #ifdef __cplusplus
137 }
138 #endif
139 
140 #endif