The quest to enhance Bitcoin’s capabilities without altering its core consensus rules has led researchers down intricate cryptographic pathways. A significant exploration into this domain arrived in May 2024 with Jeremy Rubin’s paper, "FE’d Up Covenants," which proposed a radical shift in how Bitcoin covenants could be implemented. Instead of embedding complex logic directly into Bitcoin Script, Rubin’s design leverages Functional Encryption (FE) to move covenant enforcement from the blockchain itself into the signing key. This technical innovation, while theoretically powerful, faces substantial practical challenges that currently relegate it to the realm of academic curiosity rather than immediate deployment.
The fundamental challenge in modifying Bitcoin’s base layer lies in achieving network-wide consensus. Any proposed change to Bitcoin’s consensus rules necessitates a complex dance of coordination among a diverse group of stakeholders: node operators who validate transactions, miners who secure the network, developers who write the code, and economic actors whose capital is at stake. This inherent difficulty in synchronization has led to a gradual ossification of Bitcoin’s base layer, with significant changes requiring broad agreement that is hard to attain. Consequently, innovation has increasingly focused on layer-two solutions and off-chain protocols, or on exploring how existing cryptographic primitives can be creatively employed to achieve desired functionalities without contentious hard forks or soft forks.
Rubin’s "FE’d Up Covenants" paper represents a pivotal moment in this ongoing research, directly addressing the question of whether covenant behavior could be enforced without touching consensus rules. His proposed solution hinges on a sophisticated cryptographic concept: Functional Encryption.
Functional Encryption: A New Paradigm for Key Control
At its core, Functional Encryption (FE) offers a generalized approach to public-key cryptography. In standard public-key systems, a private key grants unrestricted access to decrypt a ciphertext, revealing the original plaintext. FE, however, introduces a nuanced control mechanism. A master secret key is used to generate specialized "functional keys." Each of these functional keys is designed to reveal only a specific, predetermined function of the underlying plaintext, without ever exposing the plaintext itself. In essence, a holder of a functional key can compute a specific output related to encrypted data but cannot access the data directly.
The academic journey of FE began with its formalization by Dan Boneh, Amit Sahai, and Brent Waters in 2011. Early constructions, while demonstrating theoretical feasibility for arbitrary functions, were plagued by exorbitant computational overheads, rendering them impractical for real-world applications. These initial designs, proposed around 2013, also relied on novel, unproven cryptographic building blocks known as multilinear maps. It wasn’t until 2021 that significant advancements were made, with researchers developing constructions based on more established cryptographic assumptions. These breakthroughs, while still demanding, opened a theoretical pathway towards more practical FE implementations.
In the context of Bitcoin covenants, the "function" (f) in an FE scheme is specifically a signing function. This function takes a private key and a transaction as inputs and outputs a valid Bitcoin signature for that transaction. Crucially, this signature is not a generic one generated by the private key alone. Instead, the FE function derives a new, tweaked key pair by combining the original private key with the specific covenant’s spending policy. Signatures produced through this process are valid only for the tweaked public key, not the base public key associated with the original private key. This constraint is the bedrock of Rubin’s proposed covenant mechanism.

Rubin’s design specifically employs multi-input FE, recognizing that the signing process inherently requires at least two inputs: the private key and the transaction to be signed. For covenants that permit only a single, predefined spending transaction, similar to the proposed OP_CTV (CheckTemplateVerify), two inputs are sufficient. However, for more versatile and expressive covenant designs, the functional signature might require more arguments, as exemplified by Rubin’s generalized function signature: f(k, tx, program, proof).
The Mechanics of FE-Based Covenants
Implementing FE-based covenants necessitates a trusted setup authority. This entity is responsible for generating an initial Bitcoin key pair (a private key ‘k’ and its corresponding public key ‘P’). Simultaneously, it generates an FE key pair, comprising a master secret key ‘msk’ and an FE public key ‘mpk’. The setup authority then publishes ‘P’ and ‘mpk’. The original private key ‘k’ is encrypted using ‘mpk’, and a functional key for the signing function ‘f’ is derived from ‘msk’. A critical trust assumption here is that the setup authority securely destroys both ‘k’ and ‘msk’ after this initial setup. Failure to do so would allow the authority to forge signatures and violate covenant rules. Once this trusted setup is complete, an unlimited number of distinct covenants can be established.
Each covenant is uniquely identified by a dedicated key pair, which is essentially a "tweaked" version of the original (k, P) pair, influenced by the specific spending policy of that covenant. The private key for this tweaked pair remains exclusively within the FE function ‘f’ and is never exposed. The corresponding public key, however, can be derived by anyone who knows the hash of the desired spending policy, starting from the original public key ‘P’. This mechanism allows for the generation of covenant receiving addresses.
In practice, a covenant-receiving address would likely commit to a 2-of-2 multisignature script. This script would require a signature from a user-controlled key in addition to the FE-generated signature. This layered security approach is designed to prevent unauthorized parties from unilaterally initiating transactions permitted by the covenant.
The Signature Generation Process
To generate an FE signature for a covenant-controlled spend, a signer must first construct a transaction (‘tx’) that adheres to the specific spending policy of the covenant. This ‘tx’ is then encrypted with the FE public key ‘mpk’. Using this encrypted transaction, along with the encrypted original private key ‘k’ and the functional key provided by the setup authority, the FE function ‘f’ can be evaluated. The function ‘f’ then produces a signature for ‘tx’ using ‘k’, which has been effectively "tweaked" by the hash of the covenant’s spending policy.
The efficacy of this system lies in its enforcement. A transaction that attempts to violate the spending policy of a particular covenant address would, at best, be signed for a differently tweaked public key that does not hold control over those specific funds. In a more robust implementation, the function ‘f’ can be designed to outright reject any attempt to sign transactions that deviate from the prescribed policy.
Enhanced Expressiveness and Future Potential
The generalized version of FE-based covenants, represented by f(k, tx, program, proof), offers significantly greater expressiveness than simpler proposals like OP_CTV. In this advanced model, the ‘program’ argument specifies a condition that must be met for the transaction to be considered valid. The ‘proof’ argument is a zero-knowledge proof confirming that the transaction indeed satisfies the program’s conditions.

While the zero-knowledge proof facilitates the FE scheme’s implementation, it doesn’t inherently alter the cryptographic principles of FE itself. A single, fixed FE function ‘f’ can operate with or without the proof. The inclusion of the proof allows for a more streamlined evaluation of ‘f’. Without it, ‘f’ would need to function as a general interpreter capable of executing any given program on the transaction. Such a universal interpreter would be large and computationally expensive to evaluate within the FE framework. The proof, however, enables ‘f’ to verify a concise proof of compliance, potentially allowing for the enforcement of arbitrarily complex covenants without increasing the complexity of ‘f’ itself. Furthermore, this proof mechanism allows spending policies to incorporate data beyond the transaction itself, such as the outcomes of off-chain computations.
The Practical Bottleneck: Infeasibility of Current FE Implementations
Despite the theoretical elegance and potential of FE-based covenants, their practical realization on Bitcoin faces formidable obstacles, primarily stemming from the immaturity of FE implementations. The foundational research for multi-input FE, as presented by Goldwasser et al. in 2014, demonstrated its connection to indistinguishability obfuscation. Subsequent work by Ananth and Jain in 2015 further highlighted that even single-input FE for general circuits, when made compact, implies obfuscation. This means that the cryptographic primitive required for FE-based covenants is, at a minimum, as challenging to construct as indistinguishability obfuscation itself, a field that has seen progress but remains far from widespread practical application.
Empirical evidence underscores this challenge. A 2017 study by Carmer, Malozemoff, and Raykova detailed an attempt to obfuscate a simple 12-bit pseudorandom function, a circuit comprising approximately 62,000 gates. The process took a staggering 3.7 hours, produced an obfuscated program occupying 120 GB of disk space, and required 67 minutes of computation with 128 GB of RAM for evaluation. For context, this is a minuscule circuit compared to the complexity of performing an ECDSA signature verification on 256-bit numbers, a standard operation in Bitcoin. The authors themselves described the results as "still far from practical." The computational burden in such schemes falls on the party generating the signature, not on the Bitcoin nodes verifying it, but the sheer resource requirements make it economically unviable for most users.
Compounding these issues, current practical FE schemes are restricted to very narrow classes of functions. Examples include inner product computations, as explored by Abdalla et al. in 2015. The specific type of ECDSA signing required for robust Bitcoin covenants is not within the scope of these limited practical FE constructions. Rubin’s own paper acknowledges these limitations, listing under-developed cryptography and the inherent trust assumption in the setup authority as significant downsides. While CTV-style opcodes, which require a base-layer change, remain considerably more efficient in terms of byte usage and verification time, they necessitate a hard fork or soft fork.
The Road Ahead: Approximating Covenants
The significant practical barriers to FE-based covenants have prompted further research into alternative approaches that can approximate covenant behavior without relying on such computationally intensive cryptographic primitives. In an upcoming installment of this series, "Un-FE’d Covenants," the exploration will shift to proposals that aim to achieve similar functionalities. One such avenue involves replacing FE with oracle signers that are bonded through mechanisms like BitVM. Additionally, the article will delve into "Bitcoin PIPEs," an initiative that began in 2024 as an FE design but evolved by 2026 to incorporate witness encryption, a proposal that will also be covered in subsequent analysis. These ongoing developments highlight the dynamic and evolving nature of Bitcoin’s technical frontier, as researchers continue to push the boundaries of what is possible on the decentralized ledger.
