Author

Topic: [ANN][CLAM] CLAMs, Proof-Of-Chain, Proof-Of-Working-Stake, a.k.a. "Clamcoin" - page 283. (Read 1151252 times)

legendary
Activity: 2940
Merit: 1333
Thanks,  dooglus, I was helping FreeHealthCare to deposit a paper wallet and so I pushed the tx through your page and I wanted to be able to tell him, "here ya go: TXID".  I ended up finding it by using a block explorer and looking for his/her deposit address.   Just that that's what prompted the question.  Thanks again for the explanation.  I actually went and asked about how to calculate it in the Technical Discussion board, perhaps someone there can explain why its not coming out the way you expected.

It's because you don't just sha256 it, you sha256 it twice, then reverse the result!

Code:
$ clamd getrawtransaction 512f2e27b233eee9c28ac0f12a653ca1b6e1ef76b8214915d7865dda0b51dfc0 |
    xxd -r -p |              # convert hex to binary
    sha256sum |              # hash it
    xxd -r -p |              # convert hex to binary
    sha256sum |              # hash it
    awk '{print $1}' |       # keep just the hash:    01234567
    rev |                    # reverse it:            76543210
    sed -E 's/(.)(.)/\2\1/g' # switch adjacent bytes: 67452301
512f2e27b233eee9c28ac0f12a653ca1b6e1ef76b8214915d7865dda0b51dfc0

Edit: I learned this from https://en.bitcoin.it/wiki/Dump_format#General_note_about_hashes - and found that page by googling for 9a538906e6466ebd2617d321f71bc94e56056ce213d366773699e28158e00614, which is what Bitcoin gives when you hash a single 00 byte (which is what I got when I serialized an empty string).
legendary
Activity: 1456
Merit: 1081
I may write code in exchange for bitcoins.
Thanks,  dooglus, I was helping FreeHealthCare to deposit a paper wallet and so I pushed the tx through your page and I wanted to be able to tell him, "here ya go: TXID".  I ended up finding it by using a block explorer and looking for his/her deposit address.   Just that that's what prompted the question.  Thanks again for the explanation.  I actually went and asked about how to calculate it in the Technical Discussion board, perhaps someone there can explain why its not coming out the way you expected.
legendary
Activity: 2940
Merit: 1333
Today I used the pushtx page of just-dice to push a raw transaction, I got the message "OK", but it would be nice to have a transaction ID to go along with that.  This is just my request/suggestion in regards this page:

https://just-dice.com/pushtx

If there's another pushtx page elsewhere that can push txs in hex format into the clam network and which gives you back the txid, that'd be great.

Oh, and I guess I can just hash my transaction to get my transaction id?  Is that correct?  Do I use sha256sum or something like that?

I've added the txid to the output. You'll see it when I push the next update to the site.

I thought you could just sha256 hash the tx to get its txid, but it doesn't work:

Code:
$ clamd getrawtransaction 2b90afc1a9b8a82c187aa59dfb5ea1767bc1976fcd9696ef4dda0886ca6771d7 | xxd -r -p | sha256sum
e2410f88b750f1a90c316fdcc6d1bb08e8abafd5ab9f0b34682101c662a6266f  -

I don't know why. I tried reversing the bytes, but that doesn't fix it.

getrawtransaction gets its hex string like this:

Code:
   CDataStream ssTx(SER_NETWORK, PROTOCOL_VERSION);
    ssTx << tx;
    string strHex = HexStr(ssTx.begin(), ssTx.end());

txid's are calculated like this:

Code:
   uint256 GetHash() const
    {
        return SerializeHash(*this);
    }

I would expect them to both end up using the serialization code:

Code:
   IMPLEMENT_SERIALIZE
    (
        READWRITE(this->nVersion);
        nVersion = this->nVersion;
        READWRITE(nTime);
        READWRITE(vin);
        READWRITE(vout);
        READWRITE(nLockTime);
        if (this->nVersion > LEGACY_VERSION_1)
        {
          READWRITE(strCLAMSpeech);
        }
    )

but somehow they get different results. So I don't know.

Edit: I didn't figure out why it doesn't work - it's presumably something to do with the different way that SER_GETHASH and SER_NETWORK serialize transactions - but I did work out an easy way of getting your txid from the hex string. Just "decoderawtransaction" on it, and look at the 2nd line:

Code:
$ clamd decoderawtransaction $(clamd getrawtransaction 2b90afc1a9b8a82c187aa59dfb5ea1767bc1976fcd9696ef4dda0886ca6771d7) | head -2
{
  "txid": "2b90afc1a9b8a82c187aa59dfb5ea1767bc1976fcd9696ef4dda0886ca6771d7",
legendary
Activity: 1456
Merit: 1081
I may write code in exchange for bitcoins.
Today I used the pushtx page of just-dice to push a raw transaction, I got the message "OK", but it would be nice to have a transaction ID to go along with that.  This is just my request/suggestion in regards this page:

https://just-dice.com/pushtx

If there's another pushtx page elsewhere that can push txs in hex format into the clam network and which gives you back the txid, that'd be great.

Oh, and I guess I can just hash my transaction to get my transaction id?  Is that correct?  Do I use sha256sum or something like that?
legendary
Activity: 2968
Merit: 1198
I don't see how the long term outlook can be bullish.  This is essentially a gambling coin that stakes, so basically giving out more coins that there is nothing to do with but gamble.  Gamblers that lose will buy more gamblers that win will sell but the supply keeps increasing so the price has to go down.

This coin really has some interesting economic properties:

1. As the price goes up more people will be motivated to claim their "free" claims (I doubt it is a coincidence that the "whale" showed up after the huge price rise of the past year or so). When the price goes down, people won't bother. That gives it a supply curve more like a physical commodity like gold than Bitcoin.  In turn that should tend to make the price less volatile and a better store of value.

2. Staking inflation is high (about 4% per month currently, but that declines as the supply increases) but if you stake your coins you do even better than that because not everyone stakes.

I don't know where this coin is going to end up. At the moment it looks pretty bleak, but it's an interesting experiment in any case.
hero member
Activity: 763
Merit: 500
I don't see how the long term outlook can be bullish.  This is essentially a gambling coin that stakes, so basically giving out more coins that there is nothing to do with but gamble.  Gamblers that lose will buy more gamblers that win will sell but the supply keeps increasing so the price has to go down.
legendary
Activity: 2968
Merit: 1198
I have aprox 120 CLAM thay I broght. And im loooosing and looosing money.
Does anyone have an investor tip? Should I stake? Deposit in justdice?
Thanx.

You should stake, invest in JD (which stakes for you) or sell. It doesn't make sense to hold CLAMs without staking because that's a very significant part of the return on investment. If you are just short term speculating it doesn't really matter but if you hold for a while the lost income from not staking adds up.

If you don't want to stake yourself or invest in JD you can join my no-nonsense no-fee staking pool: https://bitcointalksearch.org/topic/no-nonsense-clam-staking-pool-1200703
full member
Activity: 145
Merit: 110
I have aprox 120 CLAM thay I broght. And im loooosing and looosing money.
Does anyone have an investor tip? Should I stake? Deposit in justdice?
Thanx.
legendary
Activity: 1652
Merit: 1007
DMD Diamond Making Money 4+ years! Join us!
CLAMS to the moon? Smiley)))))))

0,004 it s a moon Really?
there are no statistics on digging?
 obviously someone found a lot of cщккyce addresses and began selling coins =)

Its all about patience. Diff will go up and compensate this, the price ll get back to higher levels. Professional investors have one very important trait, they have almost endless patience.
legendary
Activity: 1512
Merit: 1125
Swapzone
CLAMS to the moon? Smiley)))))))

0,004 it s a moon Really?
there are no statistics on digging?
 obviously someone found a lot of cщккyce addresses and began selling coins =)
sr. member
Activity: 344
Merit: 250
CCMINER.NET
Hi
I would like to know if there is the possibility that something is wrong with me clams wallet.
It is sync and connected to the network, it shows 3 days for mining a block since 2 weeks Huh Huh
Is it normal or maybe I have to fix something?
Thanks

   The 3 days is an estimate.  How many clams are you trying to stake?  We can give you a better real world estimate... 
147.65
legendary
Activity: 1007
Merit: 1000
Hi
I would like to know if there is the possibility that something is wrong with me clams wallet.
It is sync and connected to the network, it shows 3 days for mining a block since 2 weeks Huh Huh
Is it normal or maybe I have to fix something?
Thanks

   The 3 days is an estimate.  How many clams are you trying to stake?  We can give you a better real world estimate... 
sr. member
Activity: 344
Merit: 250
CCMINER.NET
Hi
I would like to know if there is the possibility that something is wrong with me clams wallet.
It is sync and connected to the network, it shows 3 days for mining a block since 2 weeks Huh Huh
Is it normal or maybe I have to fix something?
Thanks
legendary
Activity: 1358
Merit: 1003
Designer - Developer
KINGKLYE.com now accepts CLAM on site!

Just letting everyone know I have gotten http://kingklye.com up and running now and you can pay with CLAM!

All merchandise is fully endorsed by the CLAM developers and I'm very excited to offer the first shop to buy physical items for CLAM directly!
Go grab yourself a few shirts or a mug! Free shipping on your order (in 98%) of cases, I will let you know otherwise of course.

So far almost a dozen items have been purchased and received from the site with a 100% arrival rate, Don't let the negative rep scare you.
I'm sure the CLAM developers will vouch that they received their order as well as anyone else who has ordered from me.

legendary
Activity: 2940
Merit: 1333
According to https://multibit.org/en/help/v0.5/help_importingPrivateKeys.html

Quote
6. After the import, MultiBit then replays the block chain from the replay date to find the transactions for the new private keys. It is best just to leave MultiBit to sync the block chain on its own.

The replay date being a date you give it. I believe it would update the bloom filters and replay the blockchain from the date you gave it grabbing associated transactions.

That sounds expensive in terms of node I/O. The Bitcoin node needs to rescan the whole blockchain (if the date you give it is old enough) looking for transactions relating to the address you give it. Is it possible to DoS a node in that way? It seems like you're getting the node to do a whole lot of work by sending it a very simple request.
sr. member
Activity: 304
Merit: 252
CLAM Dev
How does MultiBit deal with importing private keys and rescanning? As I understand it, Bitcoin Core doesn't maintain an address index and so has to rescan the whole blockchain when you add a new private key to the wallet, which is time intensive. If MultiBit is talking to regular Core peers, how do they look up the transactions of interest given only the addresses that the MultiBit wallet controls?

MultiBit classic retrieves the whole chain (after an optional earliest use date) after installing a BIP0037 filter which allows excluding most "uninteresting" transactions. It is still pretty time intensive.

Multibit HD does not support importing Bitcoin Core wallets. It may allow importing individual keys but I'm not sure. Mostly it uses HD wallets where a single seed generates many private keys. Either way the restore process is largely the same, involving scanning of the blockchain. HD or not HD makes no difference to the actual blocks.


According to https://multibit.org/en/help/v0.5/help_importingPrivateKeys.html

Quote
6. After the import, MultiBit then replays the block chain from the replay date to find the transactions for the new private keys. It is best just to leave MultiBit to sync the block chain on its own.

The replay date being a date you give it. I believe it would update the bloom filters and replay the blockchain from the date you gave it grabbing associated transactions.

legendary
Activity: 2968
Merit: 1198
How does MultiBit deal with importing private keys and rescanning? As I understand it, Bitcoin Core doesn't maintain an address index and so has to rescan the whole blockchain when you add a new private key to the wallet, which is time intensive. If MultiBit is talking to regular Core peers, how do they look up the transactions of interest given only the addresses that the MultiBit wallet controls?

MultiBit classic retrieves the whole chain (after an optional earliest use date) after installing a BIP0037 filter which allows excluding most "uninteresting" transactions. It is still pretty time intensive.

Multibit HD does not support importing Bitcoin Core wallets. It may allow importing individual keys but I'm not sure. Mostly it uses HD wallets where a single seed generates many private keys. Either way the restore process is largely the same, involving scanning of the blockchain. HD or not HD makes no difference to the actual blocks.




legendary
Activity: 1806
Merit: 1090
Learning the troll avoidance button :)
Well it is a stake so  it will recover over time perhaps
That said its taking a beating at present.
full member
Activity: 163
Merit: 100
I have been pouring over charts this past week and last night I decided to see if the digging commencement coincided with anything else.  My first thought was maybe Ethereum but the volume and price movements don't seem highly correlated.  The best one I could find was the BTC flash crash on August 18.  Losing 1/3 of his wealth right there could have lead the digger to salvage what he can.  Also, Clam was the last alt standing after the late spring and early summer rally that peaked in July.  Clams peaked in August so if he holds other alts then he could be selling clams to buy into BTS or ETH and so forth.
legendary
Activity: 1526
Merit: 1000
the grandpa of cryptos
CLAMS to the moon? Smiley)))))))
Jump to: