Virtual CAC using libcacard, virtualsmartcard's vpcd and softhsm2 to provide PCSC accessible virtual smart card.
The virtual pcscd provides a socket based interface on one side, and the classic PCSC API on the other.
OpenSC natively uses the PCSC API to communicate with smart cards. The vpcd relays those communications through its socket. This should work with any application using the PCSC API, but virt_cacard was designed to help with the CI/CD of OpenSC.
The virtual smart card, emulated with libcacard, connects to the socket and can then get (and reply to) APDUs from the application. From the point of view of the application, the process is transparent.
./autogen.sh
./configure
make