summaryrefslogtreecommitdiffstats
path: root/lib/Providers/Rng/CSRNGProvider.php
blob: 8dba7fc91c375cc52139d8351e3097bcf3606bb8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
<?php

namespace RobThree\Auth\Providers\Rng;

class CSRNGProvider implements IRNGProvider
{
    public function getRandomBytes($bytecount) {
        return random_bytes($bytecount);    // PHP7+
    }
    
    public function isCryptographicallySecure() {
        return true;
    }
}