Attackers exploit flaw in web’s security to steal $2M in cryptocurrency
Attackers hijacked the BGP routes for a domain used to serve a JavaScript library, then obtained a valid TLS certificate for that domain via a certificate authority, and served malicious JavaScript to KLAYswap users so their cryptocurrency transactions were redirected to the attacker. Approximately $2 million worth of cryptocurrency was stolen.
freedom-to-tinker.com
Published on freedom-to-tinker.com
On Thursday, Feb. 3, 2022, attackers stole approximately $2 million worth of cryptocurrency from users of the Korean crypto exchange KLAYswap.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the certificate authority's domain control validation relied on network routing that could be hijacked via BGP, allowing the attacker to obtain a valid certificate for a domain they did not control.
Impact
The attacker stole approximately $2 million worth of cryptocurrency from KLAYswap users, and the underlying vulnerabilities remain unmitigated.
What the attacker needed
Ability to perform a BGP hijack; target uses a third-party JavaScript library; certificate authority performs domain validation over HTTP
How it was found
- The attacker performed a BGP hijack to redirect traffic for developers.kakao.com to their own network.
- The attacker requested a TLS certificate for developers.kakao.com from ZeroSSL and completed domain control validation by serving the required content.
- The attacker served a malicious JavaScript file (kakao.min.js) to KLAYswap users over the hijacked connection.
- The malicious JavaScript caused users' cryptocurrency transactions to transfer funds to the attacker.
- After several hours, the attacker withdrew the route and converted the stolen cryptocurrency to untraceable currencies.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
The internet's routing system (BGP) tells networks where to send traffic for a given IP address. Attackers can lie about routes to redirect traffic to themselves. Separately, certificate authorities (CAs) issue TLS certificates that make websites appear secure, but they verify domain control over the network, which can also be hijacked. In this attack, the attackers redirected traffic for a JavaScript library's domain, obtained a valid certificate for it, and served malicious code that stole cryptocurrency.
What is Crypto?
Encryption, signatures, randomness or certificate checks that do not protect what they claim to.