Pages:
Author

Topic: [ANN] SMAC - Accounts have been suspended project closed - page 36. (Read 65854 times)

hero member
Activity: 840
Merit: 500
A single PoS block minting 365 coins is rare with our small supply but obviously we will implement the fix. Changes like this submitted with a fix are rewarded from the buy back fund as outlined in the ANN for contributions which is why the code fix is being paid.

Well if that's the policy fair enough.  Might be a good idea to allow additional donations to the fund to ensure there is always enough to pay out. 

I also think it might be useful to reward people separately for pointing out errors and providing fixes. 

This would encourage full transparency as some errors may take time to be fixed but that should not act as a barrier to them being sought out and reported.

+1

Otherwise people might refrain from reporting bugs until they have fixed it on their own - which might take longer than it would take if they reported it at once.
legendary
Activity: 952
Merit: 1000
A single PoS block minting 365 coins is rare with our small supply but obviously we will implement the fix. Changes like this submitted with a fix are rewarded from the buy back fund as outlined in the ANN for contributions which is why the code fix is being paid.

Well if that's the policy fair enough.  Might be a good idea to allow additional donations to the fund to ensure there is always enough to pay out. 

I also think it might be useful to reward people separately for pointing out errors and providing fixes. 

This would encourage full transparency as some errors may take time to be fixed but that should not act as a barrier to them being sought out and reported.
hero member
Activity: 840
Merit: 500
Thank you for the contribution to this. I don't think we have seen a wallet this bug but will submit the change to our repo and have the wallet updates for this.

This is the great community effort to submit a fix to a seen problem in open source code.

DM me your wallet address for some SMAC.



I appreciate the generous offer but I agree with Soul_eater_123 here: At least 50% should go to Julian for spotting the issue - the fix itself is rather simple. Wink

I will DM my address.

Thanks!


Edit:

A single PoS block minting 365 coins is rare with our small supply but obviously we will implement the fix. Changes like this submitted with a fix are rewarded from the buy back fund as outlined in the ANN for contributions which is why the code fix is being paid from my input. Not sure what the SMAC team think and can do as they wish.

Well...no. Wink As soon as you send one transaction with 300 SMAC to your wallet you will create a 300 SMAC stake once these coins mature.

sr. member
Activity: 310
Merit: 250
A single PoS block minting 365 coins is rare with our small supply but obviously we will implement the fix. Changes like this submitted with a fix are rewarded from the buy back fund as outlined in the ANN for contributions which is why the code fix is being paid from my input. Not sure what the SMAC team think and can do as they wish.
legendary
Activity: 952
Merit: 1000
Thank you for the contribution to this. I don't think we have seen a wallet this bug but will submit the change to our repo and have the wallet updates for this.

This is the great community effort to submit a fix to a seen problem in open source code.

DM me your wallet address for some SMAC.


How can there be a buffer overflow? 64 bit integer max val is 9223372036854775807.
Or is there any other function overflowing this stack position? i must writing on the most significant bit hens the negative number.

The result of nCoinAge * nRewardCoinYear for 300 coins is 10950000000000000000 (or higher depending on coinage). Buffer overflow.


Easy fix though:

Code:
#include 
#include

int main(void) {
    // SMAC
    int64_t nDays = 1;
    int64_t nCoins = 300;

    int64_t CENT = 1000000;
    int64_t COIN = 100000000;
    int64_t MAX_MINT_PROOF_OF_STAKE = 1 * CENT ;
    int64_t nRewardCoinYear = 365 * MAX_MINT_PROOF_OF_STAKE; // Month 1 - 365% interest
    int64_t nCoinAge = nDays * nCoins;                                                                               //MODIFIED CODE

    int64_t nSubsidy = nCoinAge * nRewardCoinYear / 365; // SMAC code -                                  MODIFIED CODE

    printf("nSubsidy= %lld\n", nSubsidy);
}

Problem solved.



Those it matter? If the same rule applies to everybody then it really doesn't matter at all, less coins, so value is higher. Maybe less staking but more trading, is that bad? Of course not.

Jesus.  Of course it fucking matters.

Yes, it does. Fixing needed asap.

I think Julian should receive some reward as well as he was the one who initially pointed out the specific issue.  In addition I think a fund to pay out bounties for code errors would be a good idea - it is community minded individuals like JYAP & Wurstglee who help protect those of us like me who don't have the ability or the patience to go through the code.  We should welcome their input and make sure that they are rewarded.  This only serves to improve the code and hence the currency for everyone.
sr. member
Activity: 310
Merit: 250
Thank you for the contribution to this. I don't think we have seen a wallet this bug but will submit the change to our repo and have the wallet updates for this.

This is the great community effort to submit a fix to a seen problem in open source code.

DM me your wallet address for some SMAC.


How can there be a buffer overflow? 64 bit integer max val is 9223372036854775807.
Or is there any other function overflowing this stack position? i must writing on the most significant bit hens the negative number.

The result of nCoinAge * nRewardCoinYear for 300 coins is 10950000000000000000 (or higher depending on coinage). Buffer overflow.


Easy fix though:

Code:
#include 
#include

int main(void) {
    // SMAC
    int64_t nDays = 1;
    int64_t nCoins = 300;

    int64_t CENT = 1000000;
    int64_t COIN = 100000000;
    int64_t MAX_MINT_PROOF_OF_STAKE = 1 * CENT ;
    int64_t nRewardCoinYear = 365 * MAX_MINT_PROOF_OF_STAKE; // Month 1 - 365% interest
    int64_t nCoinAge = nDays * nCoins;                                                                               //MODIFIED CODE

    int64_t nSubsidy = nCoinAge * nRewardCoinYear / 365; // SMAC code -                                  MODIFIED CODE

    printf("nSubsidy= %lld\n", nSubsidy);
}

Problem solved.



Those it matter? If the same rule applies to everybody then it really doesn't matter at all, less coins, so value is higher. Maybe less staking but more trading, is that bad? Of course not.

Jesus.  Of course it fucking matters.

Yes, it does. Fixing needed asap.
hero member
Activity: 840
Merit: 500
I reconsidered.

OH NOES! ABANDON SHIP! DUMP DUMP DUMP! oO

:p
hero member
Activity: 840
Merit: 500
How can there be a buffer overflow? 64 bit integer max val is 9223372036854775807.
Or is there any other function overflowing this stack position? i must writing on the most significant bit hens the negative number.

The result of nCoinAge * nRewardCoinYear for 300 coins is 10950000000000000000 (or higher depending on coinage). Buffer overflow.


Easy fix though:

Code:
#include 
#include

int main(void) {
    // SMAC
    int64_t nDays = 1;
    int64_t nCoins = 300;

    int64_t CENT = 1000000;
    int64_t COIN = 100000000;
    int64_t MAX_MINT_PROOF_OF_STAKE = 1 * CENT ;
    int64_t nRewardCoinYear = 365 * MAX_MINT_PROOF_OF_STAKE; // Month 1 - 365% interest
    int64_t nCoinAge = nDays * nCoins;                                                                               //MODIFIED CODE

    int64_t nSubsidy = nCoinAge * nRewardCoinYear / 365; // SMAC code -                                  MODIFIED CODE

    printf("nSubsidy= %lld\n", nSubsidy);
}

Problem solved.



Those it matter? If the same rule applies to everybody then it really doesn't matter at all, less coins, so value is higher. Maybe less staking but more trading, is that bad? Of course not.

Jesus.  Of course it fucking matters.

Yes, it does. Fixing needed asap.
hero member
Activity: 784
Merit: 1000

Those it matter? If the same rule applies to everybody then it really doesn't matter at all, less coins, so value is higher. Maybe less staking but more trading, is that bad? Of course not.

Jesus.  Of course it fucking matters.

Not everything is the price and the amount of coins (for some could be good, for others can be bad). what really matters is the gap between the promises and the reality, if they fail to deliver, it makes look bad the coin. Anyways, this is not bad if it is already fixed (I really appreciate ppl who can spot they own mistakes and work with the community to solve them).
sr. member
Activity: 299
Merit: 250

Those it matter? If the same rule applies to everybody then it really doesn't matter at all, less coins, so value is higher. Maybe less staking but more trading, is that bad? Of course not.

Jesus.  Of course it fucking matters.
legendary
Activity: 952
Merit: 1000
So anyway, there's a buffer overflow in the Proof of Stake implementation which I've mentioned before but I guess I'm getting ignored. This basically means if you are staking a block of 253 or more coins, you won't receive a full Proof of Stake payout based on 365% interest.

Here's some simulation code based on staking 300 coins.

Code:
#include 
#include

int main(void) {
    // SMAC
    int64_t nDays = 1;
    int64_t nCoins = 300;

    int64_t CENT = 1000000;
    int64_t COIN = 100000000;
    int64_t MAX_MINT_PROOF_OF_STAKE = 1 * CENT;
    int64_t nRewardCoinYear = 365 * MAX_MINT_PROOF_OF_STAKE; // Month 1 - 365% interest
    int64_t nCoinAge = nDays * nCoins * COIN;

    int64_t nSubsidy = nCoinAge * nRewardCoinYear / 365 / COIN; // SMAC code

    printf("nSubsidy= %lld\n", nSubsidy);
}

So that is a buffer overflow.

Result is:
nSubsidy = -205390248

Actual result should be:
nSubsidy = 300000000

Or 3 SMAC.

So if you can find a block which has paid out more than 3 SMAC in Proof of Stake interest during the 365% interest period, you can prove me wrong.  Well to be exact, if you can find a PoS payment of more than 2.53 SMAC during the 365% interest period, you can prove me wrong.

The worst case scenario is for people staking more. I feel bad for those people as their investment isn't fully paying out.  For example with 3000 SMAC, staking for 1 day you should receive 30 SMAC.  For 30000 SMAC, staking for 1 day you should receive 300 SMAC.... So yes, 1% per day since minimum stake age is 1 day.



Thanks for spotting this.  Hopefully this can be sorted out soon.  I'm not too bothered about lower stakes but others might be so it is best to get it corrected.
legendary
Activity: 1120
Merit: 1000
So anyway, there's a buffer overflow in the Proof of Stake implementation which I've mentioned before but I guess I'm getting ignored. This basically means if you are staking a block of 253 or more coins, you won't receive a full Proof of Stake payout based on 365% interest.

Here's some simulation code based on staking 300 coins.

Code:
#include 
#include

int main(void) {
    // SMAC
    int64_t nDays = 1;
    int64_t nCoins = 300;

    int64_t CENT = 1000000;
    int64_t COIN = 100000000;
    int64_t MAX_MINT_PROOF_OF_STAKE = 1 * CENT;
    int64_t nRewardCoinYear = 365 * MAX_MINT_PROOF_OF_STAKE; // Month 1 - 365% interest
    int64_t nCoinAge = nDays * nCoins * COIN;

    int64_t nSubsidy = nCoinAge * nRewardCoinYear / 365 / COIN; // SMAC code

    printf("nSubsidy= %lld\n", nSubsidy);
}

So that is a buffer overflow.

Result is:
nSubsidy = -205390248

Actual result should be:
nSubsidy = 300000000

Or 3 SMAC.

So if you can find a block which has paid out more than 3 SMAC in Proof of Stake interest during the 365% interest period, you can prove me wrong.  Well to be exact, if you can find a PoS payment of more than 2.53 SMAC during the 365% interest period, you can prove me wrong.

The worst case scenario is for people staking more. I feel bad for those people as their investment isn't fully paying out.  For example with 3000 SMAC, staking for 1 day you should receive 30 SMAC.  For 30000 SMAC, staking for 1 day you should receive 300 SMAC.... So yes, 1% per day since minimum stake age is 1 day.


Those it matter? If the same rule applies to everybody then it really doesn't matter at all, less coins, so value is higher. Maybe less staking but more trading, is that bad? Of course not.
sr. member
Activity: 299
Merit: 250
Well, i guess this explains why i just staked a 5000 input and got 2.34947107 coins.
hero member
Activity: 585
Merit: 500
How can there be a buffer overflow? 64 bit integer max val is 9223372036854775807.
Or is there any other function overflowing this stack position? i must writing on the most significant bit hens the negative number.
hero member
Activity: 585
Merit: 500
We will be releasing a newsletter later today.

Looking forward to some great news!
sr. member
Activity: 310
Merit: 250
I have been in touch with a few platforms already. Since we are a new coin, they are hesitant which is understandable so they don't continually add and remove coins. Shapeshift is one we have an eye on and originally spoke to them almost a month ago. Their API is powerful and they are definitely something we want to look at but we do need to build the resources to show that use first.

As our value grows, we will end on more and more platforms. To grow value, the new developments will increase use so not only do we have revenue streams reentering the market but also more of a demand for the coin to expand its reach. The first phase was the investor coin to buy and hold, now we build!


SMAC is on CoinMarketCap so we are expanding =)
http://coinmarketcap.com/currencies/smac/
legendary
Activity: 952
Merit: 1000
Just a couple of points I feel are relevant to SMAC:-

I've used Shapeshift.io (http://shapeshift.io) multiple times and it has worked really well.  Shapeshift is a decentralised/trustless exchange platform.  You pick what cryptocurrency you want to exchange, put in your addresses and the transfer is done as instantly as the relevant blockchains allow.  It's very useful if you're in a hurry and don't want to mess around on regular exchanges/fighting bots etc.  It also allows you to buy in large quantities without it pushing the price around.

Might be a bit premature but it would be great to get SMAC on there.  I've already mentioned it to them on chat and they have said that they are looking at adding more cryptos based on interest.  The more people that request it the higher it should be on their radar.

Also SendChat are looking for alt coins to add to their platform (https://twitter.com/SendChat/status/575182733061808128) - this might be a good fit for SMAC.  Might be an idea to respond to their tweet and let them know as with shapeshift.
sr. member
Activity: 310
Merit: 250
Thanks for the feed back!
hero member
Activity: 585
Merit: 500
I will also confirm that the SMAC staking is working as designed. The only difference why this is less than the 1% is that these coins were not all sent in the same TX so their ages are different. Otherwise, my staking is right about 1% as promised in the original code....


I too can confirm that my staking appears to be working correctly.

I too!
legendary
Activity: 952
Merit: 1000
I will also confirm that the SMAC staking is working as designed. The only difference why this is less than the 1% is that these coins were not all sent in the same TX so their ages are different. Otherwise, my staking is right about 1% as promised in the original code....


I too can confirm that my staking appears to be working correctly.
Pages:
Jump to: