Licensing is a fundamental aspect of software development, especially in the open source world. One lesser-known but significant license is the CDDL – Common Development and Distribution License. Originally created by Sun Microsystems, CDDL is used in notable projects such as OpenZFS and the former OpenSolaris. In this article, we’ll explore the key features of the CDDL license, its legal framework, advantages, and potential drawbacks for developers and organizations.
What Is the CDDL License?
CDDL is an open source license derived from the Mozilla Public License (MPL) 1.1. It is approved by the Open Source Initiative (OSI) and recognized by the Free Software Foundation as a free software license.
Unlike strong copyleft licenses like GPL, the CDDL is a weak copyleft license. This means it allows mixing open source and proprietary code under certain conditions. However, files covered by CDDL must remain publicly available and distributed under the same license.
Key Features of the CDDL License
-
Weak copyleft: Code licensed under CDDL can be combined with other (including proprietary) code as long as certain separation and source code disclosure requirements are met.
-
File-level modularity: Each file is treated as a separate module. Only modified or newly created files based on CDDL-licensed code must be shared.
-
Compatibility issues: CDDL is not compatible with GPL, which can create legal challenges when trying to combine CDDL and GPL code in a single binary.
-
Legal clarity: The license is written to be relatively easy to read and understand, even for non-lawyers.
Real-World Use of the CDDL License
One of the best-known uses of CDDL is in OpenZFS, a high-performance file system known for features like snapshots, data integrity, and replication. Due to the GPL incompatibility, OpenZFS cannot be directly integrated into the Linux kernel, which is GPLv2-licensed. Instead, ZFS is provided as a separate kernel module.
CDDL was also used in the now-discontinued OpenSolaris project. Its modular and flexible licensing approach was intended to allow Sun Microsystems to open-source parts of their code without giving up full control.
Advantages of the CDDL License
-
Business-friendly: CDDL allows combining open source code with proprietary code, making it attractive for companies seeking a balance between openness and control.
-
Easier distribution of modifications: Developers only need to publish the specific files they've modified, not the entire codebase.
-
Clear modular structure: Because the license operates at the file level, it’s easier to identify what needs to be disclosed.
Disadvantages and Legal Risks of CDDL
-
GPL incompatibility: This creates significant obstacles for integrating CDDL code with the vast number of projects licensed under the GPL.
-
Limited adoption: Compared to more permissive or widely compatible licenses, CDDL is used by fewer projects.
-
Legal ambiguity in some use cases: Combining code under different licenses can lead to complex legal interpretations and potential violations.
The CDDL license offers an interesting compromise between open source ideals and commercial flexibility. It's particularly useful for organizations and developers who want to share parts of their code while retaining proprietary rights over the rest. Despite its incompatibility with GPL and limited adoption, projects like OpenZFS demonstrate that CDDL has a solid place in the open source ecosystem. However, anyone considering CDDL should carefully evaluate the legal implications and compatibility issues with other licenses before making a final decision.