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

zymkey_ssl engine init failed #303

Closed
Sabotaz opened this issue Apr 23, 2019 · 1 comment
Closed

zymkey_ssl engine init failed #303

Sabotaz opened this issue Apr 23, 2019 · 1 comment

Comments

@Sabotaz
Copy link

Sabotaz commented Apr 23, 2019

Hello,

I'm currently trying to use my zymkey hsm with the azure sdk.

I follow the new tutorial (https://github.com/Azure/azure-iot-sdk-c/blob/secure_hsm_tutorial/provisioning_client/devdoc/secure_custom_hsm.md), so I checked out the hsm_secure branch.

I posted the issue here, because my problem is probably in this shared git, sorry if it is not the good place :)

Everything compile, but when i launch the command in order to run it (./provisioning_client/samples/prov_dev_client_ll_sample/prov_dev_client_ll_sample), it stops at the ENGINE_init(e)call, printing only Stack frame dump (0): and nothing else happens (but the program still run...)

I have 2 warnings when i compile:

/usr/bin/ld: warning: libssl.so.1.0.2, needed by /usr/lib/gcc/arm-linux-gnueabihf/6/../../../arm-linux-gnueabihf/libcurl.so, may conflict with libssl.so.1.1
/usr/bin/ld: warning: libcrypto.so.1.0.2, needed by /usr/lib/gcc/arm-linux-gnueabihf/6/../../../arm-linux-gnueabihf/libcurl.so, may conflict with libcrypto.so.1.1

The line where the code stops (i used gdb for that:)
https://github.com/Azure/azure-c-shared-utility/blob/hsm_secure/adapters/tlsio_openssl_secure.c#L1078

(gdb) next
1079	        if (ENGINE_init(e) != 1)
(gdb) next
Stack frame dump (0):
[New Thread 0x7680e430 (LWP 6683)]

(then i can't interact with gdb anymore, the program runs infinitly.)

Anyway, thanks for your work about the zymkey :)

[edit:]
After my last next, it consumes 100% of CPU, and when i kill the process in gdb, it says:

^C
Thread 1 "prov_dev_client" received signal SIGINT, Interrupt.
0x76d5f464 in pthread_join (threadid=<optimized out>, thread_return=0x0) at pthread_join.c:90
90	pthread_join.c: No such file or directory.

[edit2:]
the second thread is libzk_app_utils.so, perhaps the problem is in there side, so i asked this question in there forum too :)

(gdb) info threads
  Id   Target Id         Frame 
* 1    Thread 0x76fef5c0 (LWP 18862) "prov_dev_client" 0x76c37120 in poll () at ../sysdeps/unix/syscall-template.S:84
  2    Thread 0x7680e430 (LWP 18869) "prov_dev_client" 0x769a4cdc in ?? () from /usr/lib/libzk_app_utils.so
@ericwol-msft
Copy link
Contributor

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