REST API  4.0.0
REST API for SafeNet Network HSMs
PUT /api/lunasa/hsms/{hsmid}/partitions/{partitionid}

PUT /api/lunasa/hsms/{hsmid}/partitions/{partitionid}

Initializes the partition.

Parameters

hsmid

The serial number of the HSM of interest

Use: Required

JSON Schema:

   Object
   type: string

partitionid

The identifier of the partition of interest

Use: Required

JSON Schema:

   Object
   type: string

label

A user-friendly text string to reference the partition after it is created

Use: Required

JSON Schema:

   Object
   type: string

domain

The cloning domain name associated with password-based partitions (not applicable for PED-based partitions)

Use: Required

JSON Schema:

   Object
   type: string

password

The password for password-based partitions (not applicable for PED-based partitions)

Use: Required

JSON Schema:

   Object
   type: string

defaultDomain

Use a default cloning domain if password-based partition (not applicable for PED-based partitions)

Use: Required

JSON Schema:

   Object
   type: boolean
         false = do not use a default cloning domain
         true = use a default cloning domain

ped

The identifier of the PED connected to the HSM. '0' is local PED; 1 or greater is remote PED. For remote PED, ped corresponds to the PED identifier. The parameter has no use for password-based HSMs.

Use: Required

JSON Schema:

   Object
   type: string

Responses

204

Success

Location

"Location" is the URL to the initialized partition and is returned in the server response. You can use "Location" to form a GET resource to query the partition.

see GET /api/lunasa/hsms/{hsmid}/partitions/{partitionid}


For PED-based partitions, "Location" is the URL to the task spawned to initialize the partition.

400

Unexpected error

404

HSM or partition does not exist.

Example Request

   PUT
   https://1.2.3.4:8443/api/lunasa/hsms/154704/partitions/273087011507
   {
     "password": "password",
     "label": "ABC123",
     "domain": "domain",
     "defaultDomain": true,
     "ped": "0" 
   }

Example Result

{
password-based partition:
{'Access-Control-Allow-Origin': '*', 'Content-Type': 'application/json', 'Location': '/api/lunasa/hsms/154704/partitions/273087011507', 'Content-Length': '2', 'Access-Control-Allow-Credentials': 'true'}

PED-based partition:
{'Access-Control-Allow-Origin': '*', 'Content-Type': 'application/json', 'Location': '/tasks/5', 'Content-Length': '712', 'Access-Control-Allow-Credentials': 'true'}
}

{}