Skip to content
forked from jb55/btcs

bitcoin script parser/evaluator/compiler/decoder

License

Notifications You must be signed in to change notification settings

sleclaire837/btcs

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

btcs

Build Status

bitcoin script parser/evaluator/compiler/decompiler

WARNING: This is not a consensus-critical implementation of bitcoin script. Make sure to actually test your script on testnet or with something like btcdeb.

Motivation

I wanted a better way to hack on Bitcoin scripts

Installing

deps: python3, bison, flex, a C compiler

$ make install

with nix:

$ nix-env -if .

TODOs

  • Tokenizer
  • Evaluator (partially complete)
  • Compiler
  • Decompiler
  • Docs

Usage

Work in progress. Some OPs are working:

$ btcs 1 2 16 3dup 2swap

script      1 2 16 OP_3DUP OP_2SWAP
script_hex  5152606f72
stack       1 2 2 16 16 1
stack_hex   010202101001
results     success

About

bitcoin script parser/evaluator/compiler/decoder

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C 91.9%
  • Python 2.9%
  • Roff 1.6%
  • Makefile 0.9%
  • Yacc 0.9%
  • Lex 0.8%
  • Other 1.0%