DeFi Smart Contracts Drained Again for Millions by Hackers: Echos of the 2016 DAO Attack

TL;DR: Decentralized finance (DeFi), exotic and complex, is the buzzphrase of 2020, capturing nearly every cryptocurrency project’s attention. Increasingly, however, that popularity and complexity attracted not only investment capital but hackers. The most recent example involves ERC777 tokens, wrapped bitcoin imBTC, Uniswap, dForce, Lendf.Me, Compound, Multicoin Capital, Aave, and Tokenlon DEX in a dizzying mess that’s been exploited for $25,000,000.

DeFi Smart Contracts Drained Again for Millions by Hackers

In the wee small hours, morning of April 19, 2020, a dForce Telegram channel participant Kjiwa summed up what was thought to have happened. “DeFi, a Chinese project named Lendfme, has been hacked for $ 25 million in lost money. There is no way to return. Previously just received $ 1.5 million in Multicoin funding,” the post read, going on to accuse the project of copying “code from all [Compound]. The team doesn’t have any expertise. copy and then change it a little bit about interest in order to pull the user and push it to list the coin erc777, which has one function that is fragile to run.

“Summary,” Kjiwa continued, blasting, “This project is finished. I’ve only been born for 7 months after copying the compound code. (This point, ceo compound has already been said. Copy already. The team is not expert.) 3-4 days ago, I received funding. So I posted it on coindesk. Make people familiar And was completely exhausted by the hack.”

On the night of April 18, 2020, about 7 hours before Kjiwa, however, an enthusiast did note something strange and posted the observation in the dForce Telegram group, “Why would LendF website would suddenly show a banner saying: ‘不要存款!!!Do not supply anymore!!!'” Apparently, Twitter links were not allowed in on the channel, so no ready reference for members was available. Immediately, however, dForce CEO Mindao Yang appeared, warning, “we are still investigating pls do not supply any asset into lendf.me for now.”

dForce CEO: The Lendf.Me is Paused

dForce describes itself in poetic terms as “an integrated and interoperable platform of open finance protocols, creating an interconnected and interdependent ecosystem.” It’s essentially a DeFi pool of smart contract protocols, including Lendf.Me, which is listed as a ‘yielding protocol,’ said to be a “decentralized money market with instant withdrawal capability. Algorithmically derived interest rates based on market supply and demands applied,” according to a link no longer live.

About two hours later after that initial spotting by an enthusiast the day prior, another dForce Telegram channel participant complained, “They stopped the contract only 20 minutes later … They had a lot of time to do this earlier during the attack, it did not happen in 5-10 minutes, it lasted several hours.” Yang responded about a half-hour after, noting, “The lendf.me is paused. The contracts are paused. We are working on one and will keep the community posted.”

Official communication from dForce recently has been roses, according to its Medium blog. Indeed, only days ago, Yang posted personally about closing a “strategic round” of funding from the likes of Multicoin Capital, CMBI, and Huobi Capital. Even rotocol improvements were lauded. Everything seemed jake. Until it wasn’t.

A Sign That They Don’t Have the Capacity or Intention to Consider Security

As for the code copying charge leveled against dForce by Kjiwa, Compound’s founder alluded to it in a cryptic post. “If a project doesn’t have the expertise to develop [its] own smart contracts, and instead steals and redeploys somebody else’s copyrighted code, it’s a sign that they don’t have the capacity or intention to consider security. Hope developers & users learn from the @LendfMe hack.”

Decentralized exchange Tokenlon DEX, creators of the fateful wrapped imBTC token contract eventually exploited, markets itself as both a wallet and “built-in Tokenlon non-custodial exchange based on Ethereum and the 0x protocol.” Describing the draining of funds between Uniswap and Lendf.Me today as “reentrancy attacks,” the team’s preliminary investigation necessitated the imBTC contract be “suspended, waiting for the security incident to be evaluated, to be then restarted.”

Much of the technical analysis of the current attack is actually borrowed from, as Kjiwa insisted, Open Zepplin of about a year ago, Tokenlon DEX acknowledged. They rehash a timeline now fairly well understood of April 18th and 19th, 2020, stressing how Tokenlon “observed the anomaly, defined the incident as a P0-level security issue and established an emergency response team,” eventually suspending “the transfer of imBTC and notified imBTC partners including Lendf.Me to evaluate potential security risks.”

DeFi Community Warned Early

Interestingly, on April 18th, “imBTC transfer was resumed after receiving the confirmation from Lendf.Me and other partners that it is OK to do so,” and that appears to have been a fatal decision. Not too long after, “Tokenlon received a message from Lendf.me about a reentrancy attack, similar to the one happened to Uniswap, resulting in a large number of abnormal borrowing on the platform.”

What the latest attack will do to sour DeFi hype is anyone’s guess. Back in late February of 2020, Ethereum DeFi platform bZx was gamed twice in only four days, totaling losses just under $1,000,000, involving multiple uses of available technology and services. What’s stranger still is how well known such attack vectors have been, going back to 2016.

Osman Gazi Güçlütürk’s 2018 post mortem of that infamous DAO exploit four years ago rings eerily prescient. “The DAO can be considered as the first big-scale application of Ethereum-based smart contracts. The heist not only triggered a general suspicion against the Blockchain technology but also it heated the debate on the requirement of regulation. It was a real example how things could get bad in a world based on computer programs.”

Bitcoin Cash

CONTINUE THE SPICE and check out our piping hot VIDEOS. Our podcast, The CoinSpice Podcast, has amazing guests. Follow CoinSpice on Twitter. Join our Telegram feed to make sure you never miss a post. Drop some BCH at the merch shop — we’ve got some spicy shirts for men and women. Don’t forget to help spread the word about CoinSpice on social media.

DYOR: CoinSpice is your home for just spicy crypto things. We’re not affiliated with any cryptocurrency project or token. Each published piece is intended for information purposes only, not investment advice and not in the hope of impacting speculative markets. There are plenty of trading sites and coin-specific advocacy journals out there, we’re neither. CoinSpice strives for rigorous accuracy in our reporting. Information presented here is contingent usually on a host of factors, and the ecosystem moves fast — prices change, projects change, and at warp speed. Do your own research.

DISCLOSURE: The author holds cryptocurrency as part of his financial portfolio, including BCH.