blob: e4e71c26aaed14f65a0fa619d0c46c2db001f791 [file] [log] [blame]
Matthias Andreas Benkardb382b102021-01-02 15:32:21 +01001<?php
2
3namespace RobThree\Auth\Providers\Rng;
4
5interface IRNGProvider
6{
Matthias Andreas Benkard7b2a3a12021-08-16 10:57:25 +02007 /**
8 * @param int $bytecount the number of bytes of randomness to return
9 *
10 * @return string the random bytes
11 */
Matthias Andreas Benkardb382b102021-01-02 15:32:21 +010012 public function getRandomBytes($bytecount);
Matthias Andreas Benkard7b2a3a12021-08-16 10:57:25 +020013
14 /**
15 * @return bool whether this provider is cryptographically secure
16 */
Matthias Andreas Benkardb382b102021-01-02 15:32:21 +010017 public function isCryptographicallySecure();
Matthias Andreas Benkard7b2a3a12021-08-16 10:57:25 +020018}