Closed matteo-cristino closed 4 months ago
Hi @matteo-cristino, thanks for the report. It sounds to me like you might be including a non-public header file. You should not be including the .h
files contained in the ml_dsa
and ml_kem
folders directly. Instead, you can include <oqs/sig.h>
or <oqs/kem.h>
, or just <oqs/oqs.h>
if you want access to the entire liboqs
API. Please see this example for signature use.
Please let me know if that fixes the problem.
Thanks for your prompt answer @SWilson4 ! Our situation is different, since we include only some liboqs (and pqclean) implementations as static libraries inside our software, which is an isolated VM for secure execution with zero dependencies. In this specific case @matteo-cristino solved it like this https://github.com/dyne/Zenroom/pull/850/commits/df2fa4352de6298cfe8c5693eeca6ab4b1f895bd
In conclusion: it is of course fine if you have different names in api.h for reasons inherent to liboqs design, we may solve it even without modifying your header and using extern
directives in our own code, to ease future update.
You may close this issue; it is solved for us.
Trying to include your ml_kem and ml_dsa library in our code we got an error sayign the function contained in the api.h file were not defined. Lookin closer to the files:
config.h
andsign.h
for ml_dsaparamsh.h
andkem.h
for ml_kemIt seems that the functions in api.h file have the wrong name
dilithium2
,dilithium3
anddilithium5
should be replace respectively withml_dsa_44_ipd
,ml_dsa_65_ipd
andml_dsa_87_ipd
kyber512
,kyber768
andkyber1024
should be replace respectively withml_kem_512_ipd
,ml_kem_768_ipd
andml_kem_1024_ipd