Streaming Protocol contest - Meta0xNull's results

General Information

Platform: Code4rena

Start Date: 30/11/2021

Pot Size: $100,000 USDC

Total HM: 15

Participants: 36

Period: 7 days

Judge: 0xean

Total Solo HM: 4

Id: 62

League: ETH

Streaming Protocol

Findings Distribution

Researcher Performance

Rank: 7/36

Findings: 3

Award: $4,591.26

🌟 Selected for report: 1

πŸš€ Solo Findings: 0

Findings Information

🌟 Selected for report: toastedsteaksandwich

Also found by: Meta0xNull, Omik, ScopeLift, bitbopper, gzeon, pedroais, wuwe1

Labels

bug
duplicate
3 (High Risk)

Awards

481.7736 USDC - $481.77

External Links

Handle

Meta0xNull

Vulnerability details

Impact

* This is a potentially dangerous function so to ensure trustlessness, *all* balances * that may matter are guaranteed to not change.

There are Pre and Post Token Check for Deposit Token and Reward Token. But there is no check for Incentives Tokens which mean the number of Incentive Tokens May Go Lower after the arbitrary Call.

Proof of Concept

https://github.com/code-423n4/2021-11-streaming/blob/main/Streaming/src/Locke.sol#L728-L749

Tools Used

Manual Review

// external incentives to stream creator mapping (address => uint112) public incentives;

The Incentive Token Address and Amounts was stored in incentives. Thus, Just need to do a loop to compare Amounts in incentives Vs Token Balance in Contract Address at The End of arbitraryCall().

#0 - brockelmore

2021-12-06T16:46:03Z

This one doesnt provide the exploit mechanism like in #107 so I am inclined to not have this be part of that because this isn't actually a helpful issue for identifying or fixing the real issue.

#1 - 0xean

2022-01-16T01:08:18Z

dupe of #199

Findings Information

🌟 Selected for report: cyberboy

Also found by: Meta0xNull

Labels

bug
duplicate
3 (High Risk)
disagree with severity
sponsor confirmed

Awards

3626.1684 USDC - $3,626.17

External Links

Handle

Meta0xNull

Vulnerability details

Impact

  1. Alice want to Transfer Gov to Bob with setPendingGov() and now pendingGov = BobAddress
  2. Bob Accept Gov via acceptGov()
  3. Bob Tell Community He Want the Contract Become Trustless by Remove Governor via function __abdicate() and gov = address(0) now
  4. Later, Bob Call acceptGov() again because pendingGov = BobAddress and Bob Become Gov Again

Proof of Concept

https://github.com/code-423n4/2021-11-streaming/blob/main/Streaming/src/Locke.sol#L26-L30 https://github.com/code-423n4/2021-11-streaming/blob/main/Streaming/src/Locke.sol#L33-L38 https://github.com/code-423n4/2021-11-streaming/blob/main/Streaming/src/Locke.sol#L45-L49

Tools Used

Manual Review

In acceptGov(), Set pendingGov to Zero Address Once Transfer Gov.

address old = gov; gov = pendingGov; pendingGov = address(0);

#0 - brockelmore

2021-12-03T21:48:45Z

If there is a pendingGov you are correct, but since all of those functions are controlled by governance, it is trivial to reset pendingGov to 0 prior to abdicating, but it should be done in a single transaction.

#1 - 0xean

2022-01-15T01:55:21Z

dupe of #132

AuditHub

A portfolio for auditors, a security profile for protocols, a hub for web3 security.

Built bymalatrax Β© 2024

Auditors

Browse

Contests

Browse

Get in touch

ContactTwitter