The vulnerability lies in the frost-core library's share refreshing mechanism, where the min_signers (the threshold number of signers required) was not being properly validated. This allowed for a potential downgrade of the security of a signing group. The analysis of the patch commit 379ef689c733b3d9c80fd409071d4f3af4dafed2 reveals that the fix was to add validation checks in two key functions within the frost-core/src/keys/refresh.rs file.
-
frost_core::keys::refresh::refresh_share: This function is used when refreshing shares using a Trusted Dealer. The patch adds a check to ensure the min_signers from the new share matches the min_signers of the existing key. Without this check, a malicious dealer could issue a new share with a lower threshold.
-
frost_core::keys::refresh::refresh_dkg_shares: This function is used in the final step of a DKG-based refresh. The patch adds a similar check to validate that the min_signers value has not been altered during the DKG process.
These two functions are the points where the maliciously crafted new shares would be processed and applied, making them the core of the vulnerability. An exploit would involve a participant calling one of these functions with inputs derived from a refresh process where the min_signers parameter was manipulated. Therefore, these functions would appear in a runtime profile during exploitation. The other modified files in the commit are primarily wrappers in other crates (frost-ed25519, frost-p256, etc.) that call these vulnerable frost-core functions, or are test files to verify the fix.