X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=SecurityPkg%2FUserIdentification%2FUsbCredentialProviderDxe%2FUsbCredentialProvider.h;fp=SecurityPkg%2FUserIdentification%2FUsbCredentialProviderDxe%2FUsbCredentialProvider.h;h=83f7f9e2ca4cc422547c337ae7c89a1b2d434bec;hp=d0295b8de4f27e54d8c3fb61b64364d8036c02c1;hb=6f0b864812b3313b79e7beade487f0ca8ca5f28d;hpb=bfbe0beec10e391464a16e7d38bf8936955547a0 diff --git a/SecurityPkg/UserIdentification/UsbCredentialProviderDxe/UsbCredentialProvider.h b/SecurityPkg/UserIdentification/UsbCredentialProviderDxe/UsbCredentialProvider.h index d0295b8de4..83f7f9e2ca 100644 --- a/SecurityPkg/UserIdentification/UsbCredentialProviderDxe/UsbCredentialProvider.h +++ b/SecurityPkg/UserIdentification/UsbCredentialProviderDxe/UsbCredentialProvider.h @@ -24,7 +24,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #include #include -#include +#include #include #include @@ -86,7 +86,7 @@ typedef struct { has changed. If an enrolled user does exist, delete the user on the credential provider. - @param[in] This Points to this instance of EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of EFI_USER_CREDENTIAL2_PROTOCOL. @param[in] User The user profile to enroll. @retval EFI_SUCCESS User profile was successfully enrolled. @@ -104,20 +104,18 @@ typedef struct { EFI_STATUS EFIAPI CredentialEnroll ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This, + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, IN EFI_USER_PROFILE_HANDLE User ); /** Returns the user interface information used during user identification. - This function returns information about the form used when interacting with the - user during user identification. The form is the first enabled form in the form-set - class EFI_HII_USER_CREDENTIAL_FORMSET_GUID installed on the HII handle HiiHandle. If - the user credential provider does not require a form to identify the user, then this - function should return EFI_NOT_FOUND. + This function enrolls a user on this credential provider. If the user exists on + this credential provider, update the user information on this credential provider; + otherwise delete the user information on credential provider. - @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. @param[out] Hii On return, holds the HII database handle. @param[out] FormSetId On return, holds the identifier of the form set which contains the form used during user identification. @@ -132,7 +130,7 @@ CredentialEnroll ( EFI_STATUS EFIAPI CredentialForm ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This, + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, OUT EFI_HII_HANDLE *Hii, OUT EFI_GUID *FormSetId, OUT EFI_FORM_ID *FormId @@ -145,7 +143,7 @@ CredentialForm ( of pixels specified by Width and Height. If no such bitmap exists, then EFI_NOT_FOUND is returned. - @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. @param[in, out] Width On entry, points to the desired bitmap width. If NULL then no bitmap information will be returned. On exit, points to the width of the bitmap returned. @@ -163,7 +161,7 @@ CredentialForm ( EFI_STATUS EFIAPI CredentialTile ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This, + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, IN OUT UINTN *Width, IN OUT UINTN *Height, OUT EFI_HII_HANDLE *Hii, @@ -176,7 +174,7 @@ CredentialTile ( This function returns a string which describes the credential provider. If no such string exists, then EFI_NOT_FOUND is returned. - @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. @param[out] Hii On return, holds the HII database handle. @param[out] String On return, holds the HII string identifier. @@ -188,7 +186,7 @@ CredentialTile ( EFI_STATUS EFIAPI CredentialTitle ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This, + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, OUT EFI_HII_HANDLE *Hii, OUT EFI_STRING_ID *String ); @@ -201,7 +199,7 @@ CredentialTitle ( submitted on a form OR after a call to Default() has returned that this credential is ready to log on. - @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. @param[in] User The user profile handle of the user profile currently being considered by the user identity manager. If NULL, then no user profile is currently under consideration. @@ -218,7 +216,7 @@ CredentialTitle ( EFI_STATUS EFIAPI CredentialUser ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This, + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, IN EFI_USER_PROFILE_HANDLE User, OUT EFI_USER_INFO_IDENTIFIER *Identifier ); @@ -230,7 +228,7 @@ CredentialUser ( AutoLogon returns FALSE, then the user interface will be constructed by the User Identity Manager. - @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. @param[out] AutoLogon On return, points to the credential provider's capabilities after the credential provider has been selected by the user. @@ -241,7 +239,7 @@ CredentialUser ( EFI_STATUS EFIAPI CredentialSelect ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This, + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, OUT EFI_CREDENTIAL_LOGON_FLAGS *AutoLogon ); @@ -250,7 +248,7 @@ CredentialSelect ( This function is called when a credential provider is deselected by the user. - @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. @retval EFI_SUCCESS Credential provider successfully deselected. @@ -258,7 +256,7 @@ CredentialSelect ( EFI_STATUS EFIAPI CredentialDeselect ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This ); /** @@ -266,7 +264,7 @@ CredentialDeselect ( This function reports the default login behavior regarding this credential provider. - @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. @param[out] AutoLogon On return, holds whether the credential provider should be used by default to automatically log on the user. @@ -277,7 +275,7 @@ CredentialDeselect ( EFI_STATUS EFIAPI CredentialDefault ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This, + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, OUT EFI_CREDENTIAL_LOGON_FLAGS *AutoLogon ); @@ -286,7 +284,7 @@ CredentialDefault ( This function returns user information. - @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. @param[in] UserInfo Handle of the user information data record. @param[out] Info On entry, points to a buffer of at least *InfoSize bytes. On exit, holds the user information. If the buffer is too small @@ -306,7 +304,7 @@ CredentialDefault ( EFI_STATUS EFIAPI CredentialGetInfo ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This, + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, IN EFI_USER_INFO_HANDLE UserInfo, OUT EFI_USER_INFO *Info, IN OUT UINTN *InfoSize @@ -320,7 +318,7 @@ CredentialGetInfo ( another user information record handle until there are no more, at which point UserInfo will point to NULL. - @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL. + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. @param[in, out] UserInfo On entry, points to the previous user information handle or NULL to start enumeration. On exit, points to the next user information handle or NULL if there is no more user information. @@ -333,8 +331,31 @@ CredentialGetInfo ( EFI_STATUS EFIAPI CredentialGetNextInfo ( - IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This, + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, IN OUT EFI_USER_INFO_HANDLE *UserInfo ); +/** + Delete a user on this credential provider. + + This function deletes a user on this credential provider. + + @param[in] This Points to this instance of the EFI_USER_CREDENTIAL2_PROTOCOL. + @param[in] User The user profile handle to delete. + + @retval EFI_SUCCESS User profile was successfully deleted. + @retval EFI_ACCESS_DENIED Current user profile does not permit deletion on the user profile handle. + Either the user profile cannot delete on any user profile or cannot delete + on a user profile other than the current user profile. + @retval EFI_UNSUPPORTED This credential provider does not support deletion in the pre-OS. + @retval EFI_DEVICE_ERROR The new credential could not be deleted because of a device error. + @retval EFI_INVALID_PARAMETER User does not refer to a valid user profile handle. +**/ +EFI_STATUS +EFIAPI +CredentialDelete ( + IN CONST EFI_USER_CREDENTIAL2_PROTOCOL *This, + IN EFI_USER_PROFILE_HANDLE User + ); + #endif