Crypto Law Seminar #4 (7 June 2024): “Transaction Execution on Ethereum Decentralized Exchanges (DEX) From a Legal Perspective”

Notes from the Crypto Law Seminar #4 on the paper “Transaction Execution on Ethereum Decentralized Exchanges (DEX) From a Legal Perspective” by Mikołaj Barczentewicz and Natasha Vasan (draft available on SSRN).

If you haven’t read the paper, Bill Hughes posted a TLDR version on X.

Difficulty of discussing private law aspects of DeFi activities across different jurisdictions, compared to regulatory issues.

Private law issues like what constitutes a legal agreement or transaction, contract formation, and ownership transfer vary significantly between jurisdictions due to different historical and legal backgrounds. This makes it difficult to find common ground, unlike with regulatory discussions. For example, in civil law jurisdictions (except Germany), ownership can only be validly transferred based on law or agreement, otherwise it stays with the original owner even if the asset itself is transferred. This is not necessarily the case in the US, making it easier there to develop the view that contracts are not required in DeFi interactions.

The seminar highlighted the importance of distinguishing between transactions in the technical sense (transactions C) and transactions in the legal sense (transactions R). Transactions C are essentially the messages sent through the blockchain network, representing the technical execution of a transaction. Transactions R, on the other hand, are the legal (or even more broadly: economic) manifestations of those transactions, embodying the expressed intentions and the legal/economic consequences of those actions.

In a DEX environment, a user might be seen as entering into multiple contracts through a single blockchain transaction. For instance, when making a swap on a DEX, the user could be entering into one contract with the nodes for the telecommunications services and another with the liquidity providers for the financial transaction itself. This differentiation helps in understanding the varied responsibilities and potential legal obligations of the different parties involved in a single blockchain interaction​.

Whether users enter into contracts when using DeFi protocols like DEXs, and with whom.

There were differing views on whether contracts are formed when users interact with DeFi protocols. One perspective is that it depends on the user’s intentions - if they intended it as a loan or trade, it could be considered a contract. But answering questions of who is contracting with whom, for what, and under what terms likely varies significantly between different DeFi applications and blockchains. The counterparty could be the liquidity providers, or potentially the nodes/validators but only for the telecom services, not the financial transaction itself. So a user might enter into two different contracts with their single blockchain transaction.

An alternative view is that DeFi enables transacting without contracts, more akin to barter, by allowing users to directly control their assets without intermediaries. In reality though, DeFi still involves many “intermediaries” that can affect the interaction. Off-chain interactions like promises, advertisements, SLAs etc. made by entities like relays or RPC services raise the chance of enforceable contracts existing somewhere in the process. Still, thinking of DeFi as a totally disintermediated system like barter can be a useful abstraction, akin to the idea of a “frictionless surface” in physics.

Under US law, for a contract to exist there needs to be a definite offer and acceptance. A Uniswap LP could potentially be seen as making an enforceable “standing offer” to traders, with sufficiently definite terms and means of acceptance. Many intermediaries could still frustrate execution, but that may be more an issue of breach/non-performance rather than contract formation.

However, even if a LP-trader contract can be constructed, it may not help much in practice given all the other network operators involved whose roles are hard to legally define. An alternative is to view users as transacting with the overall DeFi ecosystem based on its rules, with an expectation (but not guarantee) that participants follow those rules. Violating the rules could potentially constitute fraud.

Whether contracts are necessary to legally explain asset transfers in DeFi.

In European civil law, a valid legal basis like a contract is necessary for ownership to transfer. So without an underlying contract, a DeFi asset swap would not actually transfer ownership - the user would still legally own the assets they tried to trade away. US property law may not have the same requirement though. This is an important reason for some to still view DeFi interactions through a contract law lens.

How to define the implied “rules” of a DeFi protocol, for purposes like defining breaches.

One question raised was what source to use for defining a protocol’s rules - the formal technical specification, or the social/community expectations? The latter could be hard to nail down and may not match the “code is law” ethos as crypto goes mainstream. But having an idea of the rules is important for determining things like what counts as breach or fraud.

Limitations of using contract law to address problems in DeFi.

We also dicussed the remedies available for breaches of contract in the context of DeFi transactions. Traditional contract law provides remedies that are in personam, applicable directly against the contractual counterparty. However, this poses limitations in the decentralized finance context where breaches or issues might arise not just from the direct counterparty but from other network participants or external factors such as hacks or software bugs. Additionally, contract law remedies can differ based on the type of breach – we discussed the question of how to classify breaches we might see in the DeFi / DEX context, particularly given deterministic smart contracts. Many participants found that traditional contract law remedies (especially expectation damages – restoring the ‘benefit of the bargain’) may not always make intuitive sense in the DeFi context.

One of the major limitations of contractual remedies is their inability to address proprietary issues where assets might be illegitimately transferred or dissipated through a chain of holders. This limitation suggests a need to consider other legal frameworks, such as fiduciary duties or tort law, which might offer more suitable remedies in cases involving third-party interference or negligence. For instance, fiduciary duties could be imposed on certain DeFi platform operators or developers, providing a means to bind third parties and offer proprietary consequences that are more appropriate for the decentralized nature of blockchain transactions​.