6. Requirements and Design Goals

This chapter states what the designed system must do, in terms precise enough that Chapters 7–15 can be checked against them and Chapter 19 can propose tests for them. Functional requirements are labelled F, non-functional N, and constraints C.

6.1 Functional requirements

IDRequirementRationale
F1The provider shall supply a block cipher in an AEAD mode suitable for TLS 1.3 record protection.§2.4
F2The provider shall supply a hash function usable as a TLS handshake hash, including streaming update and context duplication.§5.3
F3The provider shall supply an elliptic-curve group for key agreement, including generation, derivation and peer-share validation.§2.5
F4The provider shall advertise its group through the TLS-GROUP capability with a code point, wire name and security metadata.§4.3.1
F5The algorithms shall be selectable by property query, so that a deployment can require them explicitly.§3.5
F6The provider shall be activatable by configuration file, without modifying the application.§3.7
F7A cipher suite combining F1 and F2 shall be usable in a TLS 1.3 handshake.Chapter 12
F8Each algorithm shall report its parameters — key, IV, tag and digest lengths — through the parameter mechanism.§5.5 rule 1
F9The provider shall coexist with the default provider in the same library context without displacing it.§3.7
F10Failure to satisfy a required property shall produce a clean fetch failure, not a silent fallback.§6.4

6.2 Non-functional requirements

IDRequirement
N1Algorithm objects shall be prefetched and reused for the lifetime of a connection rather than fetched per record.
N2No operation shall branch on secret data in a way that is observable through timing, to the extent the implementation language permits.
N3The provider shall be a single shared object with no dependencies beyond libcrypto.
N4All context state shall be freed on teardown, including after an error path.
N5The provider shall be buildable and testable without modifying the OpenSSL installation.
N6Diagnostic failure paths shall report through the core's error mechanism rather than writing to standard error.

6.3 Constraints

IDConstraintSource
C1The provider cannot alter handshake sequencing or message encoding.§5.1
C2The AEAD must accept an externally constructed nonce.§2.4
C3A change of handshake hash changes the width of the entire key schedule.§2.3
C4Any new code point must be recognised by the peer; unilateral introduction cannot produce interoperability.§4.5
C5The provider executes with the full privileges of the process.§3.8
C6Algorithms must be advertised in the same library context the SSL_CTX uses.§5.5 rule 3

6.4 The fail-closed principle

Requirement F10 deserves separate treatment because it is the requirement most often violated by systems of this kind, and the violation is not visible in testing that only checks the happy path.

A deployment that introduces an algorithm for a compliance reason needs the connection to fail when the algorithm is unavailable. The alternative — falling back to a standard algorithm and completing the handshake — produces a working connection that does not satisfy the requirement the deployment exists to satisfy, and produces it silently.

OpenSSL's property mechanism supports this directly: a required property that no implementation satisfies causes the fetch to fail, and the fetch failure propagates. The design must therefore be careful never to specify its properties as merely preferred where the deployment intends them as mandatory. Chapter 14 develops the distinction, and Chapter 19 proposes a negative test for it — a test that deliberately deactivates the provider and asserts that the handshake fails rather than succeeding by another route.

Design principle. A check that has never been observed to fail has not been tested. Every requirement in §6.1 that can be violated should have a test that violates it and confirms the system notices, not merely a test that satisfies it and confirms the system works. This principle governs the test plan in Chapter 19.

6.5 Explicit non-goals

The following are outside the design, and stating them prevents the evaluation chapters from being read as having neglected them:

6.6 Traceability

Each requirement is addressed by an identified chapter, and Appendix D carries the matrix forward to the claim table. A requirement with no corresponding design section is a gap, and a design section addressing no requirement is scope creep; the matrix is maintained to make both visible.

RequirementAddressed in
F1, C2Chapter 8
F2, C3Chapters 9 and 15
F3, F4Chapters 10 and 11
F5, F10Chapter 14
F6, C6Chapter 13
F7, C4Chapters 12 and 16
F8, F9Chapter 7
N1Chapter 18
N2, C5Chapter 17
N3–N6Chapter 7