Implementation of Bitcoin script parsing and evaluation