Newbie looking for details

Hi all,

I’m new on the forum and I’m looking for information on how proof-of-methods, like proof-of-stake (pos) and proof-of-work (pow) actually operate. I think I have a good grasp of pow, but it seems to me there’s very limited documentation on how pos operates – not from a high level perspective, but from a detailed perspective.

So, if it’s OK, Id like to ask some questions about Peercoin’s pos. First of all, if anyone can point me to a detailed technical documentation on proof-of-stake in Peercoin that answers the questions below, that would be really appreciated. But I’ve done some Big Searching (yes, I watched the videos, searched the forum, used Google, etc), haven’t been able to find any. Most posts seem to focus on ‘how to do it’, instead of ‘how it actually works, under the hood’.

The main idea of proof-of-stake is to use coin age as a resource, compared to pow’s hashing power.

My questions are:
*How do nodes connect tot the P2P network, or find other nodes? Are there hardcoded ip-addresses of DNS servers in the client?

  • Who/what determines the coin age? Can’t I cheat by stating (in my peercoin client) my coins have x-age? My assumption is that, as with Bitcoin, Peercoins move from transaction to transaction (not from wallet to wallet). With the network time (I assume UTC is applied) and a sliding time window, wouldn’t someone be able to slide that window up, effectively being able to mine a block faster then someone who is honest (time-wise)?
    *How is a transaction generated? What does a transaction frame look like? How are transactions collected, is there such a thing like a memory pool (as with Bitcoin)?
  • How is a block generated? What is actually in a block (like: timestamp, stake, hash previous block) – does the block contain transactions that are being verified, like in Bitcoin’s pow?
  • How are blocks distributed, is it similar as in Bitcoin’s pow, where blocks are being broadcasted to nodes in the network?
  • From what I understand from the original paper (PPCoin: Peer-to-Peer Crypto-Currency with Proof-of-Stake), everyone mines a block, but only the block with the highest stake wins. Is that correct? Somehow it seems contradictory to the idea of not everyone having to mine and thus saving energy.

Thanks for reading.


have you browsed the wiki? Here is a diagram how a new pos block is made:

There is a timewindow of 1 hour (forwards and backwards) where you may cheat in relation to unix time. So you may hash up to 7200 per second if you must. This is in contrast to the many petahashes an ASIC miner does. There is no arms race here.

What counts are the untouched coins in your last transactions multiplied by the days since last touched(capped at 90 days). The longer untouched the better the coinage.

Hey, thanks! That’s really useful.

I found the same pic with some text explaining each step:

I think I’m starting to grasp PoS. As in Sunny King’s original paper, PoS in Peercoin is a stochastic process, meaning that even with a low stake, I’d be able to win a block (but chances are low).
The coin age is derived from the blockchain itself (as in the picture above). Assuming that my Peercoin client performs the calculation of the Stake Kernel Hash, what prevents me from manually providing my client with a false coin age and thus always winning a block?

I’m also unclear about the ‘target’. Is this formula correct for creating a stake kernel hash in Peercoin: SHA256(Kernel) < coin age * target ?
And how is the target calculated, what’s the formula in English (not the code:

Last question, how do nodes collect and verify the validity of transactions that are in a block?


Nodes are verifying every block they receive, your block minted with fake coinage would be rejected.

The formula is rather basic for PoS: it increases difficulty if last block spacing is above 10 mns, lowers it otherwise.

Peercoin network is a P2P network. Nodes are relaying valid blocks and transactions they receive to each other. They validate themselves what they receive by running the peercoin client.

Thanks Mably, much appreciated