1# cper-generator 2 3This project allows you to generate pseudo-random CPER records for software 4testing purposes. The records are compliant (to an extent) with the CPER 5definitions present within UEFI Specification Appendix N. 6 7## Usage 8 9An example usage of `cper-generator` is shown below. 10 11```sh 12cper-generator --out mycper.dump --sections generic dmarvtd ia32x64 arm 13``` 14 15This command would generate a CPER log with a processor generic section, VT-d 16DMAr section, IA32x64 section and an ARM section, outputting to the given 17`mycper.dump` file. To see all available names and other command switches, you 18can run `cper-generator --help`. 19 20## Caveats 21 22The generator is not completely random within the bounds of the specification, 23to make testing easier. 24 25- Validation bits are always set to "true" for **optional** fields, to ensure 26 that translating from CPER binary -> JSON -> CPER binary yields the same 27 binary output as started with, rather than changing due to optional fields 28 being left out. 29- Parts of sections which are defined in other external specifications (i.e, not 30 included in UEFI Appendix N) generally do not have their structures to 31 specification, and are simply random bytes. 32