I would like to know if it is possible to access the Zymbit API, especially the encryption and decryption function from a Docker running in the PI with ZymKey Installed and activated.
If it is possible, what would I need to install in the docker to access the API? Thank you.
Another route that I am thinking to take is to have a simple REST api running on the Host OS of the PI to access the Zymbit Key. This would allow any programming language to have access to the Zymbit without being tied to a specific language implementation.
Does anyone has a sample app for accessing the C library for GoLang ?
I have successfully accessed the C library from Golang. I have lots of sample code – I’m creating an entire secure infrastructure around the Zymbit key.
I have a sample app that I wrote just to learn how to access the C library. I’ll post it on github in a public repository and post the repository name.
go sample code - bizzarri/gozymkey
git clone https://github.com/bizzarri/gozymkey.git should get you the sample go routine, a small shell script to help use it, and a README with sparse documentation. Enjoy. Happy to answer questions.
If you can run the Zymbit access code in GoLang (with REST API) on the host. Then accessing the Zymbit from anywhere is possible. It is just a http/https REST API call.
I tried to install the libzk_app_utils library in a Docker but it has dependency on zkifc (started via systemd) and if i am not mistaken is the interface to the zymbit key. I am not sure if you can run more than one instance of the service.
That’s correct. Only one instance of zkifc can be running on the system.
Having said that, I suppose it might be possible to copy the installed libzk_app_utils.so from the host into the docker container. If your container can communicate on localhost ports 9542 - 9546, then your application should be able to communicate with zkifc.