summaryrefslogtreecommitdiffstats
path: root/SecurityPkg/HddPassword/HddPassword.vfr
blob: 1df0c90897e8622403eae125ad6413023fc65861 (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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
/** @file
  HDD Password Configuration Formset.

  Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>

  SPDX-License-Identifier: BSD-2-Clause-Patent
**/

#include "HddPasswordHiiDataStruc.h"

formset
  guid      = HDD_PASSWORD_CONFIG_GUID,
  title     = STRING_TOKEN(STR_HDD_SECURITY_CONFIG),
  help      = STRING_TOKEN(STR_HDD_SECURITY_CONFIG),
  classguid = EFI_HII_PLATFORM_SETUP_FORMSET_GUID,

  varstore HDD_PASSWORD_CONFIG,
  name = HDD_PASSWORD_CONFIG,
  guid = HDD_PASSWORD_CONFIG_GUID;

  form formid = FORMID_HDD_MAIN_FORM,
    title  = STRING_TOKEN(STR_HDD_SECURITY_CONFIG);

    label HDD_DEVICE_ENTRY_LABEL;
    label HDD_DEVICE_LABEL_END;

  endform;

  form
    formid = FORMID_HDD_DEVICE_FORM,
    title = STRING_TOKEN(STR_HDD_SECURITY_HD);

    subtitle text = STRING_TOKEN(STR_SECURITY_HDD_PWD_DESC);

    subtitle text = STRING_TOKEN(STR_NULL);

        subtitle text = STRING_TOKEN(STR_SECURITY_HDD_BANNER_ONE);
        subtitle text = STRING_TOKEN(STR_SECURITY_HDD_BANNER_TWO);
        subtitle text = STRING_TOKEN(STR_SECURITY_HDD_BANNER_THREE);
        subtitle text = STRING_TOKEN(STR_SECURITY_HDD_BANNER_FOUR);
        subtitle text = STRING_TOKEN(STR_SECURITY_HDD_BANNER_FIVE);

    subtitle text = STRING_TOKEN(STR_NULL);

    subtitle text = STRING_TOKEN(STR_HDD_PASSWORD_CONFIG);

    subtitle text = STRING_TOKEN(STR_NULL);

    grayoutif  TRUE;
    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.Supported == 0;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_SEC_SUPPORTED),
            text   = STRING_TOKEN(STR_YES),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.Supported == 1;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_SEC_SUPPORTED),
            text   = STRING_TOKEN(STR_NO),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.Enabled == 0;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_SEC_ENABLED),
            text   = STRING_TOKEN(STR_YES),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.Enabled == 1;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_SEC_ENABLED),
            text   = STRING_TOKEN(STR_NO),
            flags  = 0,
            key    = 0;
    endif;


    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.Locked == 0;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_SEC_LOCKED),
            text   = STRING_TOKEN(STR_YES),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.Locked == 1;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_SEC_LOCKED),
            text   = STRING_TOKEN(STR_NO),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.Frozen == 0;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_SEC_FROZEN),
            text   = STRING_TOKEN(STR_YES),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.Frozen == 1;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_SEC_FROZEN),
            text   = STRING_TOKEN(STR_NO),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.UserPasswordStatus == 0;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_HDD_USER_PASSWORD_STS),
            text   = STRING_TOKEN(STR_INSTALLED),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.UserPasswordStatus == 1;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_HDD_USER_PASSWORD_STS),
            text   = STRING_TOKEN(STR_NOT_INSTALLED),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.MasterPasswordStatus == 0;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_HDD_MASTER_PASSWORD_STS),
            text   = STRING_TOKEN(STR_INSTALLED),
            flags  = 0,
            key    = 0;
    endif;

    suppressif ideqvallist HDD_PASSWORD_CONFIG.SecurityStatus.MasterPasswordStatus == 1;
        text
            help   = STRING_TOKEN(STR_EMPTY),
            text   = STRING_TOKEN(STR_HDD_MASTER_PASSWORD_STS),
            text   = STRING_TOKEN(STR_NOT_INSTALLED),
            flags  = 0,
            key    = 0;
    endif;
    endif;

    subtitle text = STRING_TOKEN(STR_NULL);

    grayoutif ideqval HDD_PASSWORD_CONFIG.SecurityStatus.Supported == 0;
      checkbox varid  = HDD_PASSWORD_CONFIG.Request.UserPassword,
            prompt      = STRING_TOKEN(STR_HDD_USER_PASSWORD),
            help        = STRING_TOKEN(STR_HDD_USER_PASSWORD_HELP),
            flags       = INTERACTIVE | RESET_REQUIRED,
            key         = KEY_HDD_USER_PASSWORD,
      endcheckbox;
    endif;

    grayoutif ideqval HDD_PASSWORD_CONFIG.SecurityStatus.Supported == 0;
      checkbox varid  = HDD_PASSWORD_CONFIG.Request.MasterPassword,
            prompt      = STRING_TOKEN(STR_HDD_MASTER_PASSWORD),
            help        = STRING_TOKEN(STR_HDD_MASTER_PASSWORD_HELP),
            flags       = INTERACTIVE | RESET_REQUIRED,
            key         = KEY_HDD_MASTER_PASSWORD,
      endcheckbox;
    endif;
  endform;

endformset;