Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The line of source code cited in the post isn't immediately evident in the Iron Contracts repo:

require(_share_price > 0, “Invalid share price”);

https://github.com/IronFinance/iron-contracts

Is it in a different repo? Does it exist?




I think it ultimately boils down to

https://github.com/IronFinance/iron-polygon-contracts/blob/m...

> uint256 private constant PRICE_PRECISION = 1e6;

yikes :D


Not unlike many package repositories (PyPI etc.) and GitHub, the actual code a smart contract is running doesn't necessarily have any connection to what's in some GitHub repo. The only way to know is to look at what's on the actual blockchain.

(If verified source is published, you can see the actual code; else you'd have to decompile the EVM bytecode. But basically 100% of the time, if verified source isn't provided then it's a scam, so it's safe to just ignore things without source. And, of course, even if verified source is published, there's still a high chance any given contract picked out of a bucket will be a scam, but at least you can review the code and spot the backdoor.)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: