audk/RedfishPkg/Library/PlatformHostInterfaceBmcUsbNicLib/PlatformHostInterfaceBmcUsbNicLib.inf
Mike Maslenkin 7b9f2018d1 RedfishPkg: PlatformHostInterfaceBmcUsbNicLib: use credential protocol
This patch replaces call of IpmiSubmitCommand() issued
REDFISH_IPMI_BOOTSTRAP_CREDENTIAL_ENABLE IPMI command to check
whether bootstrap credential support enabled or not.
The problem is that in accordance with IPMI spec while handling
such command BMC creates bootstrap account. The credentials of this account
is returned as a response. Obviously in this code the response is not used.
From the other side there is an implementation
of EDKII_REDFISH_CREDENTIAL_PROTOCOL exists and used by
RedfishPlatformCredentialIpmiLib.

By design RedfishPlatformCredentialIpmiLib keeps returned bootstrap
credentials and uses it later. So all services using
EDKII_REDFISH_CREDENTIAL_PROTOCOL instance operates with a same
credentials.
Current design of PlatformHostInterfaceBmcUsbNicLib leads to creation
of two bootstrap accounts on BMC side. This is on nesseccary and one
account is not used at all.

Using EDKII_REDFISH_CREDENTIAL_PROTOCOL prevents from creating useless
bootstrap account on BMC side.

Signed-off-by: Mike Maslenkin <mike.maslenkin@gmail.com>
2024-09-05 03:40:45 +00:00

51 lines
1.5 KiB
INI

## @file
# Module to provide the platform Redfish Host Interface information
# of USB NIC Device exposed by BMC.
#
# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.
#
# SPDX-License-Identifier: BSD-2-Clause-Patent
#
##
[Defines]
INF_VERSION = 0x0001000b
BASE_NAME = PlatformHostInterfaceBmcUsbNicLib
FILE_GUID = C4837B58-225E-4352-8FDC-4C52A5D65891
MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
LIBRARY_CLASS = RedfishPlatformHostInterfaceLib
[Sources]
PlatformHostInterfaceBmcUsbNicLib.c
PlatformHostInterfaceBmcUsbNicLib.h
[Packages]
MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
NetworkPkg/NetworkPkg.dec
RedfishPkg/RedfishPkg.dec
[LibraryClasses]
BaseMemoryLib
DebugLib
IpmiCommandLib
MemoryAllocationLib
UefiLib
UefiBootServicesTableLib
[Protocols]
gEfiSimpleNetworkProtocolGuid ## CONSUMED
gEfiUsbIoProtocolGuid ## CONSUMED
gEfiDevicePathProtocolGuid ## CONSUMED
gEdkIIRedfishCredential2ProtocolGuid ## CONSUMED
[Pcd]
gEfiRedfishPkgTokenSpaceGuid.PcdRedfishHostName ## CONSUMED
gEfiRedfishPkgTokenSpaceGuid.PcdRedfishServiceUuid ## CONSUMED
gEfiRedfishPkgTokenSpaceGuid.PcdRedfishServicePort ## CONSUMED
[Depex]
gIpmiProtocolGuid
AND gEdkIIRedfishCredential2ProtocolGuid