harrison314 / BouncyHsm

Bouncy Hsm is a software simulator of HSM and smartcard simulator with HTML UI, REST API and PKCS#11 interface.
BSD 3-Clause "New" or "Revised" License
34 stars 3 forks source link

Add passing PKCS11 connection string via shared file #7

Closed zdrlik closed 1 month ago

harrison314 commented 1 month ago

What problem was this feature supposed to solve?

If you still implement it, keep it so that the environment variable from the connection string takes precedence over the file, so that the PKCS11 library can be controlled per process.

For any outputs use log_message instead of printf and do not change the default logging levels. Unexpected output to STDOUT causes problems for applications using native messaging.

zdrlik commented 1 month ago

Hi, thanks for your email. I apologize for the PR - it was mistakenly created against your repo, I've already removed it.

According to the problem, this feature tries to solve - I need to run the BouncyHsm as a docker image. It works fine when the connection string is set before the client app (custom app written in .NET) starts. But I also need to run this docker image from tests using the Testcontainers library. In this case, the connection string is not known when the tests start, but dynamically after running the container with Testcontainers. Passing the connection string from the running tests by Environment.SetEnvironmentVariables does not work for that case. That's why I am trying to find a workaround to pass the config via a file.

Regards,

Zdenek

pá 23. 8. 2024 v 13:45 odesílatel Jozef Gajdoš @.***> napsal:

What problem was this feature supposed to solve?

If you still implement it, keep it so that the environment variable from the connection string takes precedence over the file, so that the PKCS11 library can be controlled per process.

For any outputs use log_message instead of printf and do not change the default logging levels. Unexpected output to STDOUT causes problems for applications using native messaging.

— Reply to this email directly, view it on GitHub https://github.com/harrison314/BouncyHsm/pull/7#issuecomment-2306921202, or unsubscribe https://github.com/notifications/unsubscribe-auth/AB22U44RMHKQRZVKSVEQGRDZS4OF5AVCNFSM6AAAAABM7QZLXCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMBWHEZDCMRQGI . You are receiving this because you modified the open/close state.Message ID: @.***>