In thesoftware development process, areference implementation (or, less frequently,sample implementation ormodel implementation) is a program that implements all requirements from a corresponding specification. The reference implementation often accompanies atechnical standard, and demonstrates what should be considered the "correct" or what must^ the behavior of any other implementation of it.
Reference implementations of algorithms, for instancecryptographic algorithms, are often the result or the input ofstandardization processes. In this function they are often dedicated to thepublic domain with theirsource code aspublic domain software. Examples are the firstCERN's httpd,[1]Serpent cipher,base64 variants,[2] andSHA-3.[3] TheOpenwall Project maintains a list of several algorithms with their referencesource code in the public domain.[4]
A reference implementation may or may not be production quality. For example, theFraunhofer reference implementation of theMP3 standard usually does not compare favorably to other common implementations, such asLAME, in listening tests that determine sound quality.[5] In contrast,CPython, the reference implementation of thePython programming language,[6] is also the implementation most widely used in production.
Testing the implementation-vs-specification relationship further enhances theproduction's inter-process efficiencies:
A reference implementation is, in general, an implementation of a specification to be used as a definitive interpretation for that specification. During the development of the ... conformance test suite, at least one relatively trusted implementation of each interface is necessary to (1) discover errors or ambiguities in the specification, and (2) validate the correct functioning of the test suite.[7]
Characteristics of a Reference Implementation:
- Developed concurrently with the specification and test suite;
- Verifies that specification is implementable;
- Enables the test suite to be tested;
- Serves as a Gold Standard against which other implementations can be measured;
- Helps to clarify the intent of the specification in situations whereconformance tests are inadequate[8]
The Keccak sponge function, designed by: Bertoni, Guido; Daemen, Joan; Peeters, Michaël; Van Assche, Gilles. For more information, feedback or questions, please refer to our website: keccak.noekeon.org/ / Implementation by the designers, hereby denoted as "the implementer". / To the extent possible under law, the implementer has waived all copyright and related or neighboring rights to the source code in this file. creativecommons.org/publicdomain/zero/1.0/
For a number of years now, the distinction between Python-the-language and CPython (the reference implementation) has been growing. Most of this change is due to the emergence of Jython, IronPython, and PyPy as viable alternate implementations of Python.