How to manually set peercoin address

I’m playing around with the peershare template but I’m not able to find a way to manually set the peercoin address associated with each dividends address. This is very useful in the case where my main peercoin wallet is not on the same machine as the peershare client and therefore can’t export peercoin addresses through the gui. Another important use case for this would be the use of a multisig peercoin address to receive dividends at.

Is it already implemented and I’m missing? Any thoughts?

You cannot change dividends address because it’s Peershares address, just w/ different version byte, there is no separate keypair for dividends.

Oh then I think I’m totally confused regarding the addressing system. could you please explain the differences between:

Peershares address
Dividends address

Which are in the receive tap

And

Peercoin address

Which shows in the distribute dividends window

And what does exactly the button “Export peercoin keys” do cause I think I totally got its functionality backwards in my head.

Thank you :slight_smile:

The Peershares address is the address that will show up under the “address” column. This is the address that you would provide someone to receive Peershares. Peershares addresses will have a “dividend address” associated with them. This “dividend address” is essentially a Peercoin address. Peershares cannot send or receive Peercoins itself. it can only send/receieve Peershares. So when you “export peercoin keys” it essentially talks to your Peercoin client and says “Hey, Peercoin wallet, Please add this dividend address to your wallet. When someone decides to distribute dividends to the shareholders they’re going to send Peercoins to that address”. The number of Peercoins sent will be in relation to the number of shares held in the Peershares address associate with that Peercoin address.

I hope that helps clear it up a bit. I’m working on a video series to explain all this which I hope will clear up a lot of confusion regarding use of the client. It’s far simpler than what I think a lot of people believe it to be.

[quote=“SirCoinGame, post:4, topic:2572”]The Peershares address is the address that will show up under the “address” column. This is the address that you would provide someone to receive Peershares. Peershares addresses will have a “dividend address” associated with them. This “dividend address” is essentially a Peercoin address. Peershares cannot send or receive Peercoins itself. it can only send/receieve Peershares. So when you “export peercoin keys” it essentially talks to your Peercoin client and says “Hey, Peercoin wallet, Please add this dividend address to your wallet. When someone decides to distribute dividends to the shareholders they’re going to send Peercoins to that address”. The number of Peercoins sent will be in relation to the number of shares held in the Peershares address associate with that Peercoin address.

I hope that helps clear it up a bit. I’m working on a video series to explain all this which I hope will clear up a lot of confusion regarding use of the client. It’s far simpler than what I think a lot of people believe it to be.[/quote]
This clarifies it… Thank you :)… so what the button does is add those addresses to the peercoin wallet. But won’t the peercoin client need their private key to be able to spend from those addresses? Or were the addresses generated using peercoin rpc which means they generated using the private key in the current wallet in in the peercoin client?

Sorry for seeming like I’m over complicating lol I’m trying to understand the connection between the peercoin client and peershare client when generating those addresses and accessing them :slight_smile:

How is the (dividend address which is a peercoin address) generated? Is it related to the peershare address? If I know one can I deduce the other given I have all required private keys?

Basically what I’m thinking of implementing is a way to input an already existent peercoin address into a method which would spit out a peershare address associated with the private key and that address that has the inputed peercoin address as its dividend address

I believe this is beyond the scope of what’s currently implemented in and I would be glad to implement it and create a pull request once I understand how the system works and whether this is even doable from a cryptographic stand point.

Any thoughts?

A Peershares address and its associated Peercoin address represent the same public and private keys. They are just different forms of the same key.

So if you have one address you can guess the other.

When you export the keys to Peercoin, it just generates the Peercoin forms of your private keys and calls the “importprivkey” RPC command on Peercoin.

So technically you can also generate a Peershares address from a Peercoin address.

Using multisignature addresses works too. If you create a multisignature address in Peershares and export it to Peercoin, then it calls the “addmultisigaddress” RPC command instead of “importprivkey”. So it generates a Peercoin multisignature address with the same characteristics and all the addresses converted to Peercoin addresses.

[quote=“sigmike, post:7, topic:2572”]A Peershares address and its associated Peercoin address represent the same public and private keys. They are just different forms of the same key.

So if you have one address you can guess the other.

When you export the keys to Peercoin, it just generates the Peercoin forms of your private keys and calls the “importprivkey” RPC command on Peercoin.

So technically you can also generate a Peershares address from a Peercoin address.

Using multisignature addresses works too. If you create a multisignature address in Peershares and export it to Peercoin, then it calls the “addmultisigaddress” RPC command instead of “importprivkey”. So it generates a Peercoin multisignature address with the same characteristics and all the addresses converted to Peercoin addresses.[/quote]
Thank you. This exactly the information I needed :). I’ll go over the code in the weekend and see what I can do with this info.