Bootstrap FreeKB - Broadcom API Gateway - Create a Private Key using the Gateway Migration Utility
Broadcom API Gateway - Create a Private Key using the Gateway Migration Utility

Updated:   |  Broadcom API Gateway articles

This assumes you are familiar with the basic usage of the Gateway Migration Utility. Before you create a private key in the API Gateway, you may want to list the private keys that are already in the API Gateway.

Create an XML file.

touch createPrivateKey.xml

 

Add the following to the XML file. In this example, key001 will be created.

<l7:PrivateKeyCreationContext xmlns:l7="http://ns.l7tech.com/2010/04/gateway-management">
     <l7:Dn>CN=www.example.com</l7:Dn>
     <l7:Properties>
         <l7:Property key="signatureHashAlgorithm">
             <l7:StringValue>SHA384</l7:StringValue>
         </l7:Property>
         <l7:Property key="rsaKeySize">
             <l7:IntegerValue>2048</l7:IntegerValue>
         </l7:Property>
         <l7:Property key="ecName">
             <l7:StringValue>key001</l7:StringValue>
         </l7:Property>
         <l7:Property key="daysUntilExpiry">
             <l7:IntegerValue>365</l7:IntegerValue>
         </l7:Property>
         <l7:Property key="caCapable">
             <l7:BooleanValue>true</l7:BooleanValue>
         </l7:Property>
     </l7:Properties>
 </l7:PrivateKeyCreationContext>

 

Then issue this command.

/path/to/GatewayMigrationUtility.sh restman
-host apig.example.com
-port 8443
-username john.doe
-password f5VPX0yUJPg.m4BrjdgMv84UgktddJD3xA
-method POST
-path '1.0/privateKeys/00000000000000000000000000000002:key001'
-request createPrivateKey.xml

 

Or the -argFile option can be used, to reduce the number of options that are used on the command line.

/path/to/GatewayMigrationUtility.sh restman
-argFile example.properties
-method POST
-path '1.0/privateKeys/00000000000000000000000000000002:key001'
-request createPrivateKey.xml



Did you find this article helpful?

If so, consider buying me a coffee over at Buy Me A Coffee



Comments


Add a Comment


Please enter fb5b6c in the box below so that we can be sure you are a human.