PRNG
This API acts as a Pseudo Random Number Generator (PRNG).
URL
<http/https>://<host-name>:<Port>/protectappws/services/rest/prng
Input Parameters
Parameters | Description |
---|---|
username | User name (optional). |
password | Password associated with the user (optional). |
length | The number of random bytes to be generated. |
certAlias | Client certificate alias for making SSL connections (optional). |
certPass | Password for the provided certificate alias (optional). |
Sample REST call for cxf
request
{
"prng": {
"username": "cryptouser",
"password": "safenet123",
"length": "20"
}
}
response
{
"PRNGResponse": {
"prngResponse": "8F542DB70F12FE3CED68E76FDCBF32BC84696905"
}
}
Sample SOAP Parameters
<prot:PRNG>
<username>cryptouser</username>
<password>qwerty1234</password>
<length>4</length>
</prot:PRNG>
Output
Hex of random bytes.
<ns1:PRNGResponse xmlns:ns1="http://dsws.org/protectappws/">725C241D</ns1:PRNGResponse>
Note
The lengths of the returned random bytes are represented in Hex and the length of the Hex value is twice as long as the number of actual bytes.