KMIP Examples
Several modifications are required to make this example run on your machine:
-
In the files ex-kmip-X.cpp (where 'X' is replace with a number like 1, 2, 3), in the function CKmipExample1::initialize(), replace the host name of "fqdn.com" to the fully qualified domain name of the KMIP server you wish to connect to.
-
(Optional) In the files ex-kmip-X.cpp, the function CKmipExample1::createKeystore(), replace the first parameter of the call to openSigned(). The first parameter of openSigned() is the file path where to create and access keystore databases. If NULL, then the keystore location will default to the P6R database directory. If the SKC is installed in a read-only directory then the first parameter will need to be set to an existing read/write directory. Note that the keystore is used to hold the KMIP server certificates so that an SSL connection can be made.
-
Replace the contents of the files: ClientCert.pem, ClientPrivate.pem, and RootCert.pem. These files are required to make an SSL connection to a KMIP server.
-
RootCert.pem is the certificate for the server you wish to connect to.
-
ClientCert.pem is the client's certificate generated by the KMIP server.
-
ClientPrivate.pem is the client's private key generated by the KMIP server.
Replace each file with certificate/private key given to you by the KMIP server administrator.
-
In the file, ../confs/p6kmip.conf, under the section "[p6kmip-gen]" change the "logDir" configuration parameter to an existing, writeable directory path. Use the proper path for the system you are on (Linux, Solaris, or Windows). For eample:
* logDir = "E:\work\current\WINNT6.1_x86_DBG_32bit.OBJ\logs"
*
Or * logDir = "/var/logs/kmip"
*
Note, that this top level log directory must already exist. The SDK will create all needed directories under it.