Farseen0/scar-pairs huggingface dataset:
MEDIUM severity: Vulnerable function: ```\nfunction testBorrowOverflow() public {\n    uint256 borrowAmount = 1e40;\n    BorrowArg[] memor. ```\nfunction testBorrowOverflow() public {\n    uint256 borrowAmount = 1e40;\n    BorrowArg[] memory borrowArgs = new BorrowArg[](1);\n    (, ,uint256 loanId , ) = kairos.getParameters();\n    loanId += 1;\n\n    Offer memory offer = Offer({\n            assetToLend: money,\n            loanToValue

Vulnerable code:
```\nfunction testBorrowOverflow() public {\n    uint256 borrowAmount = 1e40;\n    BorrowArg[] memory borrowArgs = new BorrowArg[](1);\n    (, ,uint256 loanId , ) = kairos.getParameters();\n    loanId += 1;\n\n    Offer memory offer = Offer({\n            assetToLend: money,\n            loanToValue: 1e61,\n            duration: 1,\n            expirationDate: block.timestamp + 2 hours,\n            tranche: 0,\n            collateral: getNft()\n        });\n    uint256 currentTokenId;\n\n    getFlooz(signer, money, getOfferArg(offer).amount);\n\n    {\n        OfferArg[] memory offerArgs = new OfferArg[](1);\n        currentTokenId = getJpeg(BORROWER, nft);\n        offer.collateral.id = currentTokenId;\n        offerArgs[0] = OfferArg({\n            signature: getSignature(offer),\n            amount: borrowAmount,\n            offer: offer\n        });\n        borrowArgs[0] = BorrowArg({nft: NFToken({id: currentTokenId, implem: nft}), args: offerArgs});\n    }\n\n    vm.prank(BORROWER);\n    kairos.borrow(borrowArgs);\n\n    assertEq(nft.balanceOf(BORROWER), 0);\n    assertEq(money.balanceOf(BORROWER), borrowAmount);\n    assertEq(nft.balanceOf(address(kairos)), 1);\n\n    vm.warp(block.timestamp + 1);\n    Loan memory loan = kairos.getLoan(loanId);\n    console.log("price of loanId", kairos.price(loanId));\n}\n```\n
MEDIUM severity: Vulnerable function: ```\nuint256 timeSinceMigration = finalMigrationTime - lastClaimTime;\n\n// (tim. ```\nuint256 timeSinceMigration = finalMigrationTime - lastClaimTime;\n\n// (timeSinceMigration \* INTERNAL\_TOKEN\_PRECISION \* finalEmissionRatePerYear) / YEAR\nuint256 incentiveRate =\n    timeSinceMigration\n        .mul(uint256(Constants.INTERNAL\_TOKEN\_PRECISION))\n        // Migration emissi

Vulnerable code:
```\nuint256 timeSinceMigration = finalMigrationTime - lastClaimTime;\n\n// (timeSinceMigration \* INTERNAL\_TOKEN\_PRECISION \* finalEmissionRatePerYear) / YEAR\nuint256 incentiveRate =\n    timeSinceMigration\n        .mul(uint256(Constants.INTERNAL\_TOKEN\_PRECISION))\n        // Migration emission rate is stored as is, denominated in whole tokens\n        .mul(finalEmissionRatePerYear).mul(uint256(Constants.INTERNAL\_TOKEN\_PRECISION))\n        .div(Constants.YEAR);\n\n// Returns the average supply using the integral of the total supply.\nuint256 avgTotalSupply = finalTotalIntegralSupply.sub(lastClaimIntegralSupply).div(timeSinceMigration);\n```\n
MEDIUM severity: Vulnerable function: ```\nFile: contracts\WooPPV2.sol\n    function _swapBaseToBase(\n// rest of code\n    ) private nonR. ```\nFile: contracts\WooPPV2.sol\n    function _swapBaseToBase(\n// rest of code\n    ) private nonReentrant whenNotPaused returns (uint256 base2Amount) {\n        require(baseToken1 != address(0) && baseToken1 != quoteToken, "WooPPV2: !baseToken1");\n        require(baseToken2 != address(0) && base

Vulnerable code:
```\nFile: contracts\WooPPV2.sol\n    function _swapBaseToBase(\n// rest of code\n    ) private nonReentrant whenNotPaused returns (uint256 base2Amount) {\n        require(baseToken1 != address(0) && baseToken1 != quoteToken, "WooPPV2: !baseToken1");\n        require(baseToken2 != address(0) && baseToken2 != quoteToken, "WooPPV2: !baseToken2");\n// rest of code\n        IWooracleV2.State memory state1 = IWooracleV2(wooracle).state(baseToken1);\n        IWooracleV2.State memory state2 = IWooracleV2(wooracle).state(baseToken2);\n// rest of code\n            uint256 newBase1Price;\n            (quoteAmount, newBase1Price) = _calcQuoteAmountSellBase(baseToken1, base1Amount, state1);\n            IWooracleV2(wooracle).postPrice(baseToken1, uint128(newBase1Price));\n// rest of code\n            uint256 newBase2Price;\n            (base2Amount, newBase2Price) = _calcBaseAmountSellQuote(baseToken2, quoteAmount, state2);\n            IWooracleV2(wooracle).postPrice(baseToken2, uint128(newBase2Price));\n// rest of code\n    }\n```\n
MEDIUM severity: Vulnerable function: ```\n    function cancel() external onlyPayerOrRecipient {\n        address payer_ = payer();\n     . ```\n    function cancel() external onlyPayerOrRecipient {\n        address payer_ = payer();\n        address recipient_ = recipient();\n        IERC20 token_ = token();\n\n        uint256 recipientBalance = balanceOf(recipient_);\n\n        // This zeroing is important because without it, it's pos

Vulnerable code:
```\n    function cancel() external onlyPayerOrRecipient {\n        address payer_ = payer();\n        address recipient_ = recipient();\n        IERC20 token_ = token();\n\n        uint256 recipientBalance = balanceOf(recipient_);\n\n        // This zeroing is important because without it, it's possible for recipient to obtain additional funds\n        // from this contract if anyone (e.g. payer) sends it tokens after cancellation.\n        // Thanks to this state update, `balanceOf(recipient_)` will only return zero in future calls.\n        remainingBalance = 0;\n\n        if (recipientBalance > 0) token_.safeTransfer(recipient_, recipientBalance);\n```\n
HIGH severity: Vulnerable function: ```\ncontract ZeroDAOToken is\n  OwnableUpgradeable,\n  ERC20Upgradeable,\n  ERC. ```\ncontract ZeroDAOToken is\n  OwnableUpgradeable,\n  ERC20Upgradeable,\n  ERC20PausableUpgradeable,\n  ERC20SnapshotUpgradeable\n{\n```\n

Vulnerable code:
```\ncontract ZeroDAOToken is\n  OwnableUpgradeable,\n  ERC20Upgradeable,\n  ERC20PausableUpgradeable,\n  ERC20SnapshotUpgradeable\n{\n```\n
HIGH severity: Vulnerable function: ```\nfunction totalFunds() public view override returns (uint256, uint256) {\n    return ConvexPosit. ```\nfunction totalFunds() public view override returns (uint256, uint256) {\n    return ConvexPositionHandler.positionInWantToken();\n}\n```\n

Vulnerable code:
```\nfunction totalFunds() public view override returns (uint256, uint256) {\n    return ConvexPositionHandler.positionInWantToken();\n}\n```\n
HIGH severity: Vulnerable function: ```\nfunction _calculateMaxBorrowCollateral(ActionInfo memory _actionInfo, bool _isLever) internal v. ```\nfunction _calculateMaxBorrowCollateral(ActionInfo memory _actionInfo, bool _isLever) internal view returns(uint256) {\n    \n    // Retrieve collateral factor and liquidation threshold for the collateral asset in precise units (1e16 = 1%)\n    ( , uint256 maxLtvRaw, uint256 liquidationThreshold

Vulnerable code:
```\nfunction _calculateMaxBorrowCollateral(ActionInfo memory _actionInfo, bool _isLever) internal view returns(uint256) {\n    \n    // Retrieve collateral factor and liquidation threshold for the collateral asset in precise units (1e16 = 1%)\n    ( , uint256 maxLtvRaw, uint256 liquidationThresholdRaw, , , , , , ,) = strategy.aaveProtocolDataProvider.getReserveConfigurationData(address(strategy.collateralAsset));\n\n    // Normalize LTV and liquidation threshold to precise units. LTV is measured in 4 decimals in Aave which is why we must multiply by 1e14\n    // for example ETH has an LTV value of 8000 which represents 80%\n    if (_isLever) {\n        uint256 netBorrowLimit = _actionInfo.collateralValue\n            .preciseMul(maxLtvRaw.mul(10 ** 14))\n            .preciseMul(PreciseUnitMath.preciseUnit().sub(execution.unutilizedLeveragePercentage));\n\n        return netBorrowLimit\n            .sub(_actionInfo.borrowValue)\n            .preciseDiv(_actionInfo.collateralPrice);\n```\n
MEDIUM severity: Vulnerable function: ```\nuint256 liquidatableAmount = totalPositionSize.sub(totalPositionSize.mod(go. ```\nuint256 liquidatableAmount = totalPositionSize.sub(totalPositionSize.mod(governance.lotSize));\nliquidationAmount = liquidationAmount.ceil(governance.lotSize).min(maxAmount).min(liquidatableAmount);\n```\n

Vulnerable code:
```\nuint256 liquidatableAmount = totalPositionSize.sub(totalPositionSize.mod(governance.lotSize));\nliquidationAmount = liquidationAmount.ceil(governance.lotSize).min(maxAmount).min(liquidatableAmount);\n```\n
MEDIUM severity: Vulnerable function: ```\nfunction getPurchasedAmount(address holder) public returns (uint amount) {\n    // check if any. ```\nfunction getPurchasedAmount(address holder) public returns (uint amount) {\n    // check if any delegation was ended\n    for (uint i = 0; i < \_endingDelegations[holder].length; ++i) {\n        getState(\_endingDelegations[holder][i]);\n    }\n    return \_purchased[holder];\n```\n

Vulnerable code:
```\nfunction getPurchasedAmount(address holder) public returns (uint amount) {\n    // check if any delegation was ended\n    for (uint i = 0; i < \_endingDelegations[holder].length; ++i) {\n        getState(\_endingDelegations[holder][i]);\n    }\n    return \_purchased[holder];\n```\n
MEDIUM severity: Vulnerable function: ```\n(uint80 roundID, int256 price,, uint256 updatedAt, uint80 answeredInRound) . ```\n(uint80 roundID, int256 price,, uint256 updatedAt, uint80 answeredInRound) = priceFeed.latestRoundData();\nrequire(price > 0, "Chainlink: Incorrect Price");\nrequire(block.timestamp - updatedAt < priceSources[token].heartBeat, "Chainlink: Stale Price");\nrequire(answeredInRound >= roundID, "Cha

Vulnerable code:
```\n(uint80 roundID, int256 price,, uint256 updatedAt, uint80 answeredInRound) = priceFeed.latestRoundData();\nrequire(price > 0, "Chainlink: Incorrect Price");\nrequire(block.timestamp - updatedAt < priceSources[token].heartBeat, "Chainlink: Stale Price");\nrequire(answeredInRound >= roundID, "Chainlink: Stale Price");\n```\n
HIGH severity: Vulnerable function: ```\nfunction acceptBid(bytes memory signature, uint256 rand, address bidder, uint256 bid, address n. ```\nfunction acceptBid(bytes memory signature, uint256 rand, address bidder, uint256 bid, address nftaddress, uint256 tokenid) external {\n    address recoveredbidder = recover(toEthSignedMessageHash(keccak256(abi.encode(rand, address(this), block.chainid, bid, nftaddress, tokenid))), signature);\n

Vulnerable code:
```\nfunction acceptBid(bytes memory signature, uint256 rand, address bidder, uint256 bid, address nftaddress, uint256 tokenid) external {\n    address recoveredbidder = recover(toEthSignedMessageHash(keccak256(abi.encode(rand, address(this), block.chainid, bid, nftaddress, tokenid))), signature);\n    require(bidder == recoveredbidder, 'zAuction: incorrect bidder');\n    require(!randUsed[rand], 'Random nonce already used');\n    randUsed[rand] = true;\n    IERC721 nftcontract = IERC721(nftaddress);\n    accountant.Exchange(bidder, msg.sender, bid);\n    nftcontract.transferFrom(msg.sender, bidder, tokenid);\n    emit BidAccepted(bidder, msg.sender, bid, nftaddress, tokenid);\n}\n```\n
MEDIUM severity: Vulnerable function: ```\nTRANSFER_PROXY.tokenTransferFrom(WETH, payer, payee, paymentAmount);\n```\n. ```\nTRANSFER_PROXY.tokenTransferFrom(WETH, payer, payee, paymentAmount);\n```\n

Vulnerable code:
```\nTRANSFER_PROXY.tokenTransferFrom(WETH, payer, payee, paymentAmount);\n```\n
HIGH severity: Vulnerable function: ```\n  mapping(address => address) public nativeToBridgedToken;\n  mapping(addre. ```\n  mapping(address => address) public nativeToBridgedToken;\n  mapping(address => address) public bridgedToNativeToken;\n```\n

Vulnerable code:
```\n  mapping(address => address) public nativeToBridgedToken;\n  mapping(address => address) public bridgedToNativeToken;\n```\n
MEDIUM severity: Vulnerable function: ```\nFile: ProtectionPool.sol\n\n   /// step 1: Capture protection pool's curren. ```\nFile: ProtectionPool.sol\n\n   /// step 1: Capture protection pool's current investors by creating a snapshot of the token balance by using ERC20Snapshot in SToken\n   _snapshotId = _snapshot();\n```\n

Vulnerable code:
```\nFile: ProtectionPool.sol\n\n   /// step 1: Capture protection pool's current investors by creating a snapshot of the token balance by using ERC20Snapshot in SToken\n   _snapshotId = _snapshot();\n```\n
MEDIUM severity: Vulnerable function: ```\nif (operatorFee > 0) {\n (status, data) = operator.call{value: operatorFee}. ```\nif (operatorFee > 0) {\n (status, data) = operator.call{value: operatorFee}("");\n if (status == false) {\n revert FeeRecipientReceiveError(data);\n }\n}\n```\n

Vulnerable code:
```\nif (operatorFee > 0) {\n (status, data) = operator.call{value: operatorFee}("");\n if (status == false) {\n revert FeeRecipientReceiveError(data);\n }\n}\n```\n
MEDIUM severity: Vulnerable function: ```\n    function getReservedUsd(\n        DataStore dataStore,\n        Market.Props memory market,. ```\n    function getReservedUsd(\n        DataStore dataStore,\n        Market.Props memory market,\n        MarketPrices memory prices,\n        bool isLong\n    ) internal view returns (uint256) {\n        uint256 reservedUsd;\n        if (isLong) {\n            // for longs calculate the reserve

Vulnerable code:
```\n    function getReservedUsd(\n        DataStore dataStore,\n        Market.Props memory market,\n        MarketPrices memory prices,\n        bool isLong\n    ) internal view returns (uint256) {\n        uint256 reservedUsd;\n        if (isLong) {\n            // for longs calculate the reserved USD based on the open interest and current indexTokenPrice\n            // this works well for e.g. an ETH / USD market with long collateral token as WETH\n            // the available amount to be reserved would scale with the price of ETH\n            // this also works for e.g. a SOL / USD market with long collateral token as WETH\n            // if the price of SOL increases more than the price of ETH, additional amounts would be\n            // automatically reserved\n            uint256 openInterestInTokens = getOpenInterestInTokens(dataStore, market, isLong);\n            reservedUsd = openInterestInTokens * prices.indexTokenPrice.max;\n        } else {\n            // for shorts use the open interest as the reserved USD value\n            // this works well for e.g. an ETH / USD market with short collateral token as USDC\n            // the available amount to be reserved would not change with the price of ETH\n            reservedUsd = getOpenInterest(dataStore, market, isLong);\n        }\n\n        return reservedUsd;\n    }\n```\n
HIGH severity: Vulnerable function: ```\n        if (block.number <= lastRepay + overdueBlocks + maxOverdueBlocks) {. ```\n        if (block.number <= lastRepay + overdueBlocks + maxOverdueBlocks) {\n            if (staker != msg.sender) revert AuthFailed();\n        }\n```\n

Vulnerable code:
```\n        if (block.number <= lastRepay + overdueBlocks + maxOverdueBlocks) {\n            if (staker != msg.sender) revert AuthFailed();\n        }\n```\n
MEDIUM severity: Vulnerable function: ```\nfunction getOraclePrice(IAggregatorV3 _priceFeed, int192 _maxPrice, int192 _minPrice) public vi. ```\nfunction getOraclePrice(IAggregatorV3 _priceFeed, int192 _maxPrice, int192 _minPrice) public view returns (uint256 ) {\n    (\n        /*uint80 roundID*/,\n        int signedPrice,\n        /*uint startedAt*/,\n        uint timeStamp,\n        /*uint80 answeredInRound*/\n    ) = _priceFeed.late

Vulnerable code:
```\nfunction getOraclePrice(IAggregatorV3 _priceFeed, int192 _maxPrice, int192 _minPrice) public view returns (uint256 ) {\n    (\n        /*uint80 roundID*/,\n        int signedPrice,\n        /*uint startedAt*/,\n        uint timeStamp,\n        /*uint80 answeredInRound*/\n    ) = _priceFeed.latestRoundData();\n    //check for Chainlink oracle deviancies, force a revert if any are present. Helps prevent a LUNA like issue\n    require(signedPrice > 0, "Negative Oracle Price");\n    require(timeStamp >= block.timestamp - HEARTBEAT_TIME , "Stale pricefeed");\n\n    //@audit revert if price is outside of immutable bounds\n    require(signedPrice < _maxPrice, "Upper price bound breached");\n    require(signedPrice > _minPrice, "Lower price bound breached");\n    uint256 price = uint256(signedPrice);\n    return price;\n}\n```\n
MEDIUM severity: Vulnerable function: ```\nfunction liquidation(address provider, address onBehalfOf, uint256 assetAmount) external virtua. ```\nfunction liquidation(address provider, address onBehalfOf, uint256 assetAmount) external virtual {\n uint256 assetPrice = getAssetPrice();\n uint256 onBehalfOfCollateralRatio = (depositedAsset[onBehalfOf] \* assetPrice \* 100) / borrowed[onBehalfOf];\n require(onBehalfOfCollateralRatio < badCol

Vulnerable code:
```\nfunction liquidation(address provider, address onBehalfOf, uint256 assetAmount) external virtual {\n uint256 assetPrice = getAssetPrice();\n uint256 onBehalfOfCollateralRatio = (depositedAsset[onBehalfOf] \* assetPrice \* 100) / borrowed[onBehalfOf];\n require(onBehalfOfCollateralRatio < badCollateralRatio, "Borrowers collateral ratio should below badCollateralRatio");\n\n require(assetAmount \* 2 <= depositedAsset[onBehalfOf], "a max of 50% collateral can be liquidated");\n require(EUSD.allowance(provider, address(this)) != 0, "provider should authorize to provide liquidation EUSD");\n uint256 eusdAmount = (assetAmount \* assetPrice) / 1e18;\n\n \_repay(provider, onBehalfOf, eusdAmount);\n uint256 reducedAsset = assetAmount \* 11 / 10;\n totalDepositedAsset -= reducedAsset;\n depositedAsset[onBehalfOf] -= reducedAsset;\n uint256 reward2keeper;\n if (provider == msg.sender) {\n collateralAsset.safeTransfer(msg.sender, reducedAsset);\n } else {\n reward2keeper = (reducedAsset \* configurator.vaultKeeperRatio(address(this))) / 110;\n collateralAsset.safeTransfer(provider, reducedAsset - reward2keeper);\n collateralAsset.safeTransfer(msg.sender, reward2keeper);\n }\n emit LiquidationRecord(provider, msg.sender, onBehalfOf, eusdAmount, reducedAsset, reward2keeper, false, block.timestamp);\n}\n```\n
MEDIUM severity: Vulnerable function: ```\nFile: BondBaseCallback.sol\n    /* ========== WHITELISTING ========== */\n\n    /// @inheritdoc. ```\nFile: BondBaseCallback.sol\n    /* ========== WHITELISTING ========== */\n\n    /// @inheritdoc IBondCallback\n    function whitelist(address teller_, uint256 id_) external override onlyOwner {\n        // Check that the market id is a valid, live market on the aggregator\n        try _aggregat

Vulnerable code:
```\nFile: BondBaseCallback.sol\n    /* ========== WHITELISTING ========== */\n\n    /// @inheritdoc IBondCallback\n    function whitelist(address teller_, uint256 id_) external override onlyOwner {\n        // Check that the market id is a valid, live market on the aggregator\n        try _aggregator.isLive(id_) returns (bool live) {\n            if (!live) revert Callback_MarketNotSupported(id_);\n        } catch {\n            revert Callback_MarketNotSupported(id_);\n        }\n\n        // Check that the provided teller is the teller for the market ID on the stored aggregator\n        // We could pull the teller from the aggregator, but requiring the teller to be passed in\n        // is more explicit about which contract is being whitelisted\n        if (teller_ != address(_aggregator.getTeller(id_))) revert Callback_TellerMismatch();\n\n        approvedMarkets[teller_][id_] = true;\n    }\n```\n
HIGH severity: Vulnerable function: ```\n    function mintViaUnderlying(\n        uint256 depositAmountExternal,\n        uint88 fCashAm. ```\n    function mintViaUnderlying(\n        uint256 depositAmountExternal,\n        uint88 fCashAmount,\n        address receiver,\n        uint32 minImpliedRate//@audit when lendAmount bigger than maxFCash lack of minRate protect.\n    ) external override {\n        (/* */, uint256 maxFCash) = ge

Vulnerable code:
```\n    function mintViaUnderlying(\n        uint256 depositAmountExternal,\n        uint88 fCashAmount,\n        address receiver,\n        uint32 minImpliedRate//@audit when lendAmount bigger than maxFCash lack of minRate protect.\n    ) external override {\n        (/* */, uint256 maxFCash) = getTotalFCashAvailable();\n        _mintInternal(depositAmountExternal, fCashAmount, receiver, minImpliedRate, maxFCash);\n    }\n```\n
MEDIUM severity: Vulnerable function: ```\nFile: FraxEtherRedemptionQueue.sol\n    /// @notice Sets the fee for redeeming\n    /// @param . ```\nFile: FraxEtherRedemptionQueue.sol\n    /// @notice Sets the fee for redeeming\n    /// @param _newFee New redemption fee given in percentage terms, using 1e6 precision\n    function setRedemptionFee(uint64 _newFee) external {\n        _requireSenderIsTimelock();\n        if (_newFee > FEE_PREC

Vulnerable code:
```\nFile: FraxEtherRedemptionQueue.sol\n    /// @notice Sets the fee for redeeming\n    /// @param _newFee New redemption fee given in percentage terms, using 1e6 precision\n    function setRedemptionFee(uint64 _newFee) external {\n        _requireSenderIsTimelock();\n        if (_newFee > FEE_PRECISION) revert ExceedsMaxRedemptionFee(_newFee, FEE_PRECISION);\n\n        emit SetRedemptionFee({ oldRedemptionFee: redemptionQueueState.redemptionFee, newRedemptionFee: _newFee });\n\n        redemptionQueueState.redemptionFee = _newFee;\n    }\n```\n
MEDIUM severity: Vulnerable function: ```\ntry IERC721(order.collection).safeTransferFrom(bear, bull, tokenId) {}\ncat. ```\ntry IERC721(order.collection).safeTransferFrom(bear, bull, tokenId) {}\ncatch (bytes memory) {\n    // Transfer NFT to BvbProtocol\n    IERC721(order.collection).safeTransferFrom(bear, address(this), tokenId);\n    // Store that the bull has to retrieve it\n    withdrawableCollectionTokenId[ord

Vulnerable code:
```\ntry IERC721(order.collection).safeTransferFrom(bear, bull, tokenId) {}\ncatch (bytes memory) {\n    // Transfer NFT to BvbProtocol\n    IERC721(order.collection).safeTransferFrom(bear, address(this), tokenId);\n    // Store that the bull has to retrieve it\n    withdrawableCollectionTokenId[order.collection][tokenId] = bull;\n}\n\nuint bearAssetAmount = order.premium + order.collateral;\nif (bearAssetAmount > 0) {\n    // Transfer payment tokens to the Bear\n    IERC20(order.asset).safeTransfer(bear, bearAssetAmount);\n}\n```\n
HIGH severity: Vulnerable function: ```\n        uint256 validSigCount = countValidSignatures(txHash, signatures, si. ```\n        uint256 validSigCount = countValidSignatures(txHash, signatures, signatures.length / 65);\n                // revert if there aren't enough valid signatures\n        if (validSigCount < safe.getThreshold()) {\n                     revert InvalidSigners();\n         }\n```\n

Vulnerable code:
```\n        uint256 validSigCount = countValidSignatures(txHash, signatures, signatures.length / 65);\n                // revert if there aren't enough valid signatures\n        if (validSigCount < safe.getThreshold()) {\n                     revert InvalidSigners();\n         }\n```\n