riscv-crypto
riscv-crypto copied to clipboard
Add GM/T 0005-2012 randomness test
GM/T 0005-2012 is a national standard in China for randomness test of commercial cryptography applications. In some regions it's required in law to use GM/T 0005 test method series to pass national standard verifications.
This pull request includes:
- Description on GM/T 0005-2012 randomness test
- Small typo fix on NIST SP 800-90B requirements section
Notes on GM/T 0005-2021: it will replace GM/T 0005-2012 on May 1, 2022 link. As the new standard version is not currently in effect, this added section describes its 2012 version which is in effect by now.
Hi,
Isn't the "old" GM/T 0005-2012 an RNG test, not an entropy source test? I looked at the requirements and it seemed very similar to the obsoleted 800-22 which was a test covering also pseudorandom output. Entropy sources do not need to pass 800-22 either.
Anyway, in terms of timelines, it would seem sensible to look closely at the newer standard and see if it is compatible with AIS-31 and SP 800-90B standards (the old one is not really compatible with AIS-31/PTG.2 or 90B, as it does not seem to concern entropy. just "statistical randomness"). If it is not compatible and there is still a need for ISA support, it will need a separate instruction or a CSR interface. The seed entropy source is specifically an entropy source.
Cheers,
- markku
GM/T 0005-2012 is obsolete.