Hegic Exchange Funds Locked
Notice: This page is a freshly imported case study from the original repository. The original content was in a different format, and may not have relevant information for all sections. Please help restructure the content by moving information from the 'About' section to other sections, and add any missing information or sources you can find. If you are new here, please read General Tutorial on Wikis or Anatomy of a Case Study for help getting started.
Customer funds on the Hegic Exchange platform were locked up due to a typo in the smart contract. The platform had requested a code review by an auditing firm, and that firm failed to notice the issue at the time.
In the end, the amount lost was not that significant (compared to other incidents) and was fully reimbursed by Hegic.
This is a global/international case not involving a specific country.
About Hegic Exchange
"Hegic is an options protocol taking a fresh approach to minting and trading options." "Trade non-custodial options for profits or to hedge your positions. Enjoy fixed price and unlimited upside of the options contracts. No registration, KYC or email required.". "Traders and holders can use options on Hegic to insure against price volatility. Consider ETH is worth $500, and a user buys an option contract, which enables them to sell one ETH for 500 DAI within some time window. If ETH price tanks to $400, the user can safely exercise the contract, liquidating their position for 500 DAI." "Hegic Protocol V1 code has been audited by @trailofbits. Security audit includes HegicOptions, HegicCallOptions, HegicPutOptions, ETHPool and ERCPool contracts."
"Hegic made its debut on the mainnet on 23rd April 2020, hours after going live, they claimed to have a bug in the smart contract. The bug locked user funds into expired options contracts, rendering them permanently inaccessible. Up to $48,000 worth of funds were forever locked up in the platform’s smart contract." "All found issues were fixed and now IT IS MUCH SAFER TO USE THE CONTRACTS!"
"The options platform Hegic wasn’t attacked by anyone, yet a typo in the project’s code led to freezing users’ assets." "It’s NOT a security issue. It’s an incorrect function name (optionIDs instead of optionsIDs). This function unlocks liquidity in expired contracts. If it doesn’t work, funds are just forever locked. It can’t be used by a malicious actor. @trailofbits did their job well."
"Trail of Bits was not so happy that Hegic claimed they had “audited” the smart contract. CEO Dan Guido asked them in a tweet: “Please stop holding up a 3-day code review as an ‘audit’ that proves the code is safe.”"
"Hegic’s founder reimbursed everyone who suffered."
"As the liquidity is [forever] locked on the old contracts with a bug, all the LPs who have suffered losses due to the bug have received a 100% refund. Those who have closed their options early, have also received a 100% refund. $47,765 in total was paid out to LPs & holders."
This is a global/international case not involving a specific country.
The background of the exchange platform, service, or individuals involved, as it would have been seen or understood at the time of the events.
Include:
- Known history of when and how the service was started.
- What problems does the company or service claim to solve?
- What marketing materials were used by the firm or business?
- Audits performed, and excerpts that may have been included.
- Business registration documents shown (fake or legitimate).
- How were people recruited to participate?
- Public warnings and announcements prior to the event.
Don't Include:
- Any wording which directly states or implies that the business is/was illegitimate, or that a vulnerability existed.
- Anything that wasn't reasonably knowable at the time of the event.
There could be more than one section here. If the same platform is involved with multiple incidents, then it can be linked to a main article page.
The Reality
This sections is included if a case involved deception or information that was unknown at the time. Examples include:
- When the service was actually started (if different than the "official story").
- Who actually ran a service and their own personal history.
- How the service was structured behind the scenes. (For example, there was no "trading bot".)
- Details of what audits reported and how vulnerabilities were missed during auditing.
What Happened
The specific events of the loss and how it came about. What actually happened to cause the loss and some of the events leading up to it.
| Date | Event | Description |
|---|---|---|
| April 24th, 2020 12:00:00 AM | First Event | This is an expanded description of what happened and the impact. If multiple lines are necessary, add them here. |
Total Amount Lost
The total amount lost is unknown.
How much was lost and how was it calculated? If there are conflicting reports, which are accurate and where does the discrepancy lie?
Immediate Reactions
How did the various parties involved (firm, platform, management, and/or affected individual(s)) deal with the events? Were services shut down? Were announcements made? Were groups formed?
Ultimate Outcome
What was the end result? Was any investigation done? Were any individuals prosecuted? Was there a lawsuit? Was any tracing done?
Total Amount Recovered
It is unknown how much was recovered.
What funds were recovered? What funds were reimbursed for those affected users?
Ongoing Developments
What parts of this case are still remaining to be concluded?
Prevention Policies
Smart contracts are generally too complex to prove that they are error-free. Storage in offline multi-signature wallets is generally simpler and possible to validated. It's important to always test that wallets are set up correctly.
References
Crypto Hacks 2020: A Comprehensive List - ImmuneBytes (May 17)
Millions Lost: The Top 19 DeFi Cryptocurrency Hacks of 2020 | Crypto Briefing (May 21)
@HegicOptions Twitter (May 22)
Hegic: New Age Options Trading Protocol | Crypto Briefing (May 23)
Hegic: On-chain options trading protocol on Ethereum (May 23)
@HegicOptions Twitter (May 23)
@HegicOptions Twitter (May 23)
publications/hegic-summary.pdf at master · trailofbits/publications · GitHub (May 23)
Hegic Analysis Report: Non-Custodial Options Protocol | Albaron Ventures (May 23)
@HegicOptions Twitter (May 23)
@HegicOptions Twitter (May 23)
@dguido Twitter (May 23)
Defi Sharing The Risks Rewards And Responsibility (May 23)
DeFi Security: With So Many Hacks, Will It Ever Be Safe? - Unchained Podcast (May 23)
SlowMist Hacked - SlowMist Zone (May 17)
Hegic Exploit · GitHub (Jun 22)
List of Ethereum Smart Contracts Post-Mortems - Security - OpenZeppelin Community (Jun 22)
CRYPTO ANONSENSE [Book] (Jul 28)
DeFi Bug Freezes $30,000 of Ether Forever | Crypto Briefing (Jul 28)
No Title (Jul 28)
Examining Decentralized Options Platforms - Deribit Insights (Jan 15)