Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentations && Windows needs #476

Open
GomezJulie opened this issue Oct 6, 2022 · 1 comment
Open

Documentations && Windows needs #476

GomezJulie opened this issue Oct 6, 2022 · 1 comment

Comments

@GomezJulie
Copy link

GomezJulie commented Oct 6, 2022

Hi,
First, thanks for your work.

What is my environment and needs:
I work on Windows 10, 64 bits.
I add package with pacman linux command on my mingw32 terminal (msys64 version of 2022/09/04).
I work on a Qt Creator editor and I have a .pro file to configure my Qt project.
I want to develop a C++ module for my application which use libp11 to get the Yubikey bin number and decrypt file.
Why I use a mingw32 terminal and not the mingw64, because, for the moment, the project is always in develop in QT 4.8.

What I do:
I read the README file and follow the installation step of the INSTALL file (first I follow the MinGW / MSYS chapter, then I follow the MSYS2 chapter.)
I do much more, but I don't remember every thing and I go in many wrong ways.

My problems and questions
Considering this previous information:

  • I have many difficulties to install the necessary environment before using libp11. Did you update the process recently ?
  • I find that there is not enough documentation (Doxygen or wiki) to use function when we work on Windows environment. Can you help me with it ?

For example :
It seems the function PKCS11_CTX_load(...) can take in second argument /usr/lib/opensc-pkcs11.so like I can see on cpp.hotexamples.com.
But in C++ .so are not compatible. So I try with a pkcs11.dll or libpkcs11.dll finding in C:\msys64\mingw32\lib\engines-1_1.
It doesn't work well, the function PKCS11_CTX_load(...) always return -1.

Thank you in advance for your help.

@jmdesp
Copy link

jmdesp commented Oct 25, 2022

Hi, the documentation is indeed severly lacking in many ways, however it's not very clear what you've suceeded until now and what you're try to do precisely, Julie.

For what's it's worth, note however that I found in the following blog entry a lot of information that is either missing or not clear at all here on the official site. It may be that it will help you too :
https://colinpaice.blog/2021/03/08/using-openssl-with-an-hsm-keystore-and-opensc-pkcs11-engines/

Also I did myself some tests with mingw32/msys, and I didn't have sucess when trying to interface this with my USB token using its pkcs#11 dll. Using the native windows artifact from version 0.4.11 instead of the libp11 package from msys worked very well however.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants