Forum Discussion
Philip_L
Apr 05, 2012Nimbostratus
Per that post and your reccomendation I tried that (see begining of my last post) and it failed with:
Exception: Common::OperationFailed
primary_error_code : -17 (0xFFFFFFEF)
secondary_error_code : 0
error_string : Invalid filename. Filenames may only contain the following characters: [A-Za-z][0-9].-_/
here is the code I ran:
NetworkCredential creds = new NetworkCredential();
creds.UserName = "username";
creds.Password = "password";
String[] ids = new string[24];
ids[0] = "test";
String[] file_names = new string[100];
file_names[0] = "C:/SSLInfo/Certs/chut.pfx";
String[] passwords = new string[24];
passwords[0] = "pass";
Management.KeyCertificate.iControl.ManagementKeyCertificate iControl = new Management.KeyCertificate.iControl.ManagementKeyCertificate();
iControl.Url = "https://bigip/iControl/iControlPortal.cgi";
iControl.Credentials = creds;
iControl.pkcs12_import_from_file(Management.KeyCertificate.iControl.ManagementKeyCertificateManagementModeType.MANAGEMENT_MODE_WEBSERVER, ids, file_names, passwords, false);