REST API
4.0.0
REST API for SafeNet Network HSMs
|
Creates a partition.
The serial number of the HSM of interest
Use: Required
JSON Schema:
Object type: string
Indicates whether to create the partition with a default domain. Note that if you set this flag to true the domain parameter is ignored. Either the defaultDomain parameter or the domain parameter is required when creating a legacy partition.
Use: Not Required
JSON Schema:
Object type: boolean false = do not use a default domain true = use a default domain
Indicates whether to create the partition with a default challenge.
Use: Not Required
JSON Schema:
Object type: boolean false = do not use a default challenge true = use a default challenge
A user-friendly text string to reference the partition after it is created
Use: Required
JSON Schema:
Object type: string
Indicates whether to create the partition with all available storage space assigned to it. Note that if you set this flag to true the size parameter is ignored. Either the allStorageSpace parameter or the size parameter is required when creating a legacy partition.
Use: Not Required
JSON Schema:
Object type: boolean false = do not use all available storage space true = assign all remaining, available storage space to the partition
A user-friendly text string to reference the partition after it is created The label parameter is required when creating a legacy partition.
Use: Not Required
JSON Schema:
Object type: string
The cloning domain name associated with password-based partitions (not applicable for PED-based partitions). For PED-based partitions, you must provide the "domain" parameter with the POST: use "" in this case. Either the defaultDomain parameter or the domain parameter is required when creating a legacy partition.
Use: Not Required
JSON Schema:
Object type: string
Indicates whether to create the partition with a Security Officer
Use: Required
JSON Schema:
Object type: boolean false = do not create the partition with a Security Officer true = create the partition with a Security Officer
The password for password-based partitions (not applicable for PED-based partitions) The password parameter is required when creating a legacy partition.
Use: Not Required
JSON Schema:
Object type: string
The number of bytes of storage space to assign to the partition if allStorageSpace is false Either the allStorageSpace parameter or the size parameter is required when creating a legacy partition.
Use: Not Required
JSON Schema:
Object type: integer
Partition details
JSON Schema: Partition description
"Location" is the URL to the partition and is returned in the server response. You can use "Location" to form a GET resource to obtain the partition.
see GET /api/lunasa/hsms/{hsmid}/partitions/{partitionid}
For PED-based partitions, "Location" is the URL to the task spawned to create the partition.
Unexpected error
HSM does not exist.
POST https://1.2.3.4:8443/api/lunasa/hsms/154704/partitions { "defaultDomain": true, "defaultChallenge": true, "name": "123", "allStorageSpace": false, "label": "123", "domain": "", "hasPso": false, "password": "", "size": 20480 }
Password-based partition: {'Access-Control-Allow-Origin': '*', 'Content-Type': 'application/json', 'Location': '/api/lunasa/hsms/151256/partitions/352170252337', 'Content-Length': '712', 'Access-Control-Allow-Credentials': 'true'} PED-based partition: {'Access-Control-Allow-Origin': '*', 'Content-Type': 'application/json', 'Location': '/tasks/0', 'Content-Length': '712', 'Access-Control-Allow-Credentials': 'true'} { }