Skip to Content
Foundations of Blockchain
book

Foundations of Blockchain

by Koshik Raj
January 2019
Beginner to intermediate
372 pages
11h 17m
English
Packt Publishing
Content preview from Foundations of Blockchain

Script

We need to understand the basic execution of the Script language before trying to make sense of the locking and unlocking scripts. Script is simple, a stack-based language that is processed from left to right. It is intentionally not Turing-complete. It doesn't have a complex control flow, such as loops, other than conditions. This makes sure that the program is executed in a predictable time. This was done intentionally to avoid denial-of-service attacks, which create infinite execution loops. The simplicity of the Script language ensures that Bitcoin is not vulnerable to any attacks of this nature.

Script is also stateless, meaning that there is no information stored prior to or after execution. This ensures that execution is not ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Blockchain Basics

Blockchain Basics

Daniel Drescher
What Is Blockchain?

What Is Blockchain?

Sir John Hargrave, Evan Karnoupakis
Mastering Blockchain

Mastering Blockchain

Lorne Lantz, Daniel Cawrey

Publisher Resources

ISBN: 9781789139396Supplemental Content