From: Abner Chang <abner.ch...@amd.com> For the HTTPS connetion that doesn't require TLS peer verification, We introduce a new HTTP event HttpEventTlsConfigured to notify HTTP callback functions after TlsConfigureSession(). With this event, the upper layer HTTP application can listen to HttpEventTlsConfigured HTTP event and reconfigure TLS configuration data in the callback function to set TLS verify method to TLS_VERIFY_NONE. The use case such as Redfish service connction which doesn't require the TLS peer verification on the cetificate, especially to the Redfish service connection through the in-band network interface. The root cause we are fixing is the TLS config data is hardcoded in TlsConfigureSession() for any TLS child in HttpSupport.c. With this hardcoded code, HTTP application has no way to give the proper TLS config data when TLS session is initiated.
In V2, total six patches. Relocate HttpEventTlsConfigured event to the end of enum. This keeps the enum number backward compatiable. - Add 5/6 patch to uncrustify RedfishRestExDriver.h. - Fix typo in the commit sibject. In V1, total five patches: Patch 1/5: We agreed to refactor TlsCreateChild and install TLS on the given HTTP handle. Patch 2/5: We consider TLS certificate not found as a success case to ensures HTTP session is still initiated and HttpInitSession() returns EFI_SUCCESS to the caller. The failure is pushed back to TLS DXE driver if the HTTP communication actually requires certificate. Patch 3/5: Introduce HttpEventTlsConfigured HTTP callback event Patch 4/5: REST EX DXE provides HTTP event callback protocol Patch 5/5: REST EX DXE fix. Signed-off-by: Abner Chang <abner.ch...@amd.com> Cc: Saloni Kasbekar <saloni.kasbe...@intel.com> Cc: Zachary Clark-williams <zachary.clark-willi...@intel.com> Cc: Michael Brown <mc...@ipxe.org> Cc: Nickle Wang <nick...@nvidia.com> Cc: Igor Kulchytskyy <ig...@ami.com> Abner Chang (6): NetworkPkg/HttpDxe: Refactor TlsCreateChild NetworkPkg/HttpDxe: Consider TLS certificate not found as a success case NetworkPkg/HttpDxe: Add HttpEventTlsConfigured HTTP callback event RedfishPkg/RedfishRestExDxe: Implement EDKII_HTTP_CALLBACK_PROTOCOL RedfishPkg/RedfishRestExDxe: Uncrustify RedfishRestExDriver.h RedfishPkg/RedfishRestExDxe: Update Supported function .../RedfishRestExDxe/RedfishRestExDxe.inf | 3 + NetworkPkg/HttpDxe/HttpProto.h | 3 +- NetworkPkg/HttpDxe/HttpsSupport.h | 18 ++-- NetworkPkg/Include/Protocol/HttpCallback.h | 15 ++- .../RedfishRestExDxe/RedfishRestExDriver.h | 32 +++++-- NetworkPkg/HttpDxe/HttpImpl.c | 23 +---- NetworkPkg/HttpDxe/HttpProto.c | 8 +- NetworkPkg/HttpDxe/HttpsSupport.c | 95 ++++++++++++------- .../RedfishRestExDxe/RedfishRestExDriver.c | 85 +++++++++++++++++ 9 files changed, 204 insertions(+), 78 deletions(-) -- 2.37.1.windows.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#113327): https://edk2.groups.io/g/devel/message/113327 Mute This Topic: https://groups.io/mt/103577241/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-