mirror of
https://github.com/linuxboot/heads.git
synced 2024-12-18 20:47:55 +00:00
Add script for obtaining T440p me.bin blob
I performed an analysis of the differences between an me.bin blob I extracted from my T440p and the me.bin blob from Lenovo's website: https://github.com/osresearch/heads/pull/1282#issuecomment-1386292403.
This commit is contained in:
parent
7a29db11ed
commit
ed8c74e197
49
blobs/t440p/download-clean-me
Executable file
49
blobs/t440p/download-clean-me
Executable file
@ -0,0 +1,49 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
function usage() {
|
||||
echo -n \
|
||||
"Usage: $(basename "$0")
|
||||
Download Intel ME firmware from Lenovo, neutralize, and shrink.
|
||||
"
|
||||
}
|
||||
|
||||
ME_BIN_HASH="b7cf4c0cf514bbf279d9fddb12c34fca5c1c23e94b000c26275369b924ab9c25"
|
||||
|
||||
if [[ "${BASH_SOURCE[0]}" == "$0" ]]; then
|
||||
if [[ "${1:-}" == "--help" ]]; then
|
||||
usage
|
||||
else
|
||||
BLOB_DIR="$(cd "$(dirname "$0")" && pwd)"
|
||||
COREBOOT_DIR="$(find "${BLOB_DIR}/../../build/x86/" -maxdepth 1 -type d -name 'coreboot-*')"
|
||||
|
||||
pushd "$(mktemp -d)"
|
||||
|
||||
curl -O https://download.lenovo.com/pccbbs/mobiles/glrg22ww.exe
|
||||
innoextract glrg22ww.exe
|
||||
|
||||
mv app/ME9.1_5M_Production.bin "${COREBOOT_DIR}/util/me_cleaner"
|
||||
|
||||
popd
|
||||
|
||||
pushd "${COREBOOT_DIR}/util/me_cleaner"
|
||||
|
||||
# Neutralize and shrink Intel ME. Note that this doesn't include
|
||||
# --soft-disable to set the "ME Disable" or "ME Disable B" (e.g., High
|
||||
# Assurance Program) bits, as they are defined within the Flash
|
||||
# Descriptor.
|
||||
# https://github.com/corna/me_cleaner/wiki/External-flashing#neutralize-and-shrink-intel-me-useful-only-for-coreboot
|
||||
python me_cleaner.py -r -t -O me_shrinked.bin ME9.1_5M_Production.bin
|
||||
|
||||
mv me_shrinked.bin "${BLOB_DIR}/me.bin"
|
||||
rm ./*.bin
|
||||
|
||||
popd
|
||||
|
||||
if ! echo "${ME_BIN_HASH} ${BLOB_DIR}/me.bin" | sha256sum --check; then
|
||||
echo "SHA256 checksum for me.bin doesn't match."
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
fi
|
Loading…
Reference in New Issue
Block a user