WHM API.
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/
https://{host}:{port}/json-api/
Request
This function enables DNSSEC on the domain.
Note:
- Only servers that run PowerDNS can use DNSSEC. If you call this function on a server that doesn't use PowerDNS, you will receive an error.
- After you enable DNSSEC on the domain, you must add the Delegation of Signing (DS) records on your DNS server and with your registrar.
- You cannot modify the DNSSEC security key. To make any changes, you must disable, delete, and re-create the DNSSEC security key.
The domain for which to enable DNSSEC.
Note:
To enable DNSSEC on multiple domains, duplicate or increment the parameter name. For example, to check three domains, you could:
- Use the
domainparameter multiple times. - Use the
domain,domain-1, anddomain-2parameters.
Whether to activate the newly-created key.
1- Activate the key.0- Do not activate the key.
The algorithm that the system uses to generate the security key.
5- RSA/SHA-16- DSA-NSEC3-SHA17- RSASHA1-NSEC3-SHA18- RSA/SHA-25610- RSA/SHA-51213- ECDSA Curve P-256 with SHA-25614- ECDSA Curve P-384 with SHA-384
Note:
We recommend that you use an ECDSA Curve P-256 with SHA-256 (13) value if your registrar supports it.
The manner in which the system creates the security key.
classic- Use separate keys for KSK and ZSK. Use this value when thealgo_numparameter is equal to or less than 8.simple- Use a single key for both KSK and ZSK. Use this value when thealgo_numparameter is greater than 8.
The number of times that the system rehashes the first resource record hash operation.
Whether NSEC3 operates in Narrow or Inclusive mode.
Note:
For information about these modes, read PowerDNS's DNSSEC documentation.
1- Narrow mode.0- Inclusive mode.
Whether the system will create records for all delegations.
1- Create records for all delegations.0- Create records only for secure delegations.
Note:
Only use the 1 value if you must create records for all delegations.
A hexadecimal string that the system appends to the domain name before it applies the hash function to the name.
Note:
For information about salt values, read RFC 5155.
Whether the domain will use Next Secure Record (NSEC) or NSEC3 semantics.
1- Use NSEC3 semantics.0- Use NSEC semantics.
Note:
If you use this value, the system ignores the other NSEC3 options.
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/enable_dnssec_for_domains
- A server running WHM.
https://whm-server.tld:2087/json-api/enable_dnssec_for_domains
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
-u <username>:<password> \
'https://api.docs.cpanel.net/_mock/specifications/whm.openapi/enable_dnssec_for_domains?domain=example.com&active=1&algo_num=8&key_setup=classic&nsec3_iterations=7&nsec3_narrow=1&nsec3_opt_out=1&nsec3_salt=1a2b3c4d5e6f&use_nsec3=1'{ "data": { "domains": [ … ] }, "metadata": { "command": "enable_dnssec_for_domains", "reason": "OK", "result": 1, "version": 1 } }
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/export_zone_key
- A server running WHM.
https://whm-server.tld:2087/json-api/export_zone_key
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
-u <username>:<password> \
'https://api.docs.cpanel.net/_mock/specifications/whm.openapi/export_zone_key?domain=example.com&key_id=1'{ "data": { "key_tag": 40481, "key_type": "CSK" }, "metadata": { "command": "export_zone_key", "reason": "OK", "result": 1, "version": 1 } }
The security key's data that the pdnsuti utility's export-zone-key call returns.
- Mock server
https://api.docs.cpanel.net/_mock/specifications/whm.openapi/import_zone_key
- A server running WHM.
https://whm-server.tld:2087/json-api/import_zone_key
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
-u <username>:<password> \
'https://api.docs.cpanel.net/_mock/specifications/whm.openapi/import_zone_key?domain=example.com&key_data=Private-key-format%3A%2520v1.2%250AAlgorithm%3A%252013%2520%5C%28ECDSAP256SHA256%5C%29%250APrivateKey%3A%2520xCM281KtWE9oCsUX8fP1hDZ02%2FX7JCjp4QZA%2FDZjfX0%3D%250A%250A&key_type=ksk'{ "data": { "import_key_id": 1 }, "metadata": { "command": "import_zone_key", "reason": "OK", "result": 1, "version": 1 } }