open-quantum-safe / liboqs-python

Python 3 bindings for liboqs
https://openquantumsafe.org/
MIT License
108 stars 39 forks source link

Invalid configuration on Windows 10 by default #36

Closed zerjioang closed 2 years ago

zerjioang commented 3 years ago

I have compile liboqs to work in Windows via liboqs.dll. I correctly setup the PATH pointing to my bin folder that contains this DLL in order to be recognized by the system. However, when I run python examples/kem.py the error No liboqs shared libraries found is raised.

I found that a solution to fix this issue on Windows platform is to replace the constant "oqs" by "liboqs" in

https://github.com/open-quantum-safe/liboqs-python/blob/8bf81666cf992e1ba73c6dee339eca4c3797af82/oqs/oqs.py#L25

In this way, the Windows setup will be able to solve the shared library lookup. Should we consider this alternative call configuration for Windows based python interactions?

vsoftco commented 3 years ago

Thanks, I will take a look

dstebila commented 2 years ago

Is this still a problem?

vsoftco commented 2 years ago

@dstebila will check on my VM and fix or close the issue if fixed

dstebila commented 2 years ago

@vsoftco #45 provides a temporary workaround to run liboqs-python on Windows inside a Docker container, but a native fix for this would be ideal.

vsoftco commented 2 years ago

@dstebila I fixed it on my VM, will push a fix soon

vsoftco commented 2 years ago

@zerjioang Fixed by https://github.com/open-quantum-safe/liboqs-python/commit/a44565b25ebe7b12d2ee7b8667711eee413ba81e