Forum Discussion
2 Replies
Sort By
- Jeffrey_Silver1Nimbostratus
Ok, let me try another way. I am trying to export ssl certificates from one LTM to another using powershell and iControl. The better question is am I going about this in the correct manner.
- Jeffrey_Silver1Nimbostratus
With the assitance of Joe Pruitt, I have been able to figure out what I was having issues with. The goal is to get the clientSSL certs from one F5 into another F5 without doing a full configSync type process. The following code snipped in POWERSHELL gets the .crt and .key content that I am planning on importing into the other LTM using the cerfiticate_import_from_pem and key_import_from_pem methods.
if ( Initialize-F5.iControl -Hostname $name -Username xxxx -Password xxxx ) { $g_Certs = (Get-F5.iControl).ManagementKeyCertificate $ocrt = ($g_Certs).certificate_export_to_pem('MANAGEMENT_MODE_DEFAULT',$cname) $okey = ($g_Certs).key_export_to_pem('MANAGEMENT_MODE_DEFAULT',$cname) } else { write-host "Critical Error Has Occurred. Cannot Initialize secondary iControl" return $false }