summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c2
-rw-r--r--SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c2
-rw-r--r--SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c16
-rw-r--r--SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h1
-rw-r--r--SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c161
-rw-r--r--SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr24
-rw-r--r--SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c2
7 files changed, 150 insertions, 58 deletions
diff --git a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c b/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
index 20eb3eee08..f884226d97 100644
--- a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
+++ b/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
@@ -404,7 +404,7 @@ TcgCallback (
return EFI_INVALID_PARAMETER;
}
- if ((Action != EFI_BROWSER_ACTION_CHANGING) || (QuestionId != KEY_TPM_ACTION)) {
+ if ((Action != EFI_BROWSER_ACTION_CHANGED) || (QuestionId != KEY_TPM_ACTION)) {
return EFI_UNSUPPORTED;
}
diff --git a/SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c b/SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c
index afb090a919..cf7fe4079a 100644
--- a/SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c
+++ b/SecurityPkg/UserIdentification/PwdCredentialProviderDxe/PwdCredentialProvider.c
@@ -548,7 +548,7 @@ CredentialDriverCallback (
CHAR8 Password[CREDENTIAL_LEN];
CHAR16 *PromptStr;
- if (Action == EFI_BROWSER_ACTION_CHANGING) {
+ if (Action == EFI_BROWSER_ACTION_CHANGED) {
if (QuestionId == KEY_GET_PASSWORD) {
//
// Get and check password.
diff --git a/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c b/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c
index 268dfab469..adcf9bf652 100644
--- a/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c
+++ b/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManager.c
@@ -2411,8 +2411,7 @@ UserIdentifyManagerCallback (
Status = EFI_SUCCESS;
break;
- case EFI_BROWSER_ACTION_CHANGING:
- {
+ case EFI_BROWSER_ACTION_CHANGED:
if (QuestionId >= LABEL_PROVIDER_NAME) {
//
// QuestionId comes from the second Form (Select a Credential Provider if identity
@@ -2425,10 +2424,16 @@ UserIdentifyManagerCallback (
}
return EFI_SUCCESS;
}
-
+ break;
+
+ case EFI_BROWSER_ACTION_CHANGING:
//
// QuestionId comes from the first Form (Select a user to identify).
//
+ if (QuestionId >= LABEL_PROVIDER_NAME) {
+ return EFI_SUCCESS;
+ }
+
User = (USER_PROFILE_ENTRY *) mUserProfileDb->UserProfile[QuestionId & 0xFFF];
Status = GetIdentifyType (User, &PolicyType);
if (EFI_ERROR (Status)) {
@@ -2456,9 +2461,10 @@ UserIdentifyManagerCallback (
mCurrentUser = (EFI_USER_PROFILE_HANDLE) User;
mIdentified = TRUE;
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_EXIT;
+ if (Type == EFI_IFR_TYPE_REF) {
+ Value->ref.FormId = FORMID_INVALID_FORM;
+ }
}
- }
break;
default:
diff --git a/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h b/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h
index 5efc50d16b..b08ac46437 100644
--- a/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h
+++ b/SecurityPkg/UserIdentification/UserIdentifyManagerDxe/UserIdentifyManagerData.h
@@ -22,6 +22,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
#define FORMID_USER_FORM 1
#define FORMID_PROVIDER_FORM 2
+#define FORMID_INVALID_FORM 0x0FFF
//
// Labels definition.
diff --git a/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c b/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c
index 6e5bd06502..4b1eabaaed 100644
--- a/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c
+++ b/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManager.c
@@ -309,7 +309,7 @@ UserProfileManagerCallback (
Status = EFI_SUCCESS;
break;
- case EFI_BROWSER_ACTION_CHANGING:
+ case EFI_BROWSER_ACTION_CHANGED:
{
//
// Handle the request from form.
@@ -338,13 +338,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_SECOND_FORM_MASK) {
//
- // Enter delete user profile form.
- //
- case KEY_ENTER_NEXT_FORM:
- SelectUserToDelete ();
- break;
-
- //
// Delete specified user profile.
//
case KEY_SELECT_USER:
@@ -369,13 +362,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_SECOND_FORM_MASK) {
//
- // Enter modify user profile form.
- //
- case KEY_ENTER_NEXT_FORM:
- SelectUserToModify ();
- break;
-
- //
// Enter user profile information form.
//
case KEY_SELECT_USER:
@@ -384,13 +370,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_MODIFY_INFO_MASK) {
//
- // Display user information form.
- //
- case KEY_ENTER_NEXT_FORM:
- ModifyUserInfo ((UINT8) QuestionId);
- break;
-
- //
// Modify user name.
//
case KEY_MODIFY_NAME:
@@ -410,13 +389,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_MODIFY_IP_MASK) {
//
- // Display identity policy modify form.
- //
- case KEY_ENTER_NEXT_FORM:
- ModifyIdentityPolicy ();
- break;
-
- //
// Change credential provider option.
//
case KEY_MODIFY_PROV:
@@ -442,7 +414,7 @@ UserProfileManagerCallback (
//
case KEY_IP_RETURN_UIF:
SaveIdentityPolicy ();
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
break;
default:
@@ -459,13 +431,6 @@ UserProfileManagerCallback (
//
switch (QuestionId & KEY_MODIFY_AP_MASK) {
//
- // Display access policy modify form.
- //
- case KEY_ENTER_NEXT_FORM:
- ModidyAccessPolicy ();
- break;
-
- //
// Change access right choice.
//
case KEY_MODIFY_RIGHT:
@@ -545,7 +510,7 @@ UserProfileManagerCallback (
//
case KEY_AP_RETURN_UIF:
SaveAccessPolicy ();
- *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_APPLY;
+ *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_SUBMIT_EXIT;
break;
default:
@@ -642,6 +607,126 @@ UserProfileManagerCallback (
}
break;
+
+ case EFI_BROWSER_ACTION_CHANGING:
+ {
+ //
+ // Handle the request from form.
+ //
+ if (Value == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ //
+ // Judge first 2 bits.
+ //
+ switch (QuestionId & KEY_FIRST_FORM_MASK) {
+ //
+ // Delete user profile operation.
+ //
+ case KEY_DEL_USER:
+ //
+ // Judge next 2 bits.
+ //
+ switch (QuestionId & KEY_SECOND_FORM_MASK) {
+ //
+ // Enter delete user profile form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ SelectUserToDelete ();
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ //
+ // Modify user profile operation.
+ //
+ case KEY_MODIFY_USER:
+ //
+ // Judge next 2 bits.
+ //
+ switch (QuestionId & KEY_SECOND_FORM_MASK) {
+ //
+ // Enter modify user profile form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ SelectUserToModify ();
+ break;
+
+ //
+ // Enter user profile information form.
+ //
+ case KEY_SELECT_USER:
+ //
+ // Judge next 3 bits.
+ //
+ switch (QuestionId & KEY_MODIFY_INFO_MASK) {
+ //
+ // Display user information form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ ModifyUserInfo ((UINT8) QuestionId);
+ break;
+
+ //
+ // Modify identity policy.
+ //
+ case KEY_MODIFY_IP:
+ //
+ // Judge next 3 bits
+ //
+ switch (QuestionId & KEY_MODIFY_IP_MASK) {
+ //
+ // Display identity policy modify form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ ModifyIdentityPolicy ();
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ //
+ // Modify access policy.
+ //
+ case KEY_MODIFY_AP:
+ //
+ // Judge next 3 bits.
+ //
+ switch (QuestionId & KEY_MODIFY_AP_MASK) {
+ //
+ // Display access policy modify form.
+ //
+ case KEY_ENTER_NEXT_FORM:
+ ModidyAccessPolicy ();
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ default:
+ break;
+ }
+ break;
+
+ default:
+ break;
+ }
+ }
+ break;
+
default:
//
// All other action return unsupported.
diff --git a/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr b/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr
index d094d78a76..fa6d9e4a87 100644
--- a/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr
+++ b/SecurityPkg/UserIdentification/UserProfileManagerDxe/UserProfileManagerVfr.Vfr
@@ -114,12 +114,12 @@ formset
subtitle
text = STRING_TOKEN(STR_NULL_STRING);
- goto FORMID_USER_INFO,
- prompt = STRING_TOKEN(STR_SAVE),
- help = STRING_TOKEN(STR_IDENTIFY_SAVE_HELP),
- flags = INTERACTIVE,
- key = KEY_IP_RETURN;
-
+ text
+ help = STRING_TOKEN(STR_IDENTIFY_SAVE_HELP),
+ text = STRING_TOKEN(STR_SAVE),
+ flags = INTERACTIVE,
+ key = KEY_IP_RETURN;
+
endform;
//
@@ -146,12 +146,12 @@ formset
subtitle
text = STRING_TOKEN(STR_NULL_STRING);
- goto FORMID_USER_INFO,
- prompt = STRING_TOKEN(STR_SAVE),
- help = STRING_TOKEN(STR_ACCESS_SAVE_HELP),
- flags = INTERACTIVE,
- key = KEY_AP_RETURN;
-
+ text
+ help = STRING_TOKEN(STR_ACCESS_SAVE_HELP),
+ text = STRING_TOKEN(STR_SAVE),
+ flags = INTERACTIVE,
+ key = KEY_AP_RETURN;
+
endform;
//
diff --git a/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c b/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c
index 1d6d7aa2ce..f846a72ca9 100644
--- a/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c
+++ b/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c
@@ -314,7 +314,7 @@ SecureBootCallback (
return EFI_INVALID_PARAMETER;
}
- if ((Action != EFI_BROWSER_ACTION_CHANGING) || (QuestionId != KEY_SECURE_BOOT_ENABLE)) {
+ if ((Action != EFI_BROWSER_ACTION_CHANGED) || (QuestionId != KEY_SECURE_BOOT_ENABLE)) {
return EFI_UNSUPPORTED;
}