Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(727)

Unified Diff: scripts/image_signing/resign_image.sh

Issue 3083025: Make signing script re-sign Firmware AU payload, and update rootfs hash. (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/vboot_reference.git
Patch Set: review fixes Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « scripts/image_signing/resign_firmwarefd.sh ('k') | scripts/image_signing/sign_official_build.sh » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scripts/image_signing/resign_image.sh
diff --git a/scripts/image_signing/resign_image.sh b/scripts/image_signing/resign_image.sh
index 6bfc9a45f9659150b649a92d0b89156c7f7757c6..5098f7d47834e8e9485214184840f3d573ab6253 100755
--- a/scripts/image_signing/resign_image.sh
+++ b/scripts/image_signing/resign_image.sh
@@ -9,6 +9,9 @@
# Both the cgpt tool and vbutil_kernel should be in the system path.
+# Load common constants and variables.
+. "$(dirname "$0")/common.sh"
+
# Abort on error
set -e
@@ -35,10 +38,8 @@ koffset="$(cgpt show -b -i 2 $1)"
ksize="$(cgpt show -s -i 2 $1)"
echo "Re-signing image ${src_bin} and outputting ${dst_bin}"
-temp_kimage=$(mktemp)
-trap "rm -f ${temp_kimage}" EXIT
-temp_out_vb=$(mktemp)
-trap "rm -f ${temp_out_vb}" EXIT
+temp_kimage=$(make_temp_file)
+temp_out_vb=$(make_temp_file)
# Grab the kernel image in preparation for resigning
dd if="${src_bin}" of="${temp_kimage}" skip=$koffset bs=$sector_size \
« no previous file with comments | « scripts/image_signing/resign_firmwarefd.sh ('k') | scripts/image_signing/sign_official_build.sh » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698