Sigh... you should know and I know that MAX_MONEY could equal "gesundheit" for all the difference that it really makes. If you are worried about redundant variables left in code you should avoid checking the code for just about every commercial program in captivity.
Completely wrong, the value of MAX_MONEY is very important, along with COIN. MAX_MONEY = 420,000,000 * COIN is absurd and way over shot for the supply this coin distributes. COIN = 10^8 or 100,000,000.
MAX_MONEY essentially the accepted amount allowed on your network within a transaction, you just are not accepting this fact for some reason.
Seems you too also would rather be lackadaisical about the allowed supply to exist with your investments in this coin.
This fix will require a hard fork and probably something to address before network hash rates get low enough to prevail a malicious attack, not just potentially here, but anywhere else you may have a "redundant variables".
It's a vulnerability clearly sitting in plain view.Proof of stake is also something to consider discussing as BitcoinSanDiego has mentioned previously. Many coins have successfully mitigated this transfer with plenty of success without requiring a switch of blockchains.
-James
As a programmer that reads the source code of these various coins, I can say that MAX_MONEY is often defined as the maximum supply of the coin that will ever exist by the programmers. This doesn't mean that the value of MAX_MONEY actually is the maximum amount of a coin that will ever be created. With Bitcoin it is, but I have seen other coins that have a difference between the value of MAX_MONEY and the maximum amount of coins that can be generated once the block reward drops to a number close to zero coin.
The Value of MAX_MONEY is used within the source code as a sanity check on the on any amount of coins, whether it be a transaction value or individual transaction output or a transaction fee. The source code checks the validity of a value of a number of coins by making sure that the value is above zero (0) and less than the value of MAX_MONEY. Additionally MAX_MONEY is the transaction fee for a block that is larger than a maximum size. The value of MAX_MONEY is arbitrary and could be mistakenly set to a value that would modify the behavior of the coin. For instance, if MAX_MONEY was set to 100 coins, whether mistakenly or on purpose, then this will definitely limit the amount of coins that could be sent in a transaction, while having other side effects.
MAX_MONEY is hard coded into the source code and some calculations are required to make sure that it would agree with the actual maximum amount of coins that could be produced on the blockchain according to the GetBlockValue function. For CANN, my calculations show that GetBlockReward maxes out at around 20 halvings of the block reward at around 105,860,159.84. Therefore CANN uses a value of 420 million for MAX_MONEY, while the actual max money will be about 106 million.
Does MAX_MONEY have any security issues? Could leaving it at 420,000,000 allow for an attack that creates 300,000,000 coins and has users with the current wallet allowing that attack?
This is getting ridiculous guys.
Here's how to satisfy yourselves that MAX_MONEY is entirely innocuous:
Go to the
CannabisCoin git repository.
At the top of the page you'll see a search box, which should be set to searching "this repository" by default.
Type in MAX_MONEY (the search is case insensitive so it doesn't have to be all uppercase).
You will receive back two files with a total of four lines highlighted.
1)
main.h line 57 is the declaration of MAX_MONEY.
2)
and line 58 which is a boolean (true/false) declaration basically defining a positive number of coins.
3)
main.cpp line 564 which tests whether a transaction is malformed.
and 4)
line 627 which prevents blocks exceeding the maximum permissible size by making the fee larger than can possibly be paid.
That's it. At no point does CannabisCoin ever use the value MAX_MONEY to determine how many coins may exist at any given moment nor the coin generation rate at any block height.
Look for yourselves and if you don't believe Git's repository search then download the source and use your own computer's search to check for any other mentions.
For goodness sake do your own research rather than falling for Jamie boy's malicious well-poisoning efforts. He has a long history of malice toward CannabisCoin and he is not an investor's friend.
Can we please put this nonsense to bed?