so @Lighter_xyz wasn’t hacked, but how did an API key get compromised? turns out it took nothing more than public data and 8th grade algebra first of all be careful when you decide to write your own custom solution, especially when it touches cryptography the trader’s bot used custom signing code instead of Lighter’s official sdk and reused the same nonce (a number that’s supposed to be unique and unpredictable every time) in two signatures every signature is roughly nonce + hash × key, and both the signature and the hash are public. so if you subtract one signature from the other, the nonce cancels out and the private key is the only unknown left! so, nothing about Lighter itself broke, and the team has already shipped a fix that hides signatures, which helps. but if you’re running your own signing code and haven’t dug deep into how it works, i’d just switch to the official sdk (or at least make sure every nonce comes from a proper secure random generator)
BitdukeShare

Source:Show original
Disclaimer: The information on this page may have been obtained from third parties and does not necessarily reflect the views or opinions of KuCoin. This content is provided for general informational purposes only, without any representation or warranty of any kind, nor shall it be construed as financial or investment advice. KuCoin shall not be liable for any errors or omissions, or for any outcomes resulting from the use of this information.
Investments in digital assets can be risky. Please carefully evaluate the risks of a product and your risk tolerance based on your own financial circumstances. For more information, please refer to our Terms of Use and Risk Disclosure.