jedisct1 / libhydrogen

A lightweight, secure, easy-to-use crypto library suitable for constrained environments.
https://libhydrogen.org
Other
605 stars 90 forks source link

Libhydrogen API hydro_kx_kk_2 getting failed in AIX #135

Open AshishDurgapal opened 2 years ago

AshishDurgapal commented 2 years ago

We have static keys sender private key, sender public key and recipient public key but when we send the packet1 from client to server, then server failed to decrypt the packet using API( hydro_kx_kk_2 ) in AIX platform.

However, same keys are working fine in linux, windows, MAC and android, so could you please let me know why we are not able to decrypt the packet over AIX only.

one more observation, We have generated the static key pairs using API hydro_kx_keygen but keys generated in AIX is not working with linux and vice-a-versa.

jedisct1 commented 1 year ago

Maybe an endianness issue.

Do you have a code snippet that reproduces this?

AshishDurgapal commented 1 year ago

Correct. The issue was due to endianness and we have fixed the issue by using flag . Thanks @jedisct1 for your time.