What is a smart contract?
If a block chain is the database, then the smart contract is the application layer that makes much of the promise of block chain technology a reality. Most conventional contracts have no direct relationship with the computer code that executes them. In many cases the paper contract is archived, and the software will execute an approximation of the contract’s terms written in computer code (see Fig. 1).
This is quite effective when signing up to use a service, but highly challenging when delivering multiple complex services to one user. This has resulted in ever more complex data protection and data privacy legislation to manage the confidentiality and privacy of the individual in an assured way. In addition, activities like data sharing or agreeing contracts have remained in paper form, rather than being automated in the wider economy. Combining the key attributes of a shared ledger (reconciliation through cryptography, replicated to many institutions, granular access control, and granular transparency and privacy) with smart contracts may create opportunities to address some of these challenges, by allowing data to either be replicated or shared under specific conditions.
If two users sign a smart contract, it will then contain logic that operates on the data in all parts of the shared ledger (see Fig. 2). Note there are other challenges like management of legacy databases and processes, but the “permissioning” across multiple systems is where Smart Contracts come into their own. In an alternative scenario (Fig. 3), User 1 opts in to a smart contract on a shared ledger to share their address with an institution that possesses a blue key (there may be many other institutions, with many different keys). But User 2 has opted out of sharing their address, so the institution only receives a copy of the latest address from User 1.
Smart contracts are being considered for a wide variety of uses, particularly for regulatory compliance, product traceability and service management, and also to defeat counterfeit products and fraud