$3 500 000 USD





"Reimagine DeFi Possibilities. Meet Karura’s all-in-one DeFi platform to help you swap, borrow, lend, earn, and more – all with micro gas fees." "Karura is an all-in-one decentralized finance (DeFi) hub and stablecoin platform built on Kusama (KSM) and integrated into Polkadot (DOT). Karura was created by the Acala Network, which has won four Web3 Foundation grants and founded the Substrate Developer Academy."


"Founded by the Acala Foundation, Karura is a scalable, EVM-compatible network optimized for DeFi." "Karura was founded by the same team that is behind the Acala Network: Ruitao Su, Bette Chen and Bryan Chen." "Ruitao Su is a co-founder of Acala and current CEO of Laminar Protocol. Prior to that, he was the CTO of Centrality. Su is an award-winning software engineer, entrepreneur, investor and advisor to tech companies and startups."


"Self-described as "Polkadot's wild cousin," Kusama is an experimental blockchain platform that is designed to provide a massively interoperable and scalable framework for developers." "Kusama is built on Substrate — a blockchain building kit developed by Parity Technologies. Kusama has almost the same codebase as Polkadot — one of the most successful interoperable blockchains."


"Karura aims to be the first project to lease a parachain through a crowdloan on the Kusama network, and it is designed to function as a hub for decentralized finance on the blockchain, similar to Acala's role on Polkadot."


"The Kusama network has a near-identical codebase to Polkadot, and Karura also bears many similarities with Acala. Both platforms are fast-paced, efficient, inexpensive to use and sufficiently secure for all kinds of financial applications."


"Karura offers a stablecoin — Karura Dollar (kUSD), which maintains a 1:1 peg to the value of the U.S. dollar. This removes the need to send KSM tokens to Binance because users can safely swap KSM to a stablecoin (or to other assets such as Bitcoin)."


"The Kusama network, the experimental hotbed of unaudited, pre-production code serving as Polkadot’s wild cousin and somewhat rash trailblazer lived up to its “Expect Chaos” mantra and had another adventure."


"While XCM v2, which is in use on the Kusama Relay-chain and is nearing audit completion without any major issues found, has some expectation of security, XCM v0 and v1 were early revisions which were not audited and as such not intended for production use. Though Kusama is an unaudited and pre-production network, owing to the large attack surface of XCM, the ability for users to execute hand-crafted XCM messages was intentionally disabled."


"On October 12, 2021 Karura, a Kusama’s parachain, lost $3.5M worth of KSM tokens after an attacker injected malicious XCM (cross-chain message) transactions exploiting vulnerable code base. Most of the stolen funds were reclaimed through a governance action."


"The Karura team (one of Kusama’s parachains) discovered that the balance of KSM tokens held by Karura parachain on the Kusama Relay-chain did not match the total number of KSM tokens recorded in the Karura tokens pallet. To be precise, the Karura parachain account was holding 11,000.00 KSM less than could be explained. The team identified a number of suspicious XCM transactions that transferred KSM tokens out of Karura parachain account."


"This happened due to the compounding of three factors on the Karura chain: The misconfiguration of the XCM pallet The usage of older, flawed, code. The utilization of Reserve asset transfers. The combination of these factors led to the possibility of the attacker being able to execute a message which could make a withdrawal from Karura’s reserve account on the Relay-chain."


"They then took three actions. They notified centralised ecosystem infrastructure providers about the account containing the stolen funds; they helped Karura governance to invoke a special contingency-plan pallet to disable the ability to send raw XCM transactions immediately; and they requested the Kusama Relay chain’s decentralized governance bodies to help recover the funds."


"As a result of the latter, motion 373 was proposed by the council to recover the transferred funds (accounting for 10,000 KSM), followed by a Technical Committee proposal for fast-track referendum and the referendum itself. The period of the referendum and enactment was intentionally kept minimal by Kusama governance in order to maximise the chances of the recovery of stolen funds, which wouldn’t work if the attacker were to have transferred the funds during the vote."


"The force transfer referendum was approved & executed, and 9,999.00 KSM were transferred back to the Karura parachain account. Note: the motion failed to execute twice prior (referenda 141 and 142) due to incorrect usage of the preimage registration extrinsics, owing to the short enactment period."


"The remaining 1,000 KSM was burned by the attacker and we expect a proposal to be made to the Kusama council in due course to re-mint this missing KSM back into the Karura sovereign account."


"All parachains connected to Kusama network have since patched and upgraded their code if needed and no other attacks, successful or otherwise, have been detected."

The unaudited Karura smart contract contained an exploit which the team hadn't noticed. This was exploited in an attempt to take the funds. The attacker was too stupid to move the funds or negotiate a bounty, and kept them in the same wallet while the Karura governance system put through a proposal for them to be taken back to the treasury, voted on it, and executed it on the blockchain. (not just once, not just twice, but three times, since the frist 2 failed.) As a result, all funds were recovered without issue.


This type of issue was one which could have been easily detected through a professional audit. However, since professional audits cannot be guaranteed to catch all problems, the safest approach is to store most funds in offline multi-signature wallets. Online or hot systems can be insred through self-insurance, smart contract insuracne, or an industry insurance fund.


Check Our Framework For Safe Secure Exchange Platforms

Sources And Further Reading

 For questions or enquiries, email info@quadrigainitiative.com.

Get Social

  • email
  • reddit
  • telegram
  • Twitter

© 2021 Quadriga Initiative. Your use of this site/service accepts the Terms of Use and Privacy Policy. This site is not associated with Ernst & Young, Miller Thompson, or the Official Committee of Affected Users. Hosted in Canada by HosterBox.