QPID C++ Broker and QPID-CPP SSL Certificates

I am trying to set up SSL with QPID and I'm having trouble figuring out how to set up the certificates. I have made a certificate database and added a self signed certificate to it like so:

mkdir ${CERT_DIR}
certutil -N -d ${CERT_DIR} -f ${CERT_PW_FILE}
certutil -S -d ${CERT_DIR} -n ${NICKNAME} -s "CN=${NICKNAME}" -t "CT,," -x -f ${CERT_PW_FILE} -z /usr/bin/certutil

I then started the QPID C++ Broker, passing it the ${CERT_DIR}, the ${NICKNAME} and the ${CERT_PW_FILE}. The broker log tells me that the SSL listener is running on my port of choice.

However, I'm not sure what directory/certificate name I should give as environment variables when starting the QPID-CPP C++ client? I have tried passing the directory as ${CERT_DIR} and the certificate name as ${NICKNAME} but this doesn't seem to work; the QPID log prints the message:

**[System] error Error reading socket: SSL peer cannot verify your certificate [-12271].**

What is the correct procedure to set up a server and client certificate to use with QPID? It says it must be done using certutil.

Thanks