@@ -8,11 +8,9 @@ use crate::{
8
8
Error , Result , WrapperErrorKind ,
9
9
} ;
10
10
use std:: convert:: TryFrom ;
11
- //////////////////////////////////////////////////////////////////////////////////
12
11
/// Hierarchy
13
12
///
14
13
/// Enum describing the object hierarchies in a TPM 2.0.
15
- //////////////////////////////////////////////////////////////////////////////////
16
14
#[ derive( Debug , Clone , Copy , PartialEq , Eq , Hash ) ]
17
15
pub enum Hierarchy {
18
16
Owner ,
@@ -74,9 +72,9 @@ impl TryFrom<TpmHandle> for Hierarchy {
74
72
}
75
73
}
76
74
77
- //////////////////////////////////////////////////////////////////////////////////
78
- /// Enables
79
- //////////////////////////////////////////////////////////////////////////////////
75
+ // ////////////////////////////////////////////////////////////////////////////////
76
+ // Enables
77
+ // ////////////////////////////////////////////////////////////////////////////////
80
78
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
81
79
pub enum Enables {
82
80
Owner ,
@@ -143,9 +141,9 @@ impl TryFrom<TpmHandle> for Enables {
143
141
}
144
142
}
145
143
146
- //////////////////////////////////////////////////////////////////////////////////
147
- /// HierarchyAuth
148
- //////////////////////////////////////////////////////////////////////////////////
144
+ // ////////////////////////////////////////////////////////////////////////////////
145
+ // HierarchyAuth
146
+ // ////////////////////////////////////////////////////////////////////////////////
149
147
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
150
148
pub enum HierarchyAuth {
151
149
Owner ,
@@ -206,13 +204,13 @@ impl TryFrom<TpmHandle> for HierarchyAuth {
206
204
}
207
205
}
208
206
}
209
- /// ///////////////////////////////////////////////////////////////////////////////
210
- /// TODO: HierarchyPolicy
211
- /// ///////////////////////////////////////////////////////////////////////////////
207
+ // ///////////////////////////////////////////////////////////////////////////////
208
+ // TODO: HierarchyPolicy
209
+ // ///////////////////////////////////////////////////////////////////////////////
212
210
213
- //////////////////////////////////////////////////////////////////////////////////
214
- /// Platform
215
- //////////////////////////////////////////////////////////////////////////////////
211
+ // ////////////////////////////////////////////////////////////////////////////////
212
+ // Platform
213
+ // ////////////////////////////////////////////////////////////////////////////////
216
214
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
217
215
pub enum Platform {
218
216
Platform ,
@@ -234,9 +232,9 @@ impl TryFrom<AuthHandle> for Platform {
234
232
}
235
233
}
236
234
}
237
- //////////////////////////////////////////////////////////////////////////////////
238
- /// Owner
239
- //////////////////////////////////////////////////////////////////////////////////
235
+ // ////////////////////////////////////////////////////////////////////////////////
236
+ // Owner
237
+ // ////////////////////////////////////////////////////////////////////////////////
240
238
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
241
239
pub enum Owner {
242
240
Owner ,
@@ -263,9 +261,9 @@ impl TryFrom<ObjectHandle> for Owner {
263
261
}
264
262
}
265
263
}
266
- //////////////////////////////////////////////////////////////////////////////////
267
- /// Endorsement
268
- //////////////////////////////////////////////////////////////////////////////////
264
+ // ////////////////////////////////////////////////////////////////////////////////
265
+ // Endorsement
266
+ // ////////////////////////////////////////////////////////////////////////////////
269
267
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
270
268
pub enum Endorsement {
271
269
Endorsement ,
@@ -292,9 +290,9 @@ impl TryFrom<ObjectHandle> for Endorsement {
292
290
}
293
291
}
294
292
}
295
- //////////////////////////////////////////////////////////////////////////////////
296
- /// Provision
297
- //////////////////////////////////////////////////////////////////////////////////
293
+ // ////////////////////////////////////////////////////////////////////////////////
294
+ // Provision
295
+ // ////////////////////////////////////////////////////////////////////////////////
298
296
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
299
297
pub enum Provision {
300
298
Owner ,
@@ -321,9 +319,9 @@ impl TryFrom<AuthHandle> for Provision {
321
319
}
322
320
}
323
321
}
324
- //////////////////////////////////////////////////////////////////////////////////
325
- /// Clear
326
- //////////////////////////////////////////////////////////////////////////////////
322
+ // ////////////////////////////////////////////////////////////////////////////////
323
+ // Clear
324
+ // ////////////////////////////////////////////////////////////////////////////////
327
325
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
328
326
pub enum Clear {
329
327
Owner ,
@@ -350,9 +348,9 @@ impl TryFrom<AuthHandle> for Clear {
350
348
}
351
349
}
352
350
}
353
- //////////////////////////////////////////////////////////////////////////////////
354
- /// NvAuth
355
- //////////////////////////////////////////////////////////////////////////////////
351
+ // ////////////////////////////////////////////////////////////////////////////////
352
+ // NvAuth
353
+ // ////////////////////////////////////////////////////////////////////////////////
356
354
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
357
355
pub enum NvAuth {
358
356
Platform ,
@@ -381,9 +379,9 @@ impl TryFrom<AuthHandle> for NvAuth {
381
379
}
382
380
}
383
381
}
384
- //////////////////////////////////////////////////////////////////////////////////
385
- /// Lockout
386
- //////////////////////////////////////////////////////////////////////////////////
382
+ // ////////////////////////////////////////////////////////////////////////////////
383
+ // Lockout
384
+ // ////////////////////////////////////////////////////////////////////////////////
387
385
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
388
386
pub enum Lockout {
389
387
Lockout ,
@@ -406,9 +404,9 @@ impl TryFrom<ObjectHandle> for Lockout {
406
404
}
407
405
}
408
406
409
- //////////////////////////////////////////////////////////////////////////////////
410
- /// NvIndex
411
- //////////////////////////////////////////////////////////////////////////////////
407
+ // ////////////////////////////////////////////////////////////////////////////////
408
+ // NvIndex
409
+ // ////////////////////////////////////////////////////////////////////////////////
412
410
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
413
411
pub enum NvIndex {
414
412
NvIndex ( NvIndexTpmHandle ) ,
@@ -428,9 +426,9 @@ impl From<NvIndex> for NvIndexTpmHandle {
428
426
}
429
427
}
430
428
431
- //////////////////////////////////////////////////////////////////////////////////
432
- /// AttachedComponent
433
- //////////////////////////////////////////////////////////////////////////////////
429
+ // ////////////////////////////////////////////////////////////////////////////////
430
+ // AttachedComponent
431
+ // ////////////////////////////////////////////////////////////////////////////////
434
432
#[ derive( Debug , Clone , Copy , PartialEq , Eq ) ]
435
433
pub enum AttachedComponent {
436
434
AttachedComponent ( AttachedComponentTpmHandle ) ,
@@ -450,8 +448,8 @@ impl From<AttachedComponent> for AttachedComponentTpmHandle {
450
448
}
451
449
}
452
450
453
- //////////////////////////////////////////////////////////////////////////////////
451
+ // ////////////////////////////////////////////////////////////////////////////////
454
452
// Act (authenticated timers)
455
453
//
456
454
// TODO: Figure out how to implement this. This is some kind of counter.
457
- //////////////////////////////////////////////////////////////////////////////////
455
+ // ////////////////////////////////////////////////////////////////////////////////
0 commit comments