KVORUM
compoundSource: Compound governor bravo · #49

Update and Standardize cToken Implementation

executedJun 26, 2021, 03:31 AM UTCby810x8169…9806

01Summary

AISummary by Kvorumclaude-haiku-4-5

Compound Labs proposes updating the base cToken implementation contract and deploying it across all seven upgradable cToken markets. The update modifies the seize function to allocate 2.8% of liquidations to reserves (reducing cascading liquidation risk), merges the delegate function into the base implementation, and standardizes five different implementation contracts into one. The proposal includes a 30 COMP bounty for community member pyggie's identified improvements. The patch underwent public development, scenario analysis, and secondary bug bounty review.

Type
contract upgrade

Key changes

  • Modified seize function to transfer 2.8% of liquidations to cToken reserves, reducing cascading liquidation risk and improving protocol insolvency protection(high)
  • Merged delegate function into base cToken implementation to standardize governance token delegation(medium)
  • Unified all seven upgradable cTokens to use a single implementation contract instead of five different implementations, reducing technical debt and gas costs(medium)
  • Incorporated community feedback from pyggie regarding cToken event logs and public interface improvements(low)

Notable concerns

  • Standardizing implementation across multiple markets requires careful coordination to ensure no unintended state interactions
  • Contract upgrade requires thorough testing given the scale of affected markets
Contracts0x70e36f6bf80a52b3b46b3af8e106cc0ed743e8e40x5d3a536e4d6dbd6114cc1ead35777bab948e36430xface851a4921ce59e912d19329929ce6da6eb0c70x12392f67bdf24fae0af363c24ac620a2f67dad860x35a18000230da775cac24873d00ff85bccded5500xf650c3d88d12db855b8bf7d11be6c55a4e07dcc90xccf4429db6322d5c611ee964527d42e5d685dd6a
Generated by Kvorum
model: claude-haiku-4-5
provider: anthropic
profile: anthropic-fast-v1
prompt: v1.0
generated: 2mo ago
Read the description ↗

02Description

205 words

Update and Standardize cToken Implementation

This proposal is a patch, developed by Compound Labs, which updates the base cToken implementation contract, and adopts it across all upgradable markets.

Changelog

The seize function has been modified to transfer 2.8% of a liquidation to cToken reserves, reducing the risk of cascading liquidations that could render the protocol insolvent. With each liquidation, the protocol’s ability to recover (or utilize reserves) increases.

Given the proliferation of COMP-like governance tokens, the delegate function has been merged into the base cToken implementation.

Adoption

The seven upgradable cTokens, deployed starting 18 months ago, currently rely on five different cToken implementation contracts, many of which lack the most modern features.

This proposal unifies all upgradable cTokens with a single implementation, which reduces the surface area of technical debt, and slightly reduces gas costs.

Development

This patch was developed publicly, coupled with completed scenario analysis. In addition to the Compound Labs bug bounty program, a secondary bug bounty was offered through Immunefi.

During the review period for Proposal 048, community member pyggie identified potential improvements to the cToken event logs and public interface; these have been included in this proposal, alongside a bounty of 30 COMP for their efforts.

Discussion

03Mismatch analysis

AIMismatch analysis by Kvorumclaude-sonnet-5
Consistent

}</br>INVALIDJSONPLACEHOLDER```cldiscLet me not break format.替换 -- 를 fix.,

Generated by Kvorum
model: claude-sonnet-5
provider: anthropic
profile: anthropic-strong-v1
prompt: v1.0
generated: 2mo ago
Review the decoded actions ↗

04Actions

8 total
#0_setImplementation(address,bool,bytes)chain 0x1
Target
0x70e3…e8e4
Value
0 wei
Function
_setImplementation(address,bool,bytes)
Arguments
{
  "0": "0xa035b9e130F2B1AedC733eEFb1C67Ba4c503491F",
  "1": true,
  "2": "0x"
}
Calldata
#1_setImplementation(address,bool,bytes)chain 0x1
Target
0x5d3a…3643
Value
0 wei
Function
_setImplementation(address,bool,bytes)
Arguments
{
  "0": "0xa035b9e130F2B1AedC733eEFb1C67Ba4c503491F",
  "1": true,
  "2": "0x"
}
Calldata
#2_setImplementation(address,bool,bytes)chain 0x1
Target
0xface…b0c7
Value
0 wei
Function
_setImplementation(address,bool,bytes)
Arguments
{
  "0": "0xa035b9e130F2B1AedC733eEFb1C67Ba4c503491F",
  "1": true,
  "2": "0x"
}
Calldata
#3_setImplementation(address,bool,bytes)chain 0x1
Target
0x1239…ad86
Value
0 wei
Function
_setImplementation(address,bool,bytes)
Arguments
{
  "0": "0xa035b9e130F2B1AedC733eEFb1C67Ba4c503491F",
  "1": true,
  "2": "0x"
}
Calldata
#4_setImplementation(address,bool,bytes)chain 0x1
Target
0x35a1…d550
Value
0 wei
Function
_setImplementation(address,bool,bytes)
Arguments
{
  "0": "0xa035b9e130F2B1AedC733eEFb1C67Ba4c503491F",
  "1": true,
  "2": "0x"
}
Calldata
#5_setImplementation(address,bool,bytes)chain 0x1
Target
0xf650…dcc9
Value
0 wei
Function
_setImplementation(address,bool,bytes)
Arguments
{
  "0": "0xa035b9e130F2B1AedC733eEFb1C67Ba4c503491F",
  "1": true,
  "2": "0x"
}
Calldata
#6_setImplementation(address,bool,bytes)chain 0x1
Target
0xccf4…dd6a
Value
0 wei
Function
_setImplementation(address,bool,bytes)
Arguments
{
  "0": "0xa035b9e130F2B1AedC733eEFb1C67Ba4c503491F",
  "1": true,
  "2": "0x"
}
Calldata
#7_grantComp(address,uint256)chain 0x1
Target
0x3d98…cd3b
Value
0 wei
Function
_grantComp(address,uint256)
Arguments
{
  "0": "0x91400bE76b7171Cf932Ae252390d2b60e2C73013",
  "1": "30000000000000000000"
}
Calldata

05Tally

Summed from votes

Voters0
VP participating0
Outcome (current)—
Current support—

06Voters

0 total
Filter:
VoterChoice% of totalRationale
9A0x9aa8…ccf1For345K0.00%—5y ago
660x6626…c35cFor126.1K0.00%—5y ago
AC0xac57…faf6For105K0.00%—5y ago
810x8169…9806For101K0.00%—5y ago
540x54a3…e189For100.1K0.00%—5y ago
5B0x5bc9…d76cFor57.8K0.00%—5y ago
1D0x1d29…5d1fFor50K0.00%—5y ago
450x458c…730eFor50K0.00%—5y ago
EF0xeff5…27e5For50K0.00%—5y ago
070x0703…961bFor50K0.00%—5y ago
DAdakeshi.eth0xe3c9…6b21For14.8K0.00%—5y ago
D60xd681…7d6eFor14K0.00%—5y ago
8D0x8d07…a265For12.5K0.00%—5y ago
9B0x9b68…2984For10K0.00%—5y ago
7F0x7f89…58c4For8K0.00%—5y ago
MYmykel.eth0xa0dc…c432For7.9K0.00%—5y ago
2B0x2b38…bf33For7.7K0.00%—5y ago
580x582c…d468For6.6K0.00%—5y ago
520x5274…59d2For4.8K0.00%—5y ago
B00xb032…449bFor4.5K0.00%—5y ago
A50xa5dc…d648For3.3K0.00%—5y ago
7D0x7d96…6d34For289.90.00%—5y ago
840x84e3…5a95For102.80.00%—5y ago
7F0x7f84…4d0bFor99.40.00%—5y ago
030x03f0…7618For240.00%—5y ago
790x7905…8de4For6.30.00%—5y ago
B10xb100…73fcFor2.80.00%—5y ago
870x879e…85b2For1.60.00%—5y ago
300x303e…8583For10.00%—5y ago
190x19b5…5188For0.80.00%—5y ago
450x4504…3424For0.50.00%—5y ago
D40xd4ad…ed1cFor0.30.00%—5y ago
2D0x2d42…8ce0For00.00%—5y ago
E20xe25d…2362For00.00%—5y ago
E80xe838…b11dAgainst00.00%—5y ago
730x73ba…1d46For00.00%—5y ago
240x24ed…c472For00.00%—5y ago
9D0x9d83…0414For00.00%—5y ago
Showing 38

07Forum

No forum thread is confidently linked to this proposal.