0 Members and 1 Guest are viewing this topic.
Is this still active?
Quote from: bytemaster on February 25, 2014, 04:23:17 amA transaction need not have the proper hash to be included..., but if it does have the proper hash then the coindays destroyed count toward the block.you want it to calculate coindays destroyed per transaction and use that to factor in as stake?so if a tx destroys 1000 coin days, the PoW block gets an extra small % in coin representing the TaPoS?
A transaction need not have the proper hash to be included..., but if it does have the proper hash then the coindays destroyed count toward the block.
Quote from: barwizi on February 24, 2014, 09:17:33 pmI've added block height into transactions, but now i need to figure out how to make a check for it. Not the block height... the hash of the prior block.
I've added block height into transactions, but now i need to figure out how to make a check for it.
// TaPOS check if tx has correct block number if (block.hash != (pblock->hashPrevBlock)) return state.DoS(10, error("CTransaction::CheckTransaction() : TaPoS failed"));
Quote from: toast on February 24, 2014, 02:39:26 pmI think you should be able to get the bounty with just signature POW. Was the TAPOS requirement added while the bounty was in [PENDING] or [ACTIVE]?[ACTIVE] but i find the TaPOS quite intriguing, i'll see what he says.
I think you should be able to get the bounty with just signature POW. Was the TAPOS requirement added while the bounty was in [PENDING] or [ACTIVE]?
Quote from: barwizi on February 23, 2014, 10:31:18 amDo you still need this?It should use TaPOS rather than Signature... but yes, this would be nice.
Do you still need this?
The concept of Poof-of-Stake
Quote from: barwizi on February 12, 2014, 01:43:53 pmQuote from: bytemaster on February 11, 2014, 04:36:37 pmQuote from: barwizi on February 11, 2014, 04:15:08 pmaltough unrelated, i now have a functional PTS PoS coin. i now have time to pay attention to Bounties again.Nice... details?check your inboxthe basics, are it uses the BTS PTS version of momentum. It's already complete and has been tested a few times now. I just finished writing the instructions for modifying it both basic and advanced. It can be used for BTS initiatives as is since it includes a custom license that tries to mimic the draft SCSL. So its PoSMomentumHighly customize-ableEasy to modify and deploy. Now it just needs a valid use.Very interesting... but it looks like it is using POW to decide the longest chain?
Quote from: bytemaster on February 11, 2014, 04:36:37 pmQuote from: barwizi on February 11, 2014, 04:15:08 pmaltough unrelated, i now have a functional PTS PoS coin. i now have time to pay attention to Bounties again.Nice... details?check your inboxthe basics, are it uses the BTS PTS version of momentum. It's already complete and has been tested a few times now. I just finished writing the instructions for modifying it both basic and advanced. It can be used for BTS initiatives as is since it includes a custom license that tries to mimic the draft SCSL. So its PoSMomentumHighly customize-ableEasy to modify and deploy. Now it just needs a valid use.
Quote from: barwizi on February 11, 2014, 04:15:08 pmaltough unrelated, i now have a functional PTS PoS coin. i now have time to pay attention to Bounties again.Nice... details?
altough unrelated, i now have a functional PTS PoS coin. i now have time to pay attention to Bounties again.
Quote from: barwizi on January 20, 2014, 12:59:35 pmperhaps you can weigh in bytemaster, should i change ?QuotePlease use the same curve at bitcoin so all private/public keys in my libs are compatible.
perhaps you can weigh in bytemaster, should i change ?
Please use the same curve at bitcoin so all private/public keys in my libs are compatible.
Quote from: barwizi on January 15, 2014, 01:47:55 pmive gone ahead with secp256r1 32, the library is now in the src folder, it has these functions of interest int ecc_make_key( uint8_t p_publicKey[ECC_BYTES+1], uint8_t p_privateKey[ECC_BYTES]);that creates a public/private key pair int ecdsa_sign( const uint8_t p_privateKey[ECC_BYTES], const uint8_t p_hash[ECC_BYTES], uint8_t p_signature[ECC_BYTES*2]);Generates an ECDSA signature for a given hash value.int ecdsa_verify( const uint8_t p_publicKey[ECC_BYTES+1], const uint8_t p_hash[ECC_BYTES], const uint8_t p_signature[ECC_BYTES*2]);Verifies an ECDSA signature.credit goes to kmackay for this. if anyone has an idea how to replace the nonce as required, just fork this repository https://github.com/Nameshar/Divssharesand get to it. I'll be trying to figure it out as well but i'd appreciate a hand.Why secp256r1 instead of secp256k1 as used in Bitcoin? There are concerns that secp256r1 was intentionally weakened by the NSA: https://bitcointalk.org/index.php?topic=151120.0
ive gone ahead with secp256r1 32, the library is now in the src folder, it has these functions of interest int ecc_make_key( uint8_t p_publicKey[ECC_BYTES+1], uint8_t p_privateKey[ECC_BYTES]);that creates a public/private key pair int ecdsa_sign( const uint8_t p_privateKey[ECC_BYTES], const uint8_t p_hash[ECC_BYTES], uint8_t p_signature[ECC_BYTES*2]);Generates an ECDSA signature for a given hash value.int ecdsa_verify( const uint8_t p_publicKey[ECC_BYTES+1], const uint8_t p_hash[ECC_BYTES], const uint8_t p_signature[ECC_BYTES*2]);Verifies an ECDSA signature.credit goes to kmackay for this. if anyone has an idea how to replace the nonce as required, just fork this repository https://github.com/Nameshar/Divssharesand get to it. I'll be trying to figure it out as well but i'd appreciate a hand.
Here is verificationhttps://github.com/Nameshar/Divsshares/blob/master/src/main.cpp#L2047Replace the place it calls CheckProofOfWork with a call to a custom CheckProofOfMasterSignature, which needs to access the master signature on a blockhttps://github.com/Nameshar/Divsshares/blob/master/src/main.h#L836^ I recommend we add a new field of the right type rather than changing the nonce's type and setting it there, that lets us touch less code.Creating a block:https://github.com/Nameshar/Divsshares/blob/master/src/main.cpp#L3992In the non-PoS case "mining" is just waiting until a new signature has been approved, we should let it try to mine so it builds up a valid block in the processThe interface for creating a master-signed block might be the longest part of this step. How about an rpc call which asks for the key, which will immediately publish whatever block the client is "mining" at that moment?
only one mining machine, lol centralization!!! ok, i''l see what i can do.
I am increasing the bounty on this to 1500 PTS.
Tell me more about the Signature PoW that you want.
Quote from: barwizi on January 01, 2014, 12:07:29 amIn order to appease both sides, why not display both the actual money supply and the number of coins? I am having difficulty wrapping my head around buying something for X%.You will not have to think in terms of X% you will just see X BTS... from the user's perspective it is just a number. The only place shares matter is under the hood, but that is an implementation detail.
In order to appease both sides, why not display both the actual money supply and the number of coins? I am having difficulty wrapping my head around buying something for X%.
Quote from: bytemaster on December 31, 2013, 11:43:46 pmAdded one little detail: Unspent outputs after 1 year expire and thus can be pruned because they cannot be spent, this forces people to spend their money once per year (Proof of Stake, and keeps the blockchain size to a maximum size).Ok, would that be a literal year or coin year?
Added one little detail: Unspent outputs after 1 year expire and thus can be pruned because they cannot be spent, this forces people to spend their money once per year (Proof of Stake, and keeps the blockchain size to a maximum size).
int64 GetAccountBalance(CWalletDB& walletdb, const string& strAccount, int nMinDepth){ int64 nBalance = 0; // Tally wallet transactions for (map<uint256, CWalletTx>::iterator it = pwalletMain->mapWallet.begin(); it != pwalletMain->mapWallet.end(); ++it) { const CWalletTx& wtx = (*it).second; if (!wtx.IsFinal()) continue; int64 nGenerated, nReceived, nSent, nFee; wtx.GetAccountAmounts(strAccount, nGenerated, nReceived, nSent, nFee); if (nReceived != 0 && wtx.GetDepthInMainChain() >= nMinDepth) nBalance += nReceived; nBalance += nGenerated - nSent - nFee; } // Tally internal accounting entries nBalance += walletdb.GetAccountCreditDebit(strAccount); return nBalance;}int64 GetAccountBalance(const string& strAccount, int nMinDepth){ CWalletDB walletdb(pwalletMain->strWalletFile); return GetAccountBalance(walletdb, strAccount, nMinDepth);}Value getbalance(const Array& params, bool fHelp){ if (fHelp || params.size() > 2) throw runtime_error( "getbalance [account] [minconf=1]\n" "If [account] is not specified, returns the server's total available balance.\n" "If [account] is specified, returns the balance in the account."); if (params.size() == 0) return ValueFromAmount(pwalletMain->GetBalance()); int nMinDepth = 1; if (params.size() > 1) nMinDepth = params[1].get_int(); if (params[0].get_str() == "*") { // Calculate total balance a different way from GetBalance() // (GetBalance() sums up all unspent TxOuts) // getbalance and getbalance '*' should always return the same number. int64 nBalance = 0; for (map<uint256, CWalletTx>::iterator it = pwalletMain->mapWallet.begin(); it != pwalletMain->mapWallet.end(); ++it) { const CWalletTx& wtx = (*it).second; if (!wtx.IsFinal()) continue; int64 allGeneratedImmature, allGeneratedMature, allFee; allGeneratedImmature = allGeneratedMature = allFee = 0; string strSentAccount; list<pair<CTxDestination, int64> > listReceived; list<pair<CTxDestination, int64> > listSent; wtx.GetAmounts(allGeneratedImmature, allGeneratedMature, listReceived, listSent, allFee, strSentAccount); if (wtx.GetDepthInMainChain() >= nMinDepth) { BOOST_FOREACH(const PAIRTYPE(CTxDestination,int64)& r, listReceived) nBalance += r.second; } BOOST_FOREACH(const PAIRTYPE(CTxDestination,int64)& r, listSent) nBalance -= r.second; nBalance -= allFee; nBalance += allGeneratedMature; } return ValueFromAmount(nBalance); } string strAccount = AccountFromValue(params[0]); int64 nBalance = GetAccountBalance(strAccount, nMinDepth); return ValueFromAmount(nBalance);}
Update the readme so we know what's done and what is left to do