Skip to content

Commit

Permalink
Delete Old Stack Cookie Library and Supporting Code
Browse files Browse the repository at this point in the history
Description

Delete the old stack cookie logic.

- [x] Impacts functionality?
  - **Functionality** - Does the change ultimately impact how firmware functions?
  - Examples: Add a new library, publish a new PPI, update an algorithm, ...
- [ ] Impacts security?
  - **Security** - Does the change have a direct security impact on an application,
    flow, or firmware?
  - Examples: Crypto algorithm change, buffer overflow fix, parameter
    validation improvement, ...
- [ ] Breaking change?
  - **Breaking change** - Will anyone consuming this change experience a break
    in build or boot behavior?
  - Examples: Add a new library class, move a module to a different repo, call
    a function in a new library class in a pre-existing module, ...
- [ ] Includes tests?
  - **Tests** - Does the change include any explicit test code?
  - Examples: Unit tests, integration tests, robot tests, ...
- [ ] Includes documentation?
  - **Documentation** - Does the change contain explicit documentation additions
    outside direct code modifications (and comments)?
  - Examples: Update readme file, add feature readme file, link to documentation
    on an a separate Web page, ...

How This Was Tested

Tested on GCC and VS builds of Q35

Integration Instructions

N/A
  • Loading branch information
TaylorBeebe committed Nov 21, 2023
1 parent a76234e commit ab03f95
Show file tree
Hide file tree
Showing 11 changed files with 0 additions and 503 deletions.
28 changes: 0 additions & 28 deletions MdePkg/Include/IndustryStandard/PeImage.h
Original file line number Diff line number Diff line change
Expand Up @@ -134,34 +134,6 @@ typedef struct {
UINT32 Size;
} EFI_IMAGE_DATA_DIRECTORY;

// MS_CHANGE_? - Something to do with Stack Cookies?
//
// Load Config Directory from PeCoff
//
typedef struct {
UINTN Size;
UINTN TimeDateStamp;
UINT8 MajorVersion;
UINT8 MinorVersion;
UINTN GlobalFlagsClear;
UINTN GlobalFlagsSet;
UINTN CriticalSectionDefaultTimeout;
UINTN DeCommitFreeBlockThreshold;
UINTN DeCommitTotalFreeThreshold;
UINTN LockPrefixTable; // VA
UINTN MaximumAllocationSize;
UINTN VirtualMemoryThreshold;
UINTN ProcessHeapFlags;
UINTN ProcessAffinityMask;
UINT8 CSDVersion;
UINT8 Reserved1;
UINTN EditList; // VA
UINTN SecurityCookie;
VOID **SEHandlerTable;
UINTN SEHandlerCount;
} EFI_IMAGE_LOAD_CONFIG_DIRECTORY;
// END

//
// Directory Entries
//
Expand Down
39 changes: 0 additions & 39 deletions MdePkg/Include/Library/BaseBinSecurityLib.h

This file was deleted.

31 changes: 0 additions & 31 deletions MdePkg/Include/Library/PeCoffLib.h
Original file line number Diff line number Diff line change
Expand Up @@ -230,37 +230,6 @@ PeCoffLoaderGetImageInfo (
IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
);

// MS_CHANGE_? START

/**
Retrieves the address of the SecurityCookie from the PE/COFF image.
This function locations the EFI_IMAGE_LOAD_CONFIG_DIRECTORY in the PE/COFF image
and gets the SecurityCookie field from this structure. This structure will only
exist in binaries built with the VS2013/VS2015 compilers without the /GS- flag.
NOTE: Only X64 binaries are supported at the moment
@param ImageContext The pointer to the image context structure that
describes the PE/COFF image that needs to be
examined by this function.
@param SecurityCookieAddress The pointer that receives the address of the
security cookie upon successful execution of this function
@retval RETURN_SUCCESS The information on the PE/COFF image was collected.
@retval RETURN_INVALID_PARAMETER ImageContext is NULL.
@retval RETURN_UNSUPPORTED The PE/COFF image is not supported.
**/
RETURN_STATUS
EFIAPI
PeCoffLoaderGetSecurityCookieAddress (
IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext,
OUT UINT64 **SecurityCookieAddress
);

// END

/**
Applies relocation fixups to a PE/COFF image that was loaded with PeCoffLoaderLoadImage().
Expand Down
40 changes: 0 additions & 40 deletions MdePkg/Library/BaseBinSecurityLibNull/BaseBinSecurityLibNull.c

This file was deleted.

24 changes: 0 additions & 24 deletions MdePkg/Library/BaseBinSecurityLibNull/BaseBinSecurityLibNull.inf

This file was deleted.

88 changes: 0 additions & 88 deletions MdePkg/Library/BaseBinSecurityLibRng/BaseBinSecurityLibRng.c

This file was deleted.

38 changes: 0 additions & 38 deletions MdePkg/Library/BaseBinSecurityLibRng/BaseBinSecurityLibRng.inf

This file was deleted.

18 changes: 0 additions & 18 deletions MdePkg/Library/BaseBinSecurityLibRng/X64/GSHandlerCheck.asm

This file was deleted.

This file was deleted.

24 changes: 0 additions & 24 deletions MdePkg/Library/BaseBinSecurityLibRng/X64/security_check_cookie.asm

This file was deleted.

Loading

0 comments on commit ab03f95

Please sign in to comment.