1 /** @file
2   Support for HSTI 1.0 specification, defined at
3   Microsoft Hardware Security Testability Specification.
4 
5   Copyright (c) 2015, Intel Corporation. All rights reserved.<BR>
6   This program and the accompanying materials
7   are licensed and made available under the terms and conditions of the BSD License
8   which accompanies this distribution.  The full text of the license may be found at
9   http://opensource.org/licenses/bsd-license.php
10 
11   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
12   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
13 
14 **/
15 
16 #ifndef __HSTI_H__
17 #define __HSTI_H__
18 
19 #pragma pack(1)
20 
21 #define ADAPTER_INFO_PLATFORM_SECURITY_GUID \
22   {0x6be272c7, 0x1320, 0x4ccd, { 0x90, 0x17, 0xd4, 0x61, 0x2c, 0x01, 0x2b, 0x25 }}
23 
24 #define PLATFORM_SECURITY_VERSION_VNEXTCS         0x00000003
25 
26 #define PLATFORM_SECURITY_ROLE_PLATFORM_REFERENCE 0x00000001  // IHV
27 #define PLATFORM_SECURITY_ROLE_PLATFORM_IBV       0x00000002
28 #define PLATFORM_SECURITY_ROLE_IMPLEMENTOR_OEM    0x00000003
29 #define PLATFORM_SECURITY_ROLE_IMPLEMENTOR_ODM    0x00000004
30 
31 typedef struct {
32   //
33   //  Return PLATFORM_SECURITY_VERSION_VNEXTCS
34   //
35   UINT32  Version;
36   //
37   // The role of the publisher of this interface.  Reference platform designers
38   // such as IHVs and IBVs are expected to return PLATFORM_SECURITY_ROLE_PLATFORM_REFERENCE
39   // and PLATFORM_SECURITY_ROLE_PLATFORM_IBV respectively.
40   // If the test modules from the designers are unable to fully verify all
41   // security features, then the platform implementers, OEMs and ODMs, will
42   // need to publish this interface with a role of Implementer.
43   //
44   UINT32  Role;
45   //
46   // Human readable vendor, model, & version of this implementation.
47   //
48   CHAR16  ImplementationID[256];
49   //
50   // The size in bytes of the SecurityFeaturesRequired and SecurityFeaturesEnabled arrays.
51   // The arrays must be the same size.
52   //
53   UINT32  SecurityFeaturesSize;
54   //
55   // IHV-defined bitfield corresponding to all security features which must be
56   // implemented to meet the security requirements defined by PLATFORM_SECURITY_VERSION Version.
57   //
58 //UINT8   SecurityFeaturesRequired[];     //Ignored for non-IHV
59   //
60   // Publisher-defined bitfield corresponding to all security features which
61   // have implemented programmatic tests in this module.
62   //
63 //UINT8   SecurityFeaturesImplemented[];
64   //
65   // Publisher-defined bitfield corresponding to all security features which
66   // have been verified implemented by this implementation.
67   //
68 //UINT8   SecurityFeaturesVerified[];
69   //
70   // A Null-terminated string, one failure per line (CR/LF terminated), with a
71   // unique identifier that the OEM/ODM can use to locate the documentation
72   // which will describe the steps to remediate the failure - a URL to the
73   // documentation is recommended.
74   //
75 //CHAR16	ErrorString[];
76 } ADAPTER_INFO_PLATFORM_SECURITY;
77 
78 #pragma pack()
79 
80 extern EFI_GUID gAdapterInfoPlatformSecurityGuid;
81 
82 #endif
83