Implemented a simple random nonce generator.