Author

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

full member
Activity: 132
Merit: 100
willmathforcrypto.com
Clam trading is "unavailable" on shapeshift.io at the moment. It's probably a good thing for me since I'm not sure I have the willpower to resist selling a few after the price spike of about 20% in the past hour. But I thought I'd point it out in case it's an issue shapeshift isn't aware of.

@Clam experts: What's the leading byte for clam p2sh addresses supposed to be? x05 or x0d?


x0d is the correct one to use now. It was originally x05 but there was a situation where an old just-dice user sent clams to a multisig btc address, so to avoid any future conflicts it was changed so the leading identifier was 6 when converted to base58.

I will look into the other multisig question for you tomorrow, just on my way to sleep.

Thanks!
legendary
Activity: 2940
Merit: 1333
EDIT: I re-pasted and now it says "OK".  It's a little strange because I was using the same rawtransaction data sitting there in the terminal window.

I don't do any kind of logging of pushed raw transactions, so I can't check the logs to see what went wrong. I'm glad it worked out for you eventually though.

Edit: since the data is intended to be publicly broadcast I don't see any harm in logging it. So I'll do that going forward. That should help to debug this issue if it happens again.
legendary
Activity: 1456
Merit: 1081
I may write code in exchange for bitcoins.
Heya Doog, I gave this a try tonight and I ended up getting the message from the just-dice.com/pushtx page "transaction rejected".  This made me wonderi if I gave the private key in the wrong format.  I was using wallet import format (key starts with a 5), is that right?

When you run the big long command, you should get back something like:

Quote
{
    "hex" : "0200[...]3433",
    "complete" : true
}

If you see "false" instead of "true", it means it wasn't able to find all the private keys it needed, which in your case should just be one of them.

The private key is meant to be in WIF, starting with a 5 for BTC keys. It will also accept the corresponding CLAM, LTC, or DOGE private keys in the same format.

So that's the first thing: did you see "compete" as true or false? If false, you're giving a valid private key, but the wrong one. If true, you're likely copy/pasting incorrectly. You need to copy just the hex value, without the quotes.

Thanks for the debugging suggestion, I see "true".  I'm quite confident about the validity of my private key as well.  However, I'l go back and double-check all the steps.

EDIT: I re-pasted and now it says "OK".  It's a little strange because I was using the same rawtransaction data sitting there in the terminal window.  I had double-checked the quotes before I posted, who knows?  Something must have been different.  In any case, I'm sure I'l see the balance show up in my JD account shortly.  Thanks again for making the tool to produce the raw transaction so easily.
sr. member
Activity: 304
Merit: 252
CLAM Dev

@Clam experts: What's the leading byte for clam p2sh addresses supposed to be? x05 or x0d?


x0d is the correct one to use now. It was originally x05 but there was a situation where an old just-dice user sent clams to a multisig btc address, so to avoid any future conflicts it was changed so the leading identifier was 6 when converted to base58.

I will look into the other multisig question for you tomorrow, just on my way to sleep.

legendary
Activity: 2940
Merit: 1333
Heya Doog, I gave this a try tonight and I ended up getting the message from the just-dice.com/pushtx page "transaction rejected".  This made me wonderi if I gave the private key in the wrong format.  I was using wallet import format (key starts with a 5), is that right?

When you run the big long command, you should get back something like:

Quote
{
    "hex" : "0200[...]3433",
    "complete" : true
}

If you see "false" instead of "true", it means it wasn't able to find all the private keys it needed, which in your case should just be one of them.

The private key is meant to be in WIF, starting with a 5 for BTC keys. It will also accept the corresponding CLAM, LTC, or DOGE private keys in the same format.

So that's the first thing: did you see "compete" as true or false? If false, you're giving a valid private key, but the wrong one. If true, you're likely copy/pasting incorrectly. You need to copy just the hex value, without the quotes.
legendary
Activity: 1456
Merit: 1081
I may write code in exchange for bitcoins.
Well the why not is that it's an address I was using for cold-storage and since I don't want to keep my savings in an address that I've given away the private key for then I'd have to first move the coins that are there.  I'd do it if CLAM is high, but not worth the trouble if CLAM is low.  But hey, I thought all the addys that were funded were funded at the 4.6 level.  What other level is there?

There's only the 4.6 level. I guess he means if it's only one address maybe it's not worth it, but if it's 100 addresses it is...

You don't have to give away the private key. I recently added a command to Just-Dice that will allow you to 'dig' your CLAM by signing a transaction on an offline machine.

For example, if I type this in the chat box:

Quote
/dig 1CrPRwBkwZdEejXusCbh8o35YMN7g7ffKf offline

It tells me:

Quote
00:21:40 INFO: run the following on an offline Linux machine, then broadcast the resulting hex value using https://just-dice.com/pushtx
00:21:41 INFO: the addr= part tells it where to send your CLAMs; the default is your Just-Dice deposit address
00:21:41 INFO: when prompted, type your private key:
00:21:41 INFO: echo -n "privkey: "; read privkey; addr=xMYvd61airRrnSUmV2oE1JhEqvzLdFWP7r; val=4.60535574; txid=b45c2a20731f8a88ba980f9cc9ce1d43cd7913d9c26ee3e8002ba1d08676b3de; vout=0; pubkey=76a91482007d41eec3a28b66b1ba726721d95577eb5a7688ac; output='"txid":"'$txid'","vout":'$vout; clamd signrawtransaction $(clamd createrawtransaction '[{'$output'}]' '{"'$addr'":'$val'}') '[{'$output',"scriptPubKey":"'$pubkey'"}]' '["'$privkey'"]'

ie. it gives me a command that I can run on an offline machine that will sign a transaction that (when broadcast) sends the dug up CLAMs to an address of my choosing.

For more information, see this post that I made when I first implemented the command.

Heya Doog, I gave this a try tonight and I ended up getting the message from the just-dice.com/pushtx page "transaction rejected".  This made me wonderi if I gave the private key in the wrong format.  I was using wallet import format (key starts with a 5), is that right?
hero member
Activity: 756
Merit: 500
P2Pool would also probably not work well with Bitcoin if a majority of the Bitcoin network was using it.
legendary
Activity: 2940
Merit: 1333
I guess p2pool would improve things, as follows:

Currently if you are staking 10 CLAMs, you can expect to stake 1 CLAM every 50 days or so. If there are 100 people staking 10 CLAMs each, they each get that same very irregular reward for staking.

With p2pool, those 100 people can expect to get the same return, but with much lower variance. They each get to stake 0.01 CLAM about twice per day. Their expectation is the same (still 14% lost due to orphans) but their income is much steadier.

Thinking about it more, p2pool works by making shares much easier to find than real blocks. 1000 times easier, say. That way, the guy who currently expects to stake a real block over every 10 days gets to contribute a share 100 times per day, or once every 15 minutes.

But there's a problem with that. If JD stops solo-staking and joins the p2pool network, that's almost all the network weight that will be on p2pool. That means p2pool will be staking about once per minute, and so its members will be contributing 1000 shares per minute. Thos shares need to be added to the share chain. So we have a distributed blockchain adding 16 blocks per second. And we thought the orphan rate was bad now!

So that doesn't work. What can we do to fix it?

Do we make the '1000' vary per miner? So JD still only submits full block solves, bitdice works on shares that are 10 times easier than standard, and the little solo-staking guy works on shares that are 1000 times easier? But isn't there a problem there too? If bitdice is only going to submit shares which are 10 times easier than a full block, surely it will get 100 times as much 'credit' for each share as the small solo miner does for each 1000x easier share he submits. Because their shares are 100 times harder. But what is to stop bitdice from selling their too-easy-to-publish shares to the little guy for him to publish on the share-chain and get credit for? This is probably something that has come up with the Bitcoin p2pool already. I've not been able to find anything very in-depth written about how p2pool works however.

Maybe p2pool only works well for Bitcoin because 1) the blockchain targets 10 minute blocks and 2) not a very large percentage of the hashrate is using it. With CLAM we have neither of these - the blocks are very fast already, and JD would want to use it.
legendary
Activity: 2940
Merit: 1333
Although you can include multiple inputs to the coinstake transaction, only one of them is part of the proofhash (the others are just along for the ride) and with a fixed reward of 1 clam including more inputs to the coinstake transaction would just reduce the return on investment, seeing as it does not alter the proofhash, thus it would actually be detrimental to your returns rather than creating more value. If you were in fact able to change your proofhash based on how many inputs you include this would be a significant security risk because it will allow stake grinding and computation attacks.

Right. The only reason I can see for including extra inputs is if you have a bunch of dust outputs and want to combine them. The CLAM client will do this automatically for outputs at the same address that is currently staking, but the protocol will even allow you to combine outputs from different addresses if you want to. I'm guessing the client doesn't do this because it can cause confusion in the accounting system.

Also is the the type of chart that you clammers are looking for?

Yes, that looks perfect.
legendary
Activity: 4004
Merit: 1250
Owner at AltQuick.com
I also find your site impressive.

On the pages for transactions, you could include the "clamSpeech" part. Both my test transactions involving multisig included clamSpeech saying they were tests:

http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=21db92347e153a6afdddca7f96d444d81d7daa19674ed3101e50de72cb387b19
http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=92306e09cafe1bb860572047a019cdf4d6136e8e4c7e89fc07be51ded5de9c2a

About multisig addresses, the good news is that you do properly display the transactions (khashier doesn't at the moment). Both the transactions above are listed at:

http://www.presstab.pw/phpexplorer/CLAM/address.php?address=3J5fBSKLSGfPnkY4kVNTp9pMmGx6soN1ek

By the way, in my clam client the multisig address is showing as 6WnV4Jhe7iNQLDekwr31h9zeoK1eaDMjAw. It's the same 20 byte address, so it's not a problem. The difference seems to be whether the leading byte is x05 or x0d.

@Clam experts: What's the leading byte for clam p2sh addresses supposed to be? x05 or x0d?


I will start adding more CLAM specific things (such as speech display) and the chart I screen shotted above, once my site is linked to from the OP and the website and such in the explorers sections.

I'lll ring a phone and get you on Clamcoin.org.  Tongue

Do you happen to have a little banner or anything?

Yep, retro style


I'll be throwing the updates on my server tonight hopefully. Thanks for you quick response bayareacoins

It will be added next update.

There will also be a new Gaming section under the services.
legendary
Activity: 1330
Merit: 1000
Blockchain Developer
I also find your site impressive.

On the pages for transactions, you could include the "clamSpeech" part. Both my test transactions involving multisig included clamSpeech saying they were tests:

http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=21db92347e153a6afdddca7f96d444d81d7daa19674ed3101e50de72cb387b19
http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=92306e09cafe1bb860572047a019cdf4d6136e8e4c7e89fc07be51ded5de9c2a

About multisig addresses, the good news is that you do properly display the transactions (khashier doesn't at the moment). Both the transactions above are listed at:

http://www.presstab.pw/phpexplorer/CLAM/address.php?address=3J5fBSKLSGfPnkY4kVNTp9pMmGx6soN1ek

By the way, in my clam client the multisig address is showing as 6WnV4Jhe7iNQLDekwr31h9zeoK1eaDMjAw. It's the same 20 byte address, so it's not a problem. The difference seems to be whether the leading byte is x05 or x0d.

@Clam experts: What's the leading byte for clam p2sh addresses supposed to be? x05 or x0d?


I will start adding more CLAM specific things (such as speech display) and the chart I screen shotted above, once my site is linked to from the OP and the website and such in the explorers sections.

I'lll ring a phone and get you on Clamcoin.org.  Tongue

Do you happen to have a little banner or anything?

Yep, retro style


I'll be throwing the updates on my server tonight hopefully. Thanks for you quick response bayareacoins
legendary
Activity: 4004
Merit: 1250
Owner at AltQuick.com
I also find your site impressive.

On the pages for transactions, you could include the "clamSpeech" part. Both my test transactions involving multisig included clamSpeech saying they were tests:

http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=21db92347e153a6afdddca7f96d444d81d7daa19674ed3101e50de72cb387b19
http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=92306e09cafe1bb860572047a019cdf4d6136e8e4c7e89fc07be51ded5de9c2a

About multisig addresses, the good news is that you do properly display the transactions (khashier doesn't at the moment). Both the transactions above are listed at:

http://www.presstab.pw/phpexplorer/CLAM/address.php?address=3J5fBSKLSGfPnkY4kVNTp9pMmGx6soN1ek

By the way, in my clam client the multisig address is showing as 6WnV4Jhe7iNQLDekwr31h9zeoK1eaDMjAw. It's the same 20 byte address, so it's not a problem. The difference seems to be whether the leading byte is x05 or x0d.

@Clam experts: What's the leading byte for clam p2sh addresses supposed to be? x05 or x0d?


I will start adding more CLAM specific things (such as speech display) and the chart I screen shotted above, once my site is linked to from the OP and the website and such in the explorers sections.

I'lll ring a phone and get you on Clamcoin.org.  Tongue

Do you happen to have a little banner or anything?
legendary
Activity: 1330
Merit: 1000
Blockchain Developer
I also find your site impressive.

On the pages for transactions, you could include the "clamSpeech" part. Both my test transactions involving multisig included clamSpeech saying they were tests:

http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=21db92347e153a6afdddca7f96d444d81d7daa19674ed3101e50de72cb387b19
http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=92306e09cafe1bb860572047a019cdf4d6136e8e4c7e89fc07be51ded5de9c2a

About multisig addresses, the good news is that you do properly display the transactions (khashier doesn't at the moment). Both the transactions above are listed at:

http://www.presstab.pw/phpexplorer/CLAM/address.php?address=3J5fBSKLSGfPnkY4kVNTp9pMmGx6soN1ek

By the way, in my clam client the multisig address is showing as 6WnV4Jhe7iNQLDekwr31h9zeoK1eaDMjAw. It's the same 20 byte address, so it's not a problem. The difference seems to be whether the leading byte is x05 or x0d.

@Clam experts: What's the leading byte for clam p2sh addresses supposed to be? x05 or x0d?


I will start adding more CLAM specific things (such as speech display) and the chart I screen shotted above, once my site is linked to from the OP and the website and such in the explorers sections.
full member
Activity: 132
Merit: 100
willmathforcrypto.com
I added CLAM to my explorer/PoS analyzing site. clam.presstab.pw (once it propogates) or http://www.presstab.pw/phpexplorer/CLAM/

Let me know any feedback. Took some custimization to get clams working Cheesy

I also find your site impressive.

On the pages for transactions, you could include the "clamSpeech" part. Both my test transactions involving multisig included clamSpeech saying they were tests:

http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=21db92347e153a6afdddca7f96d444d81d7daa19674ed3101e50de72cb387b19
http://www.presstab.pw/phpexplorer/CLAM/tx.php?tx=92306e09cafe1bb860572047a019cdf4d6136e8e4c7e89fc07be51ded5de9c2a

About multisig addresses, the good news is that you do properly display the transactions (khashier doesn't at the moment). Both the transactions above are listed at:

http://www.presstab.pw/phpexplorer/CLAM/address.php?address=3J5fBSKLSGfPnkY4kVNTp9pMmGx6soN1ek

By the way, in my clam client the multisig address is showing as 6WnV4Jhe7iNQLDekwr31h9zeoK1eaDMjAw. It's the same 20 byte address, so it's not a problem. The difference seems to be whether the leading byte is x05 or x0d.

@Clam experts: What's the leading byte for clam p2sh addresses supposed to be? x05 or x0d?
legendary
Activity: 1330
Merit: 1000
Blockchain Developer
One thing that seriously has me bothered is the address that is sending outputs on coinstake transactions... I will need to perhaps reindex my db to deal with that.

I forgot to address that.

I created those weird staking transactions yesterday as an experiment.

There has been talk recently of porting Bitcoin's p2pool distributed staking pool code to CLAMs. p2pool pays its miners directly in the coinbase transaction, and I was wondering if that was even possible with CLAM. I was aware that there was some kind of check in place to make sure that the input and output were for the same address. It turns out that it's only checking the first (actually second, since the first is always zero) output's address, and so we are free to add extra outputs to pay other miners their reward.

So you won't find too many of those weird transactions in the blockchain so far, but if p2pool ever happens for CLAM you can expect to see lots of them.

I was intending to experiment with multiple input sources in staking transactions too, but didn't do that yet.

Edit: OK, so I tried it and it worked. You can have multiple inputs from different addresses, and multiple outputs to different addresses, just so long as the first input address is the same as the first output address:

http://khashier.com/tx/2d621c452eef8f3f8e260f949488ff015007303d2c04669f619c11a0a766d172

We had quite a lengthy conversation about this on the clams irc channel. I don't believe it quite makes sense, although if you think it does maybe I am missing part of it. Although you can include multiple inputs to the coinstake transaction, only one of them is part of the proofhash (the others are just along for the ride) and with a fixed reward of 1 clam including more inputs to the coinstake transaction would just reduce the return on investment, seeing as it does not alter the proofhash, thus it would actually be detrimental to your returns rather than creating more value. If you were in fact able to change your proofhash based on how many inputs you include this would be a significant security risk because it will allow stake grinding and computation attacks.

Also is the the type of chart that you clammers are looking for? I can also add 'total supply' on the y2 axis, but its boring and makes it sort of ugly.
legendary
Activity: 2940
Merit: 1333
One thing that seriously has me bothered is the address that is sending outputs on coinstake transactions... I will need to perhaps reindex my db to deal with that.

I forgot to address that.

I created those weird staking transactions yesterday as an experiment.

There has been talk recently of porting Bitcoin's p2pool distributed staking pool code to CLAMs. p2pool pays its miners directly in the coinbase transaction, and I was wondering if that was even possible with CLAM. I was aware that there was some kind of check in place to make sure that the input and output were for the same address. It turns out that it's only checking the first (actually second, since the first is always zero) output's address, and so we are free to add extra outputs to pay other miners their reward.

So you won't find too many of those weird transactions in the blockchain so far, but if p2pool ever happens for CLAM you can expect to see lots of them.

I was intending to experiment with multiple input sources in staking transactions too, but didn't do that yet.

Edit: OK, so I tried it and it worked. You can have multiple inputs from different addresses, and multiple outputs to different addresses, just so long as the first input address is the same as the first output address:

http://khashier.com/tx/2d621c452eef8f3f8e260f949488ff015007303d2c04669f619c11a0a766d172
legendary
Activity: 2254
Merit: 1290
Believe it or not; that post was a compliment.

I restrained an impulse to post a one-liner of my spontaneous applause but now that you bring it up explicitly, I can agree that it's a gem of a post.

Cheers

Graham
legendary
Activity: 1512
Merit: 1057
SpacePirate.io

I would be very careful with that service. I only just heard of it, but some things just don't add up.

Pretty sure this is nothing but a scam.

The private registration doesn't invoke the warm and fuzzies either.  Everything is hosted from namecheap... website, email, etc.

Domain Name: CLAMSTAKER.NET
Registry Domain ID: 1939815611_DOMAIN_NET-VRSN
Registrar WHOIS Server: whois.enom.com
Registrar URL: www.enom.com
Updated Date: 2015-06-18T03:54:36.00Z
Creation Date: 2015-06-18T10:54:00.00Z
Registrar Registration Expiration Date: 2016-06-18T10:54:00.00Z
Registrar: ENOM, INC.
Registrar IANA ID: 48
Reseller: NAMECHEAP.COM
Domain Status: clientTransferProhibited https://www.icann.org/epp#clientTransferProhibited
Registry Registrant ID:
Registrant Name: WHOISGUARD PROTECTED


I sent an email to [email protected] warning them of a potential scam site.

full member
Activity: 132
Merit: 100
willmathforcrypto.com
I'm experimenting with multisig in clams. The first part worked (creating a p2sh and sending clams to it), but the second part (spending the funds) didn't do what I expected. I found a workaround, but it's possible there's a bug in signrawtransaction. Or I made a mistake, of course. Here's more detail:

1. I used "addmultisigaddress" and created a 2-of-2 address: 6WnV4Jhe7iNQLDekwr31h9zeoK1eaDMjAw

2. I sent 0.1 clams there (small enough that it's OK if I lose it). It's txout 0 of the transaction 21db92347e153a6afdddca7f96d444d81d7daa19674ed3101e50de72cb387b19. khashier shows this transaction, but is confused by the multisig address.

3. I used "createrawtransaction" to create an unsigned tx spending this back one of my ordinary addresses.

I had one private key in my wallet and the other on paper. Using "signrawtransaction" it would sign with the one in the wallet, as expected. But then if I tried to sign with "signrawtransaction" giving the other private key explicitly in the command line, it failed. (By "failed" I mean the partially signed transaction wasn't changed.)

To be more explicit, I did this:

Code:
signrawtransaction

signrawtransaction [] ['SecondPrivateKey']


After that I just used "importprivkey" to put the second private key into the wallet, and "signrawtransaction" fully signed the transaction and it worked. If someone knows an easier way I should've been doing this, please let me know.
legendary
Activity: 2940
Merit: 1333
I have the richlist updating every 12 hours at the moment, so it should be temporary patch for the problem until I can redesign a bit of my code. I updated the richlist claim name length to display more text (and prevent user from recording a name that will be cutoff due to max size), and am not displaying the burn address... if its not part of the supply should it be included on a richlist? Up to you guys. Will play around with some of the other code tomorrow.

I think hiding it is fine. It's an artifact of the initial distribution method.
Jump to: