Here, I propose a proof-of-stake algorithm against both vertical and horizontal attacks on the block chain:
[ol][li]Vertical attacks consist in privately chaining a block subchain (as in “selfish mining”).[/li]
[li]Horizontal attacks consist in chaining blocks at the same height of multiple chains (as if there was “nothing at stake”).[/li][/ol]
The algorithm is quite simple:
[ol][li]Each block has a list of all addresses holding the stake that allowed chaining it. For privacy, we can use additional hashes of those addresses, or even stealth addresses. The only purpose is uniquely identifying each stake address, not publishing it.[/li]
[li]A node must discard any block of which the stake addresses intersect with those of the previous block in the same chain. This prevents vertical attacks with the same or intersecting stakes. It also creates an implicit rule by which the same or intersecting stakes cannot chain two successive blocks.[/li]
[li]A node must discard any two blocks at the same height of different chains with an intersection between their stake addresses. This prevents horizontal attacks with the same or intersecting stakes.[/li][/ol]