Forum Discussion

jgill_43164's avatar
jgill_43164
Icon for Nimbostratus rankNimbostratus
May 16, 2011

Where to place .pfx files to import them through iControl

Hello,

 

I am having trouble importing .pfx SSL related files through iControl. The files import file through the GUI, but we are trying to do this through C code now. I am not sure which directory the .pfx file should by placed on (via SFTP) to the F5 units.

 

 

When I use the method "pkcs12_import_from_file" I receive the error below:

 

 

iControlInterfaces.ManagementKeyCertificate.pkcs12_import_from_file(iControl.ManagementKeyCertificateManagementModeType.MANAGEMENT_MODE_DEFAULT, certificateIds, certificateFileNames, certificatePasswords, true);

 

 

Exception: Common::OperationFailed

 

primary_error_code : -7 (0xFFFFFFF9)

 

secondary_error_code : 0

 

error_string : error:0906D06C:PEM routines:PEM_read_bio:no start line

 

 

When I try and use certificate import from file I get a no such file or directory error, but I am not sure which directory to place the file(s) in.

 

 

iControlInterfaces.ManagementKeyCertificate.certificate_import_from_file(iControl.ManagementKeyCertificateManagementModeType.MANAGEMENT_MODE_DEFAULT, certificateIds, certificateFileNames, true);

 

 

Exception: Common::OperationFailed

 

primary_error_code : 2 (0x00000002)

 

secondary_error_code : 0

 

error_string : No such file or directory

 

  • Nevermind, I found the issue I needed to reverse the path directions from \ to /.
  • So did you have to first SFTP the .pfx file before calling iControlInterfaces.ManagementKeyCertificate.pkcs12_import_from_file API? If you had to then, in which directory did you put the .pfx file?