From 86303e655ce8797ce1c88b9f63971b6b70bcc92f Mon Sep 17 00:00:00 2001 From: shanu Date: Fri, 17 Jul 2026 14:16:07 +0530 Subject: [PATCH] fix(deps): revert hmac to 0.12 to repair broken build The dependabot bump to hmac 0.13 (PR #4) requires digest 0.11, but the sha2/sha1 hashes remain on 0.10 (digest 0.10), so Hmac/Hmac no longer satisfy their trait bounds and every call site still uses the 0.12 new_from_slice API. This left main red (CI failure on the current HEAD) and unbuildable at relay/auth.rs, providers/linq.rs, and providers/yuanbao/{sign,cos}.rs. Revert to hmac 0.12 to match the hash stack the code targets and prune the orphaned 0.13 entry from the lockfile. Moving the whole SHA stack to digest 0.11 is left as a separate coordinated bump. --- Cargo.lock | 51 +++++++++++---------------------------------------- Cargo.toml | 2 +- 2 files changed, 12 insertions(+), 41 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 7321635..9c5580d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -284,15 +284,6 @@ dependencies = [ "generic-array", ] -[[package]] -name = "block-buffer" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2f6c7dbe95a6ed67ad9f18e57daf93a2f034c524b99fd2b76d18fdfeb6660aa" -dependencies = [ - "hybrid-array", -] - [[package]] name = "block-padding" version = "0.3.3" @@ -551,7 +542,7 @@ dependencies = [ "cfg-if", "cpufeatures 0.2.17", "curve25519-dalek-derive", - "digest 0.10.7", + "digest", "fiat-crypto", "rustc_version", "subtle", @@ -626,22 +617,11 @@ version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ - "block-buffer 0.10.4", + "block-buffer", "crypto-common 0.1.7", "subtle", ] -[[package]] -name = "digest" -version = "0.11.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1dd6dbb5841937940781866fa1281a1ff7bd3bf827091440879f9994983d5c2" -dependencies = [ - "block-buffer 0.12.1", - "crypto-common 0.2.2", - "ctutils", -] - [[package]] name = "directories" version = "6.0.0" @@ -1107,7 +1087,7 @@ version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7b5f8eb2ad728638ea2c7d47a21db23b7b58a72ed6a38256b8a1849f15fbbdf7" dependencies = [ - "hmac 0.12.1", + "hmac", ] [[package]] @@ -1116,16 +1096,7 @@ version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "hmac" -version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6303bc9732ae41b04cb554b844a762b4115a61bfaa81e3e83050991eeb56863f" -dependencies = [ - "digest 0.11.3", + "digest", ] [[package]] @@ -1708,8 +1679,8 @@ version = "0.12.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" dependencies = [ - "digest 0.10.7", - "hmac 0.12.1", + "digest", + "hmac", ] [[package]] @@ -2428,7 +2399,7 @@ checksum = "e3bf829a2d51ab4a5ddf1352d8470c140cadc8301b2ae1789db023f01cedd6ba" dependencies = [ "cfg-if", "cpufeatures 0.2.17", - "digest 0.10.7", + "digest", ] [[package]] @@ -2439,7 +2410,7 @@ checksum = "a7507d819769d01a365ab707794a4084392c824f54a7a6a7862f8c3d0892b283" dependencies = [ "cfg-if", "cpufeatures 0.2.17", - "digest 0.10.7", + "digest", ] [[package]] @@ -2662,7 +2633,7 @@ dependencies = [ "futures", "futures-util", "hex", - "hmac 0.13.0", + "hmac", "lettre", "mail-parser", "parking_lot", @@ -3116,7 +3087,7 @@ dependencies = [ "futures", "hex", "hkdf", - "hmac 0.12.1", + "hmac", "log", "md5", "once_cell", @@ -3203,7 +3174,7 @@ dependencies = [ "ghash 0.6.0", "hex", "hkdf", - "hmac 0.12.1", + "hmac", "log", "prost", "rand 0.10.2", diff --git a/Cargo.toml b/Cargo.toml index 097cea7..71870c2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -35,7 +35,7 @@ directories = "6" futures = "0.3" futures-util = { version = "0.3", default-features = false, features = ["sink", "std"] } hex = "0.4" -hmac = "0.13" +hmac = "0.12" parking_lot = "0.12" prost = "0.14" rand = "0.10"