I have a CSR file and CA keys
Thanks
See the x509 unit tests and the PKI demo in contribs. The latter might need tweaks since it has not been maintained.
The unit tests were a huge help for me. thanks for the pointer.