From 7483535256a517819d0d0e037458d7e6a829b581 Mon Sep 17 00:00:00 2001 From: Matthew Johnson Date: Fri, 26 Jan 2018 09:30:07 -0800 Subject: [PATCH] Handle bundle-add hash failures Fixes #252 Fixes #370 Fixes #371 When failing to add bundle with a file with the wrong hash remove the file and fall back to the verify_fix_path. Improve warnings so they don't look like errors until they are actually errors. Add tests so we don't regress in this regard. Signed-off-by: Matthew Johnson --- Makefile.am | 2 + src/bundle.c | 18 +++++--- src/helpers.c | 4 +- .../bundleadd/bad-hash-state/lines-checked | 5 +++ .../bad-hash-state/target-dir/testfile | 1 + .../target-dir/usr/lib/os-release | 9 ++++ .../usr/share/clear/bundles/os-core | 0 .../bundleadd/bad-hash-state/test.bats | 44 +++++++++++++++++++ .../bad-hash-state/web-dir/10/Manifest.MoM | 9 ++++ .../web-dir/10/Manifest.os-core | 14 ++++++ .../web-dir/10/Manifest.test-bundle | 8 ++++ ...b241166c4c6d0665204977274093f74851380d49b5 | 1 + ...b241166c4c6d0665204977274093f74851380d49b5 | 1 + .../web-dir/version/formatstaging/latest | 1 + .../bundleadd/bad-hash/lines-checked | 6 +++ .../bad-hash/target-dir/usr/lib/os-release | 9 ++++ .../usr/share/clear/bundles/os-core | 0 test/functional/bundleadd/bad-hash/test.bats | 35 +++++++++++++++ .../bad-hash/web-dir/10/Manifest.MoM | 9 ++++ .../bad-hash/web-dir/10/Manifest.os-core | 14 ++++++ .../bad-hash/web-dir/10/Manifest.test-bundle | 8 ++++ ...bfdbdec784afef5a82ffa54e8c93bda3e0883360a3 | 1 + ...bfdbdec784afef5a82ffa54e8c93bda3e0883360a3 | 1 + .../web-dir/version/formatstaging/latest | 1 + .../bundleadd/fix-missing-file/lines-checked | 2 +- .../bundleadd/verify-fix-path/lines-checked | 2 +- .../lines-checked | 4 +- .../verify-fix-path-missing-dir/lines-checked | 2 +- 28 files changed, 197 insertions(+), 14 deletions(-) create mode 100644 test/functional/bundleadd/bad-hash-state/lines-checked create mode 100644 test/functional/bundleadd/bad-hash-state/target-dir/testfile create mode 100644 test/functional/bundleadd/bad-hash-state/target-dir/usr/lib/os-release create mode 100644 test/functional/bundleadd/bad-hash-state/target-dir/usr/share/clear/bundles/os-core create mode 100755 test/functional/bundleadd/bad-hash-state/test.bats create mode 100644 test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.MoM create mode 100644 test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.os-core create mode 100644 test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.test-bundle create mode 100644 test/functional/bundleadd/bad-hash-state/web-dir/10/files/ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5 create mode 100644 test/functional/bundleadd/bad-hash-state/web-dir/10/staged/ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5 create mode 100644 test/functional/bundleadd/bad-hash-state/web-dir/version/formatstaging/latest create mode 100644 test/functional/bundleadd/bad-hash/lines-checked create mode 100644 test/functional/bundleadd/bad-hash/target-dir/usr/lib/os-release create mode 100644 test/functional/bundleadd/bad-hash/target-dir/usr/share/clear/bundles/os-core create mode 100755 test/functional/bundleadd/bad-hash/test.bats create mode 100644 test/functional/bundleadd/bad-hash/web-dir/10/Manifest.MoM create mode 100644 test/functional/bundleadd/bad-hash/web-dir/10/Manifest.os-core create mode 100644 test/functional/bundleadd/bad-hash/web-dir/10/Manifest.test-bundle create mode 100644 test/functional/bundleadd/bad-hash/web-dir/10/files/e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3 create mode 100644 test/functional/bundleadd/bad-hash/web-dir/10/staged/e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3 create mode 100644 test/functional/bundleadd/bad-hash/web-dir/version/formatstaging/latest diff --git a/Makefile.am b/Makefile.am index 2568425f9..7ca6a29f0 100644 --- a/Makefile.am +++ b/Makefile.am @@ -124,6 +124,8 @@ BATS = \ test/functional/bundleadd/add-existing/test.bats \ test/functional/bundleadd/add-multiple/test.bats \ test/functional/bundleadd/add-rc/test.bats \ + test/functional/bundleadd/bad-hash/test.bats \ + test/functional/bundleadd/bad-hash-state/test.bats \ test/functional/bundleadd/boot-file/test.bats \ test/functional/bundleadd/boot-skip/test.bats \ test/functional/bundleadd/include/test.bats \ diff --git a/src/bundle.c b/src/bundle.c index 391f4a467..f5db17429 100644 --- a/src/bundle.c +++ b/src/bundle.c @@ -730,32 +730,36 @@ static int install_bundles(struct list *bundles, struct list **subs, int current * Do not install any files to the system until the hash has been * verified. The verify_fix_path also verifies the hashes. */ char *hashpath; - char *fullpath; // for the error messages iter = list_head(to_install_files); while (iter) { file = iter->data; iter = iter->next; string_or_die(&hashpath, "%s/staged/%s", state_dir, file->hash); - string_or_die(&fullpath, "%s%s", path_prefix, file->filename); if (access(hashpath, F_OK) < 0) { /* fallback to verify_fix_path below, which will check the hash * itself */ free_string(&hashpath); - free_string(&fullpath); continue; } ret = verify_file(file, hashpath); if (!ret) { - fprintf(stderr, "Error: hash check failed for %s\n", fullpath); + fprintf(stderr, "Warning: hash check failed for %s\n", file->filename); + fprintf(stderr, " will attempt to download fullfile for %s\n", file->filename); + ret = swupd_rm(hashpath); + if (ret) { + fprintf(stderr, "Error: could not remove bad file %s\n", hashpath); + ret = EBUNDLE_INSTALL; + free_string(&hashpath); + goto out; + } + // successfully removed, continue and check the next file free_string(&hashpath); - free_string(&fullpath); - goto out; + continue; } free_string(&hashpath); - free_string(&fullpath); } iter = list_head(to_install_files); diff --git a/src/helpers.c b/src/helpers.c index 76015a8ce..5416462f3 100644 --- a/src/helpers.c +++ b/src/helpers.c @@ -808,9 +808,9 @@ int verify_fix_path(char *targetpath, struct manifest *target_MoM) if (verify_file(file, target)) { continue; } - fprintf(stderr, "Hash did not match for path : %s\n", path); + fprintf(stderr, "Hash did not match for path : %s ... fixing\n", path); } else if (ret == -1 && errno == ENOENT) { - fprintf(stderr, "Path %s is missing on the file system\n", path); + fprintf(stderr, "Path %s is missing on the file system ... fixing\n", path); } else { goto end; } diff --git a/test/functional/bundleadd/bad-hash-state/lines-checked b/test/functional/bundleadd/bad-hash-state/lines-checked new file mode 100644 index 000000000..04accfffe --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/lines-checked @@ -0,0 +1,5 @@ +Installing bundle(s) files... +Warning: hash check failed for /testfile + will attempt to download fullfile for /testfile +Path /testfile is missing on the file system ... fixing +Bundle(s) installation done. diff --git a/test/functional/bundleadd/bad-hash-state/target-dir/testfile b/test/functional/bundleadd/bad-hash-state/target-dir/testfile new file mode 100644 index 000000000..16b14f5da --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/target-dir/testfile @@ -0,0 +1 @@ +test file diff --git a/test/functional/bundleadd/bad-hash-state/target-dir/usr/lib/os-release b/test/functional/bundleadd/bad-hash-state/target-dir/usr/lib/os-release new file mode 100644 index 000000000..d20f38730 --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/target-dir/usr/lib/os-release @@ -0,0 +1,9 @@ +NAME="Clear Linux Software for Intel Architecture" +VERSION=1 +ID=clear-linux-os +VERSION_ID=10 +PRETTY_NAME="Clear Linux Software for Intel Architecture" +ANSI_COLOR="1;35" +HOME_URL="https://clearlinux.org" +SUPPORT_URL="https://clearlinux.org" +BUG_REPORT_URL="https://bugs.clearlinux.org/jira" diff --git a/test/functional/bundleadd/bad-hash-state/target-dir/usr/share/clear/bundles/os-core b/test/functional/bundleadd/bad-hash-state/target-dir/usr/share/clear/bundles/os-core new file mode 100644 index 000000000..e69de29bb diff --git a/test/functional/bundleadd/bad-hash-state/test.bats b/test/functional/bundleadd/bad-hash-state/test.bats new file mode 100755 index 000000000..5215e47fd --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/test.bats @@ -0,0 +1,44 @@ +#!/usr/bin/env bats + +load "../../swupdlib" + +f_hash="ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5" + +setup() { + # set up state directory with bad hash file and pack hint + clean_test_dir + sudo mkdir -p $DIR/state/staged + sudo rm -f "$DIR/state/staged/$f_hash" + sudo sh -c "echo \"test file MODIFIED\" > $DIR/state/staged/$f_hash" + sudo touch $DIR/state/pack-test-bundle-from-0-to-10.tar + chown_root -R $DIR/state + sudo chmod -R 0700 $DIR/state + + # set up web dir + create_manifest_tar 10 MoM + sign_manifest_mom 10 + create_manifest_tar 10 os-core + create_manifest_tar 10 test-bundle + create_fullfile_tar 10 $f_hash + tar -C $DIR/web-dir/10 -cf $DIR/web-dir/10/pack-test-bundle-from-0.tar staged/$f_hash + + # clean up test dir + sudo rm -f "$DIR/target-dir/testfile" +} + +teardown() { + clean_tars 10 +} + +@test "bundle-add add bundle with bad hash in state dir" { + # sanity check, the test is invalid if this exists now + [ ! -f "$DIR/target-dir/testfile" ] + run sudo sh -c "$SWUPD bundle-add $SWUPD_OPTS test-bundle" + + check_lines "$output" + [ "$status" -eq 0 ] + # the corrected file should exist on the filesystem now + [ -f "$DIR/target-dir/testfile" ] +} + +# vi: ft=sh ts=8 sw=2 sts=2 et tw=80 diff --git a/test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.MoM b/test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.MoM new file mode 100644 index 000000000..b6a9ef2c4 --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.MoM @@ -0,0 +1,9 @@ +MANIFEST 3 +version: 10 +previous: 0 +filecount: 1 +timestamp: 1451940175 +contentsize: 13805671819 + +M... 0f026bc0017b676ad1eed7db682408007171cc1c148c39c069f91d740be784d7 10 os-core +M... f88a494e5c91a07758ef75910ba6cadb166082e3f0ed68a656eefec06c9503eb 10 test-bundle diff --git a/test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.os-core b/test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.os-core new file mode 100644 index 000000000..8184dc11b --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.os-core @@ -0,0 +1,14 @@ +MANIFEST 3 +version: 10 +previous: 0 +filecount: 7 +timestamp: 1451936779 +contentsize: 17929151 + +D... cde33514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr +D... dde33514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/lib +D... ede33514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/lib/kernel +D... cde13514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/share +D... cde23514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/share/clear +D... cde43514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/share/clear/bundles +F... b85f1dc2c2317a20f47a36d3257313b131124ffa6d4f19bb060d43014fd386b0 10 /usr/share/clear/bundles/os-core diff --git a/test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.test-bundle b/test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.test-bundle new file mode 100644 index 000000000..92f42c8f8 --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/web-dir/10/Manifest.test-bundle @@ -0,0 +1,8 @@ +MANIFEST 3 +version: 10 +previous: 0 +filecount: 1 +timestamp: 1451936779 +contentsize: 17929151 + +F... ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5 10 /testfile diff --git a/test/functional/bundleadd/bad-hash-state/web-dir/10/files/ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5 b/test/functional/bundleadd/bad-hash-state/web-dir/10/files/ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5 new file mode 100644 index 000000000..16b14f5da --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/web-dir/10/files/ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5 @@ -0,0 +1 @@ +test file diff --git a/test/functional/bundleadd/bad-hash-state/web-dir/10/staged/ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5 b/test/functional/bundleadd/bad-hash-state/web-dir/10/staged/ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5 new file mode 100644 index 000000000..16b14f5da --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/web-dir/10/staged/ffbe308091534f3b47b876b241166c4c6d0665204977274093f74851380d49b5 @@ -0,0 +1 @@ +test file diff --git a/test/functional/bundleadd/bad-hash-state/web-dir/version/formatstaging/latest b/test/functional/bundleadd/bad-hash-state/web-dir/version/formatstaging/latest new file mode 100644 index 000000000..f599e28b8 --- /dev/null +++ b/test/functional/bundleadd/bad-hash-state/web-dir/version/formatstaging/latest @@ -0,0 +1 @@ +10 diff --git a/test/functional/bundleadd/bad-hash/lines-checked b/test/functional/bundleadd/bad-hash/lines-checked new file mode 100644 index 000000000..af0982e10 --- /dev/null +++ b/test/functional/bundleadd/bad-hash/lines-checked @@ -0,0 +1,6 @@ +Extracting test-bundle pack for version 10 +Installing bundle(s) files... +Warning: hash check failed for /testfile + will attempt to download fullfile for /testfile +Path /testfile is missing on the file system ... fixing +REGEXP:File content hash mismatch for .* diff --git a/test/functional/bundleadd/bad-hash/target-dir/usr/lib/os-release b/test/functional/bundleadd/bad-hash/target-dir/usr/lib/os-release new file mode 100644 index 000000000..d20f38730 --- /dev/null +++ b/test/functional/bundleadd/bad-hash/target-dir/usr/lib/os-release @@ -0,0 +1,9 @@ +NAME="Clear Linux Software for Intel Architecture" +VERSION=1 +ID=clear-linux-os +VERSION_ID=10 +PRETTY_NAME="Clear Linux Software for Intel Architecture" +ANSI_COLOR="1;35" +HOME_URL="https://clearlinux.org" +SUPPORT_URL="https://clearlinux.org" +BUG_REPORT_URL="https://bugs.clearlinux.org/jira" diff --git a/test/functional/bundleadd/bad-hash/target-dir/usr/share/clear/bundles/os-core b/test/functional/bundleadd/bad-hash/target-dir/usr/share/clear/bundles/os-core new file mode 100644 index 000000000..e69de29bb diff --git a/test/functional/bundleadd/bad-hash/test.bats b/test/functional/bundleadd/bad-hash/test.bats new file mode 100755 index 000000000..0025a1ab7 --- /dev/null +++ b/test/functional/bundleadd/bad-hash/test.bats @@ -0,0 +1,35 @@ +#!/usr/bin/env bats + +load "../../swupdlib" + +# expected hash listed in manifest, but not acutal hash of file +# also file name in staged directory +f_hash="e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3" + +setup() { + clean_test_dir + create_manifest_tar 10 MoM + sign_manifest_mom 10 + create_manifest_tar 10 os-core + create_manifest_tar 10 test-bundle + create_fullfile_tar 10 $f_hash + chown_root "$DIR/web-dir/10/staged/$f_hash" + tar -C "$DIR/web-dir/10" -cf "$DIR/web-dir/10/pack-test-bundle-from-0.tar" staged/$f_hash +} + +teardown() { + clean_tars 10 + revert_chown_root "$DIR/web-dir/10/staged/$f_hash" +} + +@test "bundle-add add bundle containing file with different hash from what is listed in manifest" { + run sudo sh -c "$SWUPD bundle-add $SWUPD_OPTS test-bundle" + + # downloaded fullfile had a bad hash - immediately fatal with a 1 return code + [ "$status" -eq 1 ] + check_lines "$output" + # the bad hash file should not exist on the system + [ ! -f "$DIR/target-dir/testfile" ] +} + +# vi: ft=sh ts=8 sw=2 sts=2 et tw=80 diff --git a/test/functional/bundleadd/bad-hash/web-dir/10/Manifest.MoM b/test/functional/bundleadd/bad-hash/web-dir/10/Manifest.MoM new file mode 100644 index 000000000..3824dea81 --- /dev/null +++ b/test/functional/bundleadd/bad-hash/web-dir/10/Manifest.MoM @@ -0,0 +1,9 @@ +MANIFEST 3 +version: 10 +previous: 0 +filecount: 1 +timestamp: 1451940175 +contentsize: 13805671819 + +M... 0f026bc0017b676ad1eed7db682408007171cc1c148c39c069f91d740be784d7 10 os-core +M... bacb42d324b642f45ae4323c462e29acb4344987f430b9b55f70e96443f967c9 10 test-bundle diff --git a/test/functional/bundleadd/bad-hash/web-dir/10/Manifest.os-core b/test/functional/bundleadd/bad-hash/web-dir/10/Manifest.os-core new file mode 100644 index 000000000..8184dc11b --- /dev/null +++ b/test/functional/bundleadd/bad-hash/web-dir/10/Manifest.os-core @@ -0,0 +1,14 @@ +MANIFEST 3 +version: 10 +previous: 0 +filecount: 7 +timestamp: 1451936779 +contentsize: 17929151 + +D... cde33514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr +D... dde33514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/lib +D... ede33514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/lib/kernel +D... cde13514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/share +D... cde23514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/share/clear +D... cde43514c151abb2b01448be290ab1d5212952571d15e3533cadc15ff82f2cd5 10 /usr/share/clear/bundles +F... b85f1dc2c2317a20f47a36d3257313b131124ffa6d4f19bb060d43014fd386b0 10 /usr/share/clear/bundles/os-core diff --git a/test/functional/bundleadd/bad-hash/web-dir/10/Manifest.test-bundle b/test/functional/bundleadd/bad-hash/web-dir/10/Manifest.test-bundle new file mode 100644 index 000000000..29d3188ae --- /dev/null +++ b/test/functional/bundleadd/bad-hash/web-dir/10/Manifest.test-bundle @@ -0,0 +1,8 @@ +MANIFEST 3 +version: 10 +previous: 0 +filecount: 1 +timestamp: 1451936779 +contentsize: 17929151 + +F... e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3 10 /testfile diff --git a/test/functional/bundleadd/bad-hash/web-dir/10/files/e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3 b/test/functional/bundleadd/bad-hash/web-dir/10/files/e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3 new file mode 100644 index 000000000..539f3894a --- /dev/null +++ b/test/functional/bundleadd/bad-hash/web-dir/10/files/e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3 @@ -0,0 +1 @@ +test file MODIFIED1 diff --git a/test/functional/bundleadd/bad-hash/web-dir/10/staged/e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3 b/test/functional/bundleadd/bad-hash/web-dir/10/staged/e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3 new file mode 100644 index 000000000..539f3894a --- /dev/null +++ b/test/functional/bundleadd/bad-hash/web-dir/10/staged/e6d85023c5e619eb43d5cfbfdbdec784afef5a82ffa54e8c93bda3e0883360a3 @@ -0,0 +1 @@ +test file MODIFIED1 diff --git a/test/functional/bundleadd/bad-hash/web-dir/version/formatstaging/latest b/test/functional/bundleadd/bad-hash/web-dir/version/formatstaging/latest new file mode 100644 index 000000000..f599e28b8 --- /dev/null +++ b/test/functional/bundleadd/bad-hash/web-dir/version/formatstaging/latest @@ -0,0 +1 @@ +10 diff --git a/test/functional/bundleadd/fix-missing-file/lines-checked b/test/functional/bundleadd/fix-missing-file/lines-checked index 32c86e8bc..e94ba4901 100644 --- a/test/functional/bundleadd/fix-missing-file/lines-checked +++ b/test/functional/bundleadd/fix-missing-file/lines-checked @@ -6,6 +6,6 @@ Downloading packs Retry #3 downloading subscribed packs Downloading packs Installing bundle(s) files -Path /foo is missing on the file system +Path /foo is missing on the file system fixing Calling post-update helper scripts Bundle(s) installation done diff --git a/test/functional/bundleadd/verify-fix-path/lines-checked b/test/functional/bundleadd/verify-fix-path/lines-checked index 88a1ffb3d..9a862d06e 100644 --- a/test/functional/bundleadd/verify-fix-path/lines-checked +++ b/test/functional/bundleadd/verify-fix-path/lines-checked @@ -1,5 +1,5 @@ Extracting test-bundle pack for version 10 Installing bundle(s) files... REGEXP:Update target directory does not exist: .*/usr/bin. Trying to fix it -Path /usr/bin is missing on the file system +Path /usr/bin is missing on the file system ... fixing Bundle(s) installation done. diff --git a/test/functional/update/verify-fix-path-hash-mismatch/lines-checked b/test/functional/update/verify-fix-path-hash-mismatch/lines-checked index 5610826c8..df4e304c9 100644 --- a/test/functional/update/verify-fix-path-hash-mismatch/lines-checked +++ b/test/functional/update/verify-fix-path-hash-mismatch/lines-checked @@ -13,8 +13,8 @@ File /usr/bin/foo was not in a pack Finishing download of update content... Staging file content REGEXP:^Update target directory does not exist: .*/target-dir/usr/bin. Trying to fix it$ -Hash did not match for path : /usr -Path /usr/bin is missing on the file system +Hash did not match for path : /usr ... fixing +Path /usr/bin is missing on the file system ... fixing Applying update Update was applied. Update successful. System updated from version 10 to version 100 diff --git a/test/functional/update/verify-fix-path-missing-dir/lines-checked b/test/functional/update/verify-fix-path-missing-dir/lines-checked index e8aa60787..fe182c179 100644 --- a/test/functional/update/verify-fix-path-missing-dir/lines-checked +++ b/test/functional/update/verify-fix-path-missing-dir/lines-checked @@ -13,7 +13,7 @@ File /usr/bin/foo was not in a pack Finishing download of update content... Staging file content REGEXP:^Update target directory does not exist: .*/target-dir/usr/bin. Trying to fix it$ -Path /usr/bin is missing on the file system +Path /usr/bin is missing on the file system ... fixing Applying update Update was applied. Update successful. System updated from version 10 to version 100