public inbox for bitcoindev@googlegroups.com
 help / color / mirror / Atom feed
From: Rusty Russell <rusty@rustcorp•com.au>
To: Luke Dashjr <luke@dashjr•org>,
	Bitcoin Protocol Discussion
	<bitcoin-dev@lists•linuxfoundation.org>,
	Bitcoin Protocol Discussion
	<bitcoin-dev@lists•linuxfoundation.org>
Subject: Re: [bitcoin-dev] BIP draft: OP_CHECKBLOCKATHEIGHT
Date: Sat, 01 Oct 2016 13:31:04 +0930	[thread overview]
Message-ID: <87oa34d8fz.fsf@rustcorp.com.au> (raw)
In-Reply-To: <201609230957.03138.luke@dashjr.org>

Luke Dashjr via bitcoin-dev <bitcoin-dev@lists•linuxfoundation.org> writes:

> This BIP describes a new opcode (OP_CHECKBLOCKATHEIGHT) for the Bitcoin 
> scripting system to address reissuing bitcoin transactions when the coins they 
> spend have been conflicted/double-spent.
>
> https://github.com/luke-jr/bips/blob/bip-cbah/bip-cbah.mediawiki
>
> Does this seem like a good idea/approach?

Prefer a three-arg version (gbits-to-compare, blocknum, hash):
- If <bits> is 0 or > 256, invalid.
- If the hash length is not (<bits> + 7) / 8, invalid.
- If the hash unused bits are not 0, invalid.
- Otherwise <bits> of hash is compared to lower <bits> of blockhash.

This version also lets you play gambling games on-chain!

Or maybe I've just put another nail in CBAH's coffin?

Cheers,
Rusty.


  parent reply	other threads:[~2016-10-01  4:10 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-23  9:57 Luke Dashjr
2016-09-23 13:43 ` Russell O'Connor
     [not found]   ` <CAAS2fgQGC695mkyze+mVTZZoQN1mh+1y32u-D6Yv1R7nXWPDcg@mail.gmail.com>
2016-09-23 18:57     ` Gregory Maxwell
2016-09-23 20:02       ` Peter Todd
2016-09-23 22:20   ` Luke Dashjr
2016-09-23 23:43     ` Gregory Maxwell
2016-09-23 14:37 ` Tom
2016-09-23 22:34   ` Luke Dashjr
2016-09-24  0:08     ` Dave Scotese
2016-09-24  9:37     ` Tom
2016-09-23 16:18 ` Peter Todd
2016-10-01  4:01 ` Rusty Russell [this message]
2016-10-01  5:02   ` Luke Dashjr
2016-10-05  2:15     ` Nathan Cook

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87oa34d8fz.fsf@rustcorp.com.au \
    --to=rusty@rustcorp$(echo .)com.au \
    --cc=bitcoin-dev@lists$(echo .)linuxfoundation.org \
    --cc=luke@dashjr$(echo .)org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox