38286 [SC-Low] bitcoinutils getdustlimitforoutput calculate wrongly the dust limit for a given bitco
#38286 [SC-Low] BitcoinUtils.getDustLimitForOutput calculate wrongly the dust limit for a given Bitcoin script public key
Description
Description
Brief/Intro
function redeem(bytes calldata scriptPubkey, uint256 amount) external {
LBTCStorage storage $ = _getLBTCStorage();
// removed for simplicity
uint64 fee = $.burnCommission;
(
uint256 amountAfterFee,
bool isAboveFee,
uint256 dustLimit,
bool isAboveDust
) = _calcFeeAndDustLimit(scriptPubkey, amount, fee);
if (!isAboveDust) {
revert AmountBelowDustLimit(dustLimit);
}
emit UnstakeRequest(fromAddress, scriptPubkey, amountAfterFee);
}
The vulnerability
Vulnerability Details
Impacts
About the severity assessment
Proof of Concept
Proof of concept
Previous#38225 [SC-Insight] user funds will get stuck if `removeDestination` executes before notarization anNext#38257 [SC-Insight] Freezing of msg.value passed in Bridge.deposit() if adapter is address zero
Last updated
Was this helpful?