Closed nd1012 closed 9 months ago
Hello @nd1012 ,
The error only occurs when using the following parameters
SphincsPlusParameters.haraka_128f_simple
SphincsPlusParameters.haraka_128s_simple
SphincsPlusParameters.haraka_192f_simple
SphincsPlusParameters.haraka_192s_simple
SphincsPlusParameters.haraka_256f_simple
SphincsPlusParameters.haraka_256s_simple
This is because they weren't added to the look-up tables and the converters.
I'll add them in a patch, however, NIST stated in their FIPS 205 draft (line 306-308) that they do not approve of these parameters.
"This standard approves the use of only 12 of the 36 parameter sets defned in [4, 5]. As specifed in Section 10, only the ‘simple’ instances in which the cryptographic functions are instantiated with SHA-2 or SHAKE are approved. "
Thanks a lot - that wasn't clear to me! For me it's not so important to stick with with Haraka hash parameters, I'll switch to Shake instead.
Usually I try to find a way to serialize a key in a standard format, so that 3rd party apps should be able to use it, too. When I look at the PQC algorithms, there are some serializations missing (NTRU, for example), so I have to use a custom serialization format at present. I assume that the standards are in heavy development for the moment, and that's the reason why things may be missing/changed in the Bouncy castle library until the standards are finalized - is that correct?
Exception:
Stack:
Code to reproduce:
The same exception is being thrown, when I use
GetEncoded
instead (similar stack).Am I doing it wrong - is there any other recommended (working) way to un-/serialize the keys?
By the way, the serilization worked with the example code above until the NuGet package was updated to version 2.3.0.