Compile-time random netlist constant
In OpenTitan's D2S signoff checklist, compile-time random netlist constants are listed as one of the standardized security countermeasures that must be implemented. They are values such as LFSR seeds or scrambling constants that are baked into the synthesized netlist so that they are fixed at hardware build time and not visible or controllable at runtime via software.
Mechanism in OpenTitan
- The constants are exposed to
topgenvia therandtypeparameter mechanism declared in the block's comportable IP Hjson file. - This means each IP block that uses random compile-time constants (for example, an LFSR-based countermeasure) declares those parameters in its Hjson;
topgenthen propagates them into the generated top-level wrapper and downstream synthesis flow.
Generating default seeds
- Default random seeds and permutations for LFSRs are not chosen by hand; they are generated with
util/design/gen-lfsr-seed.pyin the OpenTitan repository. - The script is the canonical tool for producing the compile-time random netlist constants referenced in Hjson.
Relation to the signoff checklist
The checklist (under SEC_CM_IMPLEMENTED) requires that any appropriate security counter-measures are implemented and that they follow the OpenTitan Secure Hardware Design Guidelines. Compile-time random netlist constants fall under that requirement, and their presence is checked in part by reviewing the block's Hjson and the corresponding generated RTL/netlist.
Related concept
The specific kind of compile-time random netlist constant most commonly used in OpenTitan is the LFSR seed, which is part of this broader concept.
References
- OpenTitan Earlgrey 1.0.0 Signoff Checklist (D2S, SEC_CM_IMPLEMENTED section)
util/design/gen-lfsr-seed.py(LFSR seed generation script)- OpenTitan GitHub issue #2229 (background on random netlist constants)
- OpenTitan Secure Hardware Design Guidelines