diff --git a/Cargo.toml b/Cargo.toml index bb7f1bf6bb..e3fb60c379 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -193,7 +193,7 @@ scopeguard = "1.0.0" serde = { version = "1.0.145", features = ["derive"] } serde_json = "1.0.91" serial_test = "0.10.0" -sha2 = "0.10.9" +sha2 = "0.11.0" slog = "2.5.2" slog-scope = "4.4.0" slog-stdlog = "4.0.0" diff --git a/src/agent/Cargo.toml b/src/agent/Cargo.toml index b4c567607b..c4b4be5fd8 100644 --- a/src/agent/Cargo.toml +++ b/src/agent/Cargo.toml @@ -84,7 +84,7 @@ vsock-exporter.workspace = true # Initdata base64 = { workspace = true } -sha2 = "0.10.8" +sha2 = { workspace = true } async-compression = { version = "0.4.22", features = ["tokio", "gzip"] } container-device-interface = "0.1.1" diff --git a/src/libs/kata-types/Cargo.toml b/src/libs/kata-types/Cargo.toml index 4f390d4467..7a4249e777 100644 --- a/src/libs/kata-types/Cargo.toml +++ b/src/libs/kata-types/Cargo.toml @@ -27,7 +27,7 @@ thiserror = { workspace = true } toml = { workspace = true } serde-enum-str = "0.5" sysinfo = { workspace = true } -sha2 = "0.10.8" +sha2 = { workspace = true } flate2 = "1.1" nix = { workspace = true } oci-spec = { version = "0.8.1", features = ["runtime"] } diff --git a/src/runtime-rs/crates/shim/src/shim.rs b/src/runtime-rs/crates/shim/src/shim.rs index 788c713383..1af578d497 100644 --- a/src/runtime-rs/crates/shim/src/shim.rs +++ b/src/runtime-rs/crates/shim/src/shim.rs @@ -72,9 +72,13 @@ impl ShimExecutor { // https://github.com/containerd/containerd/blob/v1.6.8/runtime/v2/shim/util_unix.go#L68 to // generate a shim socket path. Ok(PathBuf::from(format!( - "unix://{}/s/{:X}", + "unix://{}/s/{}", SOCKET_ROOT, - hasher.finalize() + hasher + .finalize() + .iter() + .map(|b| format!("{b:02X}")) + .collect::() ))) } }