summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.c65
-rw-r--r--Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.h7
-rw-r--r--Nt32Pkg/Library/Nt32BdsLib/Nt32BdsLib.inf3
-rw-r--r--Nt32Pkg/Nt32Pkg.dsc2
-rw-r--r--Nt32Pkg/Nt32Pkg.fdf2
5 files changed, 79 insertions, 0 deletions
diff --git a/Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.c b/Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.c
index edfcbcfd58..0e5b9f5953 100644
--- a/Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.c
+++ b/Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.c
@@ -345,6 +345,11 @@ PlatformBdsPolicyBehavior (
PlatformBdsConnectSequence ();
//
+ // Perform user identification process
+ //
+ PlatformBdsUserIdentify ();
+
+ //
// Notes: current time out = 0 can not enter the
// front page
//
@@ -363,6 +368,10 @@ PlatformBdsPolicyBehavior (
PlatformBdsConnectConsole (gPlatformConsole);
PlatformBdsDiagnostics (EXTENSIVE, FALSE, BaseMemoryTest);
BdsLibConnectAll ();
+ //
+ // Perform user identification process
+ //
+ PlatformBdsUserIdentify ();
ProcessCapsules (BOOT_ON_FLASH_UPDATE);
break;
@@ -375,6 +384,11 @@ PlatformBdsPolicyBehavior (
PlatformBdsDiagnostics (EXTENSIVE, FALSE, BaseMemoryTest);
//
+ // Perform user identification process
+ //
+ PlatformBdsUserIdentify ();
+
+ //
// In recovery boot mode, we still enter to the
// frong page now
//
@@ -404,6 +418,11 @@ PlatformBdsPolicyBehavior (
PlatformBdsConnectSequence ();
//
+ // Perform user identification process
+ //
+ PlatformBdsUserIdentify ();
+
+ //
// Give one chance to enter the setup if we
// have the time out
//
@@ -558,3 +577,49 @@ LockKeyboards (
{
return EFI_UNSUPPORTED;
}
+
+
+EFI_STATUS
+PlatformBdsUserIdentify (
+ VOID
+ )
+/*++
+
+ Routine Description:
+
+ This function is to identify a valid user, if successed, handle the deferred images.
+
+ Arguments:
+
+ None.
+
+ Returns:
+
+ EFI_SUCCESS - User successfully identified.
+
+--*/
+{
+ EFI_STATUS Status;
+ EFI_USER_MANAGER_PROTOCOL *Manager;
+ EFI_USER_PROFILE_HANDLE User;
+
+ //
+ // Locate user manager driver
+ //
+ Status = gBS->LocateProtocol (
+ &gEfiUserManagerProtocolGuid,
+ NULL,
+ &Manager
+ );
+ if (EFI_ERROR (Status)) {
+ return Status;
+ }
+
+ //
+ // Identity user
+ //
+ Status = Manager->Identify (Manager, &User);
+ return Status;
+}
+
+
diff --git a/Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.h b/Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.h
index d9aafc8fcd..02136a29ea 100644
--- a/Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.h
+++ b/Nt32Pkg/Library/Nt32BdsLib/BdsPlatform.h
@@ -37,6 +37,8 @@ Abstract:
#include <Protocol/WinNtThunk.h>
#include <Protocol/WinNtIo.h>
+#include <Protocol/LoadedImage.h>
+#include <Protocol/UserManager.h>
#include <Guid/WinNtSystemConfig.h>
extern BDS_CONSOLE_CONNECT_ENTRY gPlatformConsole[];
@@ -116,4 +118,9 @@ PlatformBdsEnterFrontPage (
IN BOOLEAN ConnectAllHappened
);
+EFI_STATUS
+PlatformBdsUserIdentify (
+ VOID
+ );
+
#endif // _BDS_PLATFORM_H
diff --git a/Nt32Pkg/Library/Nt32BdsLib/Nt32BdsLib.inf b/Nt32Pkg/Library/Nt32BdsLib/Nt32BdsLib.inf
index 3708d679cb..c74e4d3dd3 100644
--- a/Nt32Pkg/Library/Nt32BdsLib/Nt32BdsLib.inf
+++ b/Nt32Pkg/Library/Nt32BdsLib/Nt32BdsLib.inf
@@ -56,6 +56,9 @@
[Guids]
gEfiWinNtSystemConfigGuid
+[Protocols]
+ gEfiUserManagerProtocolGuid
+
[Pcd.common]
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutRow
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn
diff --git a/Nt32Pkg/Nt32Pkg.dsc b/Nt32Pkg/Nt32Pkg.dsc
index 406ef8ffe5..ca82a285e5 100644
--- a/Nt32Pkg/Nt32Pkg.dsc
+++ b/Nt32Pkg/Nt32Pkg.dsc
@@ -464,6 +464,8 @@
MdeModulePkg/Universal/PlatformDriOverrideDxe/PlatformDriOverrideDxe.inf
+ SecurityPkg/UserIdentification/UserIdentificationDxe/UserIdentityManager.inf
+ SecurityPkg/UserIdentification/UserManagerDxe/UserProfileManager.inf
[BuildOptions]
DEBUG_*_IA32_DLINK_FLAGS = /EXPORT:InitializeDriver=$(IMAGE_ENTRY_POINT) /ALIGN:4096 /FILEALIGN:4096 /SUBSYSTEM:CONSOLE
RELEASE_*_IA32_DLINK_FLAGS = /ALIGN:4096 /FILEALIGN:4096
diff --git a/Nt32Pkg/Nt32Pkg.fdf b/Nt32Pkg/Nt32Pkg.fdf
index d2d8ccea76..2938b6bd5d 100644
--- a/Nt32Pkg/Nt32Pkg.fdf
+++ b/Nt32Pkg/Nt32Pkg.fdf
@@ -226,6 +226,8 @@ INF Nt32Pkg/WinNtGopDxe/WinNtGopDxe.inf
INF Nt32Pkg/WinNtSimpleFileSystemDxe/WinNtSimpleFileSystemDxe.inf
INF MdeModulePkg/Universal/PlatformDriOverrideDxe/PlatformDriOverrideDxe.inf
INF MdeModulePkg/Universal/DriverSampleDxe/DriverSampleDxe.inf
+INF SecurityPkg/UserIdentification/UserIdentificationDxe/UserIdentityManager.inf
+INF SecurityPkg/UserIdentification/UserManagerDxe/UserProfileManager.inf
INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf