mirror of
https://github.com/kata-containers/kata-containers.git
synced 2026-03-18 18:58:36 +00:00
Prior to this patch, we were missing a call to `verify_cid` when the cid was derived from the image path, which meant that the host could specify something like "prefix/..", and we would use ".." as the cid. Paths derived from this (e.g., `bundle_path`) would not be at the intended tree. This patch factors the code out of `pull_image` so that it can be more easily tested. Tests are added for a number of cases. Fixes #5421 Signed-off-by: Wedson Almeida Filho <walmeida@microsoft.com>