News

Demystifying Smart Contracts

There are many indications that the next chapter in the evolution of the “Internet of Things” (IOT) will be affected by a new foundational technology similar to the inception of TCP/IP (e-mail, internet, the world wide web). The impending technology is a Distributed Ledger Technology (DLT) known as “Blockchain”, which is a decentralized database with information stored in a network of computers across the globe. One of the many features provided by this revolutionary technology is that of forging smart contracts.

What is a Smart Contract?

First discussed by Nick Szabo in 1997, he defined it as ‘a set of promises, specified in digital form, including protocols within which the parties perform on the other’s promises’. Smart contracts use modus ponens (if/then) logic to create what are in theory self-executing, self-enforcing, state-contingent contracts. In simpler words, a smart contract consists of logic written in the form of computer code that is stored and deployed on the blockchain network.

Smart contracts can have different flavours, mainly if the contract is on public blockchain, private or hybrid, or between interchains. This predominately affects the execution and enforceability part of a smart contract. Smart contacts are also currently the subject of a standard being discussed at ISO/TC 307.

When a contract is developed, it is encrypted and deployed onto the blockchain, hashed and shared with thousands of computers which will then verify it to ensure trustworthiness. Although it is publicly available, its encryption prevents anyone from accessing the contents of the contract, even an abnormally smart hacker.

One would argue that the crux of this platform is the elimination of the need for a third party intermediary to overlook and handle transactions, which in turn greatly reduces costs and waiting times. Transactions and contracts concluded on the blockchain are traceable, transparent and irreversible, while at the same time keeping both parties to the contract anonymous.

An easy way to explain the nature of a smart contract is by comparing it to a vending machine; you insert payment, choose an item and the machine will automatically release your chosen item.

Examples and benefits

Through the use of smart contracts, parties to an agreement have no need for a lawyer to draft the rules, guidelines, conditions and penalties. These are all programmed into the system in the form of computer code and will execute themselves based on pre-determined conditions.

Consider a case of peer-to-peer micro insurance. Using the blockchain, insurance firms can add the ability to efficiently bring a wider range of parties together online to tailor an insurance product to meet individual needs and reliably and transparently record the transaction. The firm can then automatically enforce and fulfill the obligations of the parties when the conditions of the contract are met, through the transmission of input signals from IoT devices used by the insured (even smart cars).

There is also the peer-to-peer lending sector which is already making strides in this direction to connect savers and lenders. MoneyCircles (which is regulated by the UK Prudential Regulation and Financial Conduct Authorities) is a company that connects savers with borrowers that form part of their social circles based on their Gmail, Facebook, Twitter or LinkedIn networks, and loan money based on their criteria. The parties to the contract then agree upon a set of conditions that are inserted into the smart contract, and then any transactions which take place occur through a blockchain. The smart contract also ensures the disbursement of the principal and interest payments over the loan period. As the transactions occur in real time over the loan cycle, regulators are provided with a real-time view of the financial details, which in turn simplifies the KYC/AML procedures.

One of the more beneficial qualities of a smart contract is that of eliminating the inherent ambiguity of natural language, where words often have multiple meanings and interpretations. Smart contracts provide a solution to this problem by incorporating legal provisions (wet code) into code (dry code). If parties want certainty, they can use a smart contract to ensure that a contractual condition is self-executed, forcing parties to remain bound to their respective obligations.

Differences between traditional contracts and smart contracts

The basic tenant on which Maltese contract law is built, is the freedom to contract. While at the time of writing most types of smart contracts are not yet directly regulated, the general view is that such contracts should follow the law of the land (lex terrae) and can be independently performed as legal contracts only if the contracting terms meet the principles of contract law.

The Maltese Law of Obligations provides that a contract is entered into by an offer being made and accepted or by the mutual exchange of declarations of intent in any other manner if it is sufficiently clear that the parties have reached an agreement. In certain instances, the freedom to contract based on the subjective will to contract is side-lined in favour of a more objective assessment of behaviour of the parties.

The Civil Code, in Article 966, sets out the four requisite elements for the validity of a contract:

  1. capacity of the parties to contract;
  2. the consent of the party who binds himself;
  3. a certain thing which constitutes the subject-matter of the contract;
  4. a lawful consideration.

Similar provisions regulating the formation of contracts are found in the United Nations Convention on Contracts for the International Sale of Goods (Vienna 1980), as well as in more recent texts of UNIDROIT Principles of International Commercial Contracts (PICC), Principles of European Contract Law (PECL) and Draft Common Frame of Reference (DCFR). These requirements are thus also applicable to smart contracts. Aside from these and depending on the transaction at hand, certain contracts would also need to follow specific formalities set at law, such as those set out in electronic contracts and consumer contracts.

It is important to note some tangible differences. Apart from the self-execution, enforcement and automated elements which distinguish a smart contract, the main difference between a smart contract and a normal contract is that rights can be traded, alienated and exchanged (and hence controlled) via digital means. You will see Bitproperty, smart property or smart cars registered as part of the blockchain with all the information on ownership, use, possession, access etc. Here the smart contract can also issue or enable smart keys and manage the respective rights of possession, use and ownership once the preset conditions are met, all via digital means.

In essence, smart contracts contain a legal relationship which is concluded by electronic means, without the need to use paper documents or traditional signatures, and it may also be modified in this manner. Performance of the legal relationship, or elements thereof, do not have to be tied to any action in the real world – it is automatic and subject only to the rules established in the smart contract.

Challenges

Although the purpose of smart contracts is to facilitate the execution of complex agreements with greater clarity, they also present a series of new challenges.

Zero tolerance would kick in when the parties are left with no choice but to execute the contract. In order for a smart contract to be valid, it needs to observe the law of the land (lex terrae), and this may present a problem. Certain contracts like distance contracts and consumer contracts might not be validly constituted if they have an absolute zero tolerance. To a certain extent, even freedom to contract would not allow an absolute zero tolerance, as the law allows the right in certain cases for individuals to amend, rescind or revoke the contract (such as in consumer contracts).

There could be two solutions to this issue: either input as dry code all the real-life instances, variables, laws and conditions in the smart contract to cater for a flexible and lawful outcome, which could be very taxing to say the least, or else, use Oracles. Oracles can be trusted third parties such as courts, authorities or public officers, amongst other entities, who can determine these instances. Oracles are also instrumental in determining issues with trust boundaries (where the contract would require verification of information not on the blockchain).

Smart contacts can also be pre-programmed at a genesis block level to allow for Oracles such as an authority or court to stop a transaction in certain instances and even to enforce precautionary measures. With smart contracts, we are seeing wet code juxtaposed over dry code. However, as time passes these two codes (legal code and technical code) may fuse/merge and the smart contract would be considered to be the law. This poses a risk if pushed to the extreme as unlike a standard contract, an individual cannot opt out, not perform and allow the law to take its due course. Here algorithmic governance would determine the outcome. This is what Lessig spoke about in his book “Code”. If pushed to an illogical extreme, such a system would be tantamount to a totalitarian model in stark contrast with the egalitarian, democratic and liberal model being envisaged with blockchain.

There are other issues which we need to be wary of and start considering. How shall we regulate machine-to-machine contracts? (which is not something far-fetched when one considers the growing importance of AI, IoT and blockchain). In the future your digital assistant (AI) could do all the contracting for you. Countries like Finland already want to bestow legal personality on AIs, and Saudi Arabia is bestowing rights to a robot.

Do we need to have special courts and dispute resolution models (like Dubai) to embrace this digital and technological innovation? Thanks, in part, to its stringent encryption techniques, blockchains will have more legal bearing in court.  An approved bill in Vermont would make records verified through blockchain technology admissible as evidence in court. Laws such as this create a kind of legal backing for blockchain-based information. In Nevada, a bill has deemed smart contracts and blockchain signatures as acceptable records under state law. Will standards (like ISDA) be required for interoperability of smart contract acceptance in all countries? Lack of harmonization in drafting of smart contracts as well as legal acceptance and validity could also pose a serious problem to the adoption of these instruments in a borderless medium and in digital economy.

There are also issues which technology can surely cater for with regards to GDPR compliance, right to be forgotten, right not to be subject to an automated decision, privacy by design, as well as identifying controllers and co-controllers and their respective obligations.

Conclusions

The advent of Lex Cryptographia and smart contracts may force us to re-evaluate the interaction between regulatory levers. One of the key consequences of blockchain adoption and widespread use of smart contracts could be a rapid expansion of what Lawrence Lessig referred to as “architecture”—the code, hardware, and structures that constrain how we behave—or at a minimum, a redefinition of how laws and regulations are designed, implemented, and enforced where there is no more an absolute hierarchical application for laws and regulation, but a more centric and circular one, catering for a decentralized digital economy. New rights and laws might emerge and legacy ones become redundant and this might also radically change the legal profession.

For more information on Smart Contracts, Blockchain, DLTs, GDPR and legal issues relating to AI and IoT, or if you have any questions, please feel free to contact Dr Ian Gauci on igauci@gtgadvocates.com