Ribbon Finance Malicious DNS Hijack

From Quadriga Initiative Cryptocurrency Hacks, Scams, and Frauds Repository
Jump to navigation Jump to search

Ribbon Finance is a yield earning protocol. The service used NameCheap to host their primary domain where customers would interact with the service. On June 23rd, a request was made to change the DNS settings on their domain name, which was believed to be due to a vulnerability in NameCheap. This redirected the website to a phishing version, which looked identical to main version. The phishing site requested approval on a new smart contract with a similar address. Approving the new smart contract allowed the attacker to steal funds and was active on the site for a few hours (plus DNS propagation time). While multiple wallet addresses gave approvals, it was reported that only two users lost funds. There hasn't been any public statement on whether Ribbon Finance will assist those users.

Ribbon Finance Homepage/Logo


About Ribbon Finance

Ribbon Finance describes themselves as a yield earning protocol[1].

"SUSTAINABLE ALPHA FOR EVERYONE" "Earn yield on your cryptoassets with DeFi's first structured products protocol." "Ribbon Finance is a new protocol that helps users access crypto structured products for DeFi. It combines options, futures, and fixed income to improve a portfolio's risk-return profile."

Ribbon Finance's Theta Vault product is a strategy focused around yield between ETH (ethereum) and WBTC (wrapped bitcoin)[2][3]. It has been extensively audited[4]. Audits were found provided by Quantstamp[5], ChainSafe (2 audits)[6], Peckshield[7], and OpenZeppelin[8], and the service has an active bug bounty program on ImmuneFi[9] which pays rewards of up to $250,000 USD[2]. Despite all this, the protocol still advises users to exercise caution and not risk funds they are not willing to lose.[10]

"Theta Vault, which is a yield-focused strategy on ETH and WBTC. The vault earns yield on its deposits by running a weekly automated options selling strategy. The vault reinvests the yield earned back into the strategy, effectively compounding the yields for depositors over time." "Ribbon's v1 and v2 Theta Vault contracts are audited. Despite the audits and security measures we have taken, we advice users to exercise caution and to not risk funds they are not willing to lose."

The Reality

While the smart contract operates in a decentralized "trustless" manner, most users will tend to interact with the contracts using transactions generated by a centralized "trusted" website. When a domain name is accessed on the internet, a service called DNS (Domain Name System) is used to route the user to the appropriate server[11].

The Ribbon Finance project used NameCheap for their registrar for their primary website ribbon.finance[12]. The procedures at NameCheap for most domains were such that individual support team members were able to override the DNS of the website[13][14][15].

NameCheap also offers a "Domain Vault" service for an additional monthly fee, which appears to have been fully launched on June 20th, 2022, coincident with the time of the attack[16][17][18].

"Usually we require a [PIN] code from customer. We also monitor all actions as well a[s] monitor a real time [VIP] list. In the end our [customer support] needs to be able to modify to help customers[,] especially when 99% don't understand [DNS]. If you want complete security use [Domain Vault]"

Ribbon Finance was not enrolled in the DomainVault service[18][19], which had only recently launched[16][17].

What Happened

The account of a customer support agent for NameCheap was reportedly hacked[20].

This allowed the attacker to modify the DNS settings for multiple high profile decentralized protocols with domain names registered there, including Convex Finance, Ribbon Finance, Defi Saver, and AllBridge[21]. The attacker was able to override any 2-factor authentication, passwords, and security alert settings[22][23][24].

The issue was quickly corrected by the Ribbon Finance team, but not before 2 users were affected[25].

Key Event Timeline - Ribbon Finance Malicious DNS Hijack
Date Event Description
March 22nd, 2022 Domain Vault Announced The first archived appearance of the "Domain Vault" service on NameCheap which costs $19.88/mo and is still "coming soon"[26].
June 20th, 2022 3:05:42 AM First Malicious Contract The very first smart contract is created by a wallet controlled from the attacker[27]. Malicious contract 0x65a8...3b2f[28] was created by wallet 0x5622...781a[27][29].
June 20th, 2022 Domain Vault Launches The NameCheap "Domain Vault" service now switches from "Get early access" to "Get Domain Vault" with the price remaining at $19.88/mo[16][17].
June 23rd, 2022 6:17:41 AM Final Malicious Contract The final malicious smart contract is created by the attacker[30]. [31][31]
June 23rd, 2022 1:02:00 PM Alexintosh Convex Finance Tweet The Twitter user @alexintosh reported an abnormal approval requested by the similarly affected Convex Finance website, with a similar but not exact smart contract address[32][33][34].
June 23rd, 2022 2:23:00 PM Please Review Approvals Convex Finance posts their very first announcement on Twitter, requesting users to "[p]lease review approvals while we evaluate a potential front end issue[35]."
June 23rd, 2022 3:46:00 PM Additional Malicious Contracts Twitter user @HarukoTech describes several malicious contracts which were created against different protocols and that "[t]he attacker seems to be generating similar addresses to well know[n] protocols"[36].
June 23rd, 2022 3:54:00 PM Bret Woods Suggestion Twitter user Bret Woods (@fewture) posts that "[w]e're seeing hackers create addresses that match the first 4 and last 4 characters". His suggestion is to run the same transaction with "the gas SUPER LOW. Like 5 gwei. Your transaction won't go through, but it will populate on @etherscan where it is much easier to click through and make sure it's doing what you intended to do"[37].
June 23rd, 2022 4:46:00 PM Convex Finance DNS Hijack Post Similarly affected Convex Finance first posts on Twitter to announce the DNS hijacking. They list 5 addresses which are affected, that investigation is still ongoing, and that the issue is "remediated" for their service[38][34].
June 23rd, 2022 9:32:48 PM MDT Initial USDC Theft A smaller transfer of 110 USDC is performed on another user who approved the phishing smart contract[39].
June 23rd, 2022 9:57:59 PM MDT Massive WBTC Theft A total of 16.50942255 WBTC are transferred from one user and victim of the DNS exploit to the attacker[40][41].
June 24th, 2022 2:29:00 AM Immediate Remediation Ribbon Finance posts on Twitter that they have "immediately remedied the issue"[25].
June 24th, 2022 4:10:00 AM MistTrack Analysis MistTrack is one of the first firms to report on the issue, providing a blockchain transaction for 16.5 WBTC (wrapped bitcoin)[42].
June 24th, 2022 6:00:00 AM Telegram Group Operating A Telegram group has reportedly been set up for communication and coordination between the different affected protocols[43].
June 24th, 2022 6:14:00 AM MDT All Attacks Reported Together All 4 "DNS exploit[s]" with "illicit vanity contracts" are reported by Twitter user CryptoCondom. He also mentioned that all protocols were using 2FA[24].
June 24th, 2022 7:00:00 AM MDT Attacks Reported With Screenshots Twitter user Nalin Gupta is the first to publicly provide screenshots of all 4 DNS attacks in a single thread[44].
June 24th, 2022 7:24:00 AM MDT Speculation About Further Domains Further speculation arises that some other domains may be related[45]. The list referenced are cryptocurrency phishing websites and it does not appear that any of those domains are related to the DNS attack[46].
June 24th, 2022 7:29:00 AM Attacks Reported Together Again Twitter user Tommy Famous also reports on all 4 DNS attacks in a single thread[47].
June 24th, 2022 10:01:00 AM NameCheap Response NameCheap's CEO responds on Twitter that they've "traced this down to a specific [customer support] agent that was either hacked or compromised somehow and have removed all access from this agent. This affected a few targeted domains but we will continue investigating."[48]
June 24th, 2022 10:03:00 AM Free DomainVault Monitoring NameCheap's CEO expands the original tweet to say that they "would like to offer [affected services their] Domain Vault service for free and [they] will also place all affected domains on the highest security monitoring"[19].
June 24th, 2022 10:32:00 AM MDT Nothing To Worry About NameCheap assures via Twitter that "[t]here is nothing to worry about" and they will "keep investigating"[49].
June 24th, 2022 11:21:00 AM NameCheap DomainVault "Usually we require a pin code from customer. We also monitor all actions as well a monitor a real time vip list. In the end our [customer support] needs to be able to modify to help customers especially when 99% don't understand [DNS]. If you want complete security use [DomainVault]"[18]
June 24th, 2022 4:16:00 PM NameCheap Clarifies Hack NameCheap responds that it "[l]ooks more like [their customer support] person was hacked."[20]
June 25th, 2022 4:14:00 AM Developer Trying To Get In Contact Ribbon Finance developer kenchangh[50] appears to be trying to get in contact with the NameCheap CEO[51].
June 25th, 2022 Domain Vault Discount NameCheap lowers the price of their Domain Vault service from $19.88/mo[52] to $1.88/mo[53].
July 1st, 2022 10:14:00 AM Postmortem Released Convex Finance releases a post-mortem report with further details of what happened, how much was lost, and their compensation plans[54][12].
July 2nd, 2022 3:25:00 AM Founder Trying To Get In Contact Ribbon Finance founder juliankoh[55] appears to be trying to get in contact with the NameCheap CEO[56].
July 2nd, 2022 Price Segmentation NameCheap decides to offer two different Domain Vault services from "Silver" tier at $1.88/mo[57] to "Titanium" tier at $19.88/mo[58].

Technical Details

Blockchain Analytics

Various notable addresses and transactions from Etherscan for further research/analysis:

[59][60][61][62][63][64][65][66][67]

Total Amount Lost

Ribbon Finance reports that at least 2 users were affected by the incident[25].

MistTrack reports one of the users lost 16.5 WBTC[42]. Blockchain analysis shows that the exact amount was 16.50942255 WBTC[40]. The closing market price of wrapped bitcoin on June 23rd, 2022 was $21,057.95 USD[68]. This creates a loss estimate of $347,654.59 USD.

While Ribbon Finance does not express any indication of the second affected user, it is most likely a smaller transaction for 110 USDC[39].

This creates a total loss estimate of $347,764.59 USD, which can be estimated to $348,000 USD.

Immediate Reactions

Ribbon Finance reported an "immediate remedy" on their Twitter shortly after the DNS issue was initially reported[25].

We are aware of a DNS attack on http://app.ribbon.finance and have immediately remedied the issue.

The takeover prompted 2 users to approve malicious contracts for vault deposits.

All funds on the vault contract are unaffected.

A Telegram group was set up for communication between the different affected protocols[43]. MistTrack was one of the first to respond to the situation, highlighting a transaction for the theft of 16.5 WBTC[42].

On-chain analysis showed that it was the same attacker as Convex. One victim lost 16.5 WBTC.

It is unclear if Ribbon Finance was in contact with NameCheap or part of the earlier groups prior to their first public record of trying to reach NameCheap on June 25th[51].

Ultimate Outcome

The NameCheap CEO ultimately responded on Twitter to explain that there was a hacked or compromised customer support agent and all access was removed from them[48]. He also offered completely free Domain Vault monitoring to all affected services[19].

"We've traced this down to a specific [customer support] agent that was either hacked or compromised somehow and have removed all access from this agent. This affected a few targeted domains but we will continue investigating." "In the meantime we would like to offer you our Domain Vault service for free and we will also place all affected domains on the highest security monitoring."

Records can be found of the Ribbon Finance team members trying to reach NameCheap on June 25th[51] and July 2nd[56]. No further communication to the community from Ribbon Finance on the matter could be located on Twitter.

Total Amount Recovered

The total amount recovered is unknown. It is suspected that nothing was done to assist the affected users in this case.

Ongoing Developments

It is unclear if any further investigation is underway to identify and recover the funds from the attacker.

Ribbon Finance has rebranded as Aevo[69].

Individual Prevention Policies

There are two policies which apply in this case. See the Prevention Policies for Individuals page for the full list.

Full Prevention

Every approval on Web3 is an opportunity to lose all of the funds present in your wallet. Take the time to review the transaction in full. Fully check over the balance, permissions, and entire address which you are interacting with. Do not trust that your clipboard or any website front-end is guaranteed to provide an accurate address or transaction status. Always perform a test transaction prior to the first high-value transaction in any session.

Limiting Losses

Store the majority of funds offline. By offline, it means that the private key and/or seed phrase is exclusively held by you and not connected to any networked device. Examples of offline storage include paper wallets (seed phrase or key written down and deleted from all electronic media), hardware wallets, steel wallet devices, etc...

Platform Prevention Policies

There are three different policies applying here. See the Prevention Policies for Platforms page for all policies.

Prevention by Namecheap

All wallets, minting functions, and critical infrastructure should be implemented with a multi-signature requirement, with a recommended minimum of 3 signatures required. This means that making important changes or approving spending will require the keys held by at least 3 separate individuals within the organization to approve. The multi-signature should be implemented at the lowest layer possible, all key holders should have security training, and all key holders should be empowered and encouraged to exercise diligence.

The issue ultimately stemmed from a single customer support agent being compromised. A multi-signature requirement on DNS changes would have prevented this scenario entirely. While NameCheap offers advanced protections on their domain names, this service had just launched two days prior to the DNS change, so it was unlikely to be a reasonable expectation that Convex Finance would have already signed up.

Prevention by Ribbon Finance

All points along the communication and supply chain should be inspected for vulnerabilities. Common vulnerability points may include DNS, Discord, and customer information. What steps are required to access and/or modify the component? Do any third party companies or organizations implement a proper multi-signature approach? What additional security options are available?

Regulatory Prevention Policies

There is one policy to prevent the situation, and one to reduce the impact. See the Prevention Policies for Regulators page for the full list of policies.

Full Prevention Through Security Assessments

All platforms should undergo published security and risk assessments by independent third parties. Two assessments are required at founding or major upgrade, one after 3 months, and one every 6 months thereafter. The third parties must not repeat within the past 14 months. A risk assessment needs to include what assets back customer deposits and the risk of default from any third parties being lent to. The security assessment must include ensuring a proper multi-signature wallet, and that all signatories are properly trained. Assessments must be performed on social media, databases, and DNS security.

Reduction Through Education

Create a standard tutorial and quiz for all new cryptocurrency participants, which is required to be completed once per participant. This tutorial and quiz should cover the basics of proper seed phrase protection, strong password generation, secure two-factor authentication, common fraud schemes, how to detect and guard against phishing attacks, how ponzi schemes work, as well as other risks which are unique to the cryptocurrency space.

This could greatly reduce the effectiveness of a similar fraud to affect those such educated.

References

  1. Ribbon Finance: Crypto structured products on Ethereum (Oct 12, 2021)
  2. 2.0 2.1 Ribbon Finance Bug Bounties on ImmuneFi (Feb 25, 2023)
  3. Introduction to Ribbon - Ribbon Finance (Dec 4, 2021)
  4. audit/RibbonThetaVault V2 Smart Contract Review And Verification.pdf at master · ribbon-finance/audit · GitHub (Dec 4, 2021)
  5. audit/Quantstamp Theta Vault.pdf at master · ribbon-finance/audit · GitHub (Dec 4, 2021)
  6. audits/Ribbon-Audit_April-2021.pdf at main · ChainSafe/audits · GitHub (Dec 4, 2021)
  7. audit/PeckShield-Audit-Report-Ribbon-v1.0.pdf at master · ribbon-finance/audit · GitHub (Dec 4, 2021)
  8. Ribbon Finance Audit - OpenZeppelin blog (Dec 4, 2021)
  9. Ribbon Finance ImmuneFi Bug Bounty - Coin World Story (Feb 25, 2023)
  10. Security - Ribbon Finance (Dec 4, 2021)
  11. What is DNS? | How DNS works | Cloudflare (Feb 9, 2023)
  12. 12.0 12.1 Post Mortem Of Events June 23 - Convex Finance Medium (Aug 24, 2022)
  13. @ConvexFinance Twitter (Aug 24, 2022)
  14. @DevanCollins3 Twitter (Aug 24, 2022)
  15. @LefterisJP Twitter (Feb 10, 2023)
  16. 16.0 16.1 16.2 Domain Vault Page on June 19th, 2022 - Namecheap (Feb 12, 2023)
  17. 17.0 17.1 17.2 Domain Vault Page on June 20th, 2022 - Namecheap (Feb 12, 2023)
  18. 18.0 18.1 18.2 Richard Kirkendall - "If you want complete security use [Domain Vault]" - Twitter (Aug 24, 2022)
  19. 19.0 19.1 19.2 Richard Kirkendall - "we would like to offer you our Domain Vault service for free and we will also place all affected domains on the highest security monitoring" - Twitter (Feb 24, 2023)
  20. 20.0 20.1 Richard Kirkendall - "Looks more like CS person was hacked." - Twitter (Feb 11, 2023)
  21. DeFi Dapps DNS Attacked - TrustNodes (Feb 25, 2024)
  22. DeFiSaver - "Same as with others, strong passwords and 2fa were used and we don't recognise security factors on our end that could have led to this." - Twitter (Mar 23, 2023)
  23. DefiSaver - "We certainly did use 2FA, as mentioned and as did other teams." - Twitter (Mar 23, 2023)
  24. 24.0 24.1 CryptoCondom - "A multi-platform DNS exploit appears to have occurred this week w/illicit vanity contracts" - Twitter (Apr 1, 2023)
  25. 25.0 25.1 25.2 25.3 Ribbon Finance Reports Remedy - Twitter (Feb 22, 2023)
  26. Domain Vault Page on Mar 22nd, 2022 - Namecheap (Feb 9, 2023)
  27. 27.0 27.1 First Transaction Creating Malicious Contract 0x65a8...3b2f - Etherscan (Feb 23, 2023)
  28. Unused Contract 0x65a8...3b2f - Etherscan (Feb 27, 2023)
  29. Wallet Address 0x5622...7d1a Who Created 0x65a8...3b2f - Etherscan (Feb 27, 2023)
  30. Final Malicious Contract Creation - EtherScan (Feb 23, 2023)
  31. 31.0 31.1 Transaction Creating 0xdd49....c82b - Etherscan (Feb 23, 2023)
  32. Alexintosh - "What is this unverified contract ? @ConvexFinance website is asking for approval for that but the correct one is [different.] 4 Starting/Ending Characters are the same. DNS spoofing?" - Twitter (Aug 23, 2022)
  33. Contract Addresses - ConvexFinance (Aug 24, 2022)
  34. 34.0 34.1 Convex: more info on the hack - Cryptonomist (Jul 2, 2022)
  35. Convex Finance - "Please review approvals while we evaluate a potential front end issue." - Twitter (Aug 23, 2022)
  36. HarukoTech - "The potential malicious contract appears to transfer funds to address .... There are several other potentially malicious contracts" - Twitter (Aug 24, 2022)
  37. Bret Woods (@fewture) - "You need to be careful with EVERY tx you make in crypto. Scammers are endless. Even on trusted sites, we're seeing UIs being hacked, leading to erroneous token approvals, resulting in the hacker stealing your funds." - Twitter (Feb 22, 2023)
  38. Convex Finance - "Investigation is still ongoing, but a quick update for the community: DNS for http://convexfinance.com was hijacked, prompting users to approve malicious contracts for some interactions on the site. Funds on verified contracts are unaffected." - Twitter (Aug 24, 2022)
  39. 39.0 39.1 Malicious Transfer of 110 USDC to Attacker - Etherscan (Mar 25, 2023)
  40. 40.0 40.1 Theft Transaction For 16.5 WBTC - Etherscan (Feb 22, 2023)
  41. Overview of WBTC Related Transactions - Etherscan (Mar 8, 2023)
  42. 42.0 42.1 42.2 MistTrack Transaction Analysis - Twitter (Feb 22, 2023)
  43. 43.0 43.1 0xLlam4 - "on TG, can add you into a group with affected protocols" - Twitter (Feb 27, 2023)
  44. Nalin Gupta - "4 DeFi projects have experienced a DNS hijack attack" - Twitter (Apr 1, 2023)
  45. Nalin Gupta - "It does seem some others might be affected tho[ugh]" - Twitter (Apr 1, 2023)
  46. idclickthat - "crypto phish" - Twitter (Apr 1, 2023)
  47. TommyBeFamous - "So far 4 #ethereum DeFi projects experienced a DNS hijack attack." - Twitter (Mar 24, 2023)
  48. 48.0 48.1 Richard Kirkendall - "traced this down to a specific [customer support] agent that was either hacked or compromised" - Twitter (Aug 24, 2022)
  49. NameCheap - "There is nothing to worry about; we keep investigating" - Twitter (Apr 1, 2023)
  50. kenchangh - "Dev @RibbonFinance. We need to build Galt's Gulch in Cyberspace." - Twitter (Mar 23, 2023)
  51. 51.0 51.1 51.2 Ken Changh - "hi @NamecheapCEO, can I DM you on behalf of @ribbonfinance?" - Twitter (Mar 23, 2023)
  52. Domain Vault Page on June 24th, 2022 - Namecheap (Feb 13, 2023)
  53. Domain Vault Page on June 25th, 2022 - Namecheap (Feb 13, 2023)
  54. Convex Finance - "Important Update on Medium regarding the DNS hijacking events last weekend." - Twitter (Feb 18, 2023)
  55. Julian Koh - "janitor & community manager @ribbonfinance" - Twitter (Mar 19, 2023)
  56. 56.0 56.1 Julian Koh - "trying to get in touch regarding the @ribbonfinance situation, i am one of the founders" - Reddit (Mar 19, 2023)
  57. Domain Vault Page on July 1st, 2022 - Namecheap (Feb 13, 2023)
  58. Domain Vault Page on July 2nd, 2022 - Namecheap (Feb 13, 2023)
  59. Unused Contract 0x65a8...3b2f - Etherscan (Feb 27, 2023)
  60. Transaction Creating Contract 0x65a8...3b2f - Etherscan (Feb 27, 2023)
  61. Wallet Address 0x5622...7d1a Who Created 0x65a8...3b2f - Etherscan (Feb 27, 2023)
  62. Transaction Creating 0xdd49....c82b - Etherscan (Feb 23, 2023)
  63. Transactions By Wallet 0x56d3...49c8 (Fake_Phishing5851) - Etherscan (Dec 27, 2023)
  64. Address 0x4e12...899a Who Created 0xf403...ae31 - Etherscan (Dec 28, 2023)
  65. Vanity Phishing Smart Contract 0xF403...AE31 - Etherscan (Dec 7, 2o23)
  66. Address 0xB732...F9Aa (Convex & Ribbon Phisher) - Etherscan (Aug 23, 2022)
  67. Convex Finance Tokens Received By Convex & Ribbon Phisher - Etherscan (Dec 28, 2023)
  68. Wrapped Bitcoin Historic Prices - CoinMarketCap (Feb 22, 2023)
  69. Aevo (fka Ribbon Finance) - Twitter Profile (Dec 19, 2023)