- All Known Implementing Classes:
DefaultSecureRandomSupplier
public interface ISecureRandomSupplier
Supplies the Wicket application with random bytes.
- Author:
- papegaaij
-
Method Summary
Modifier and TypeMethodDescriptionReturns the actualSecureRandom
being used as source.default String
getRandomBase64
(int length) Returns a url-base64 encoded string with random content, base onlength
bytes.default byte[]
getRandomBytes
(int length) Returns a byte array with random bytes of the given length.
-
Method Details
-
getRandom
Returns the actualSecureRandom
being used as source.- Returns:
- The
SecureRandom
.
-
getRandomBytes
Returns a byte array with random bytes of the given length.- Parameters:
length
- The number of bytes to return.- Returns:
- A byte array with random bytes of the given length.
-
getRandomBase64
Returns a url-base64 encoded string with random content, base onlength
bytes. The length of the returned string will belength/3*4
.- Parameters:
length
- The number of random bytes to use as input.- Returns:
- A string with random base64 data.
-