line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Crypt::Perl::RNG; |
2
|
|
|
|
|
|
|
|
3
|
12
|
|
|
12
|
|
69
|
use strict; |
|
12
|
|
|
|
|
21
|
|
|
12
|
|
|
|
|
284
|
|
4
|
12
|
|
|
12
|
|
52
|
use warnings; |
|
12
|
|
|
|
|
30
|
|
|
12
|
|
|
|
|
291
|
|
5
|
|
|
|
|
|
|
|
6
|
12
|
|
|
12
|
|
4265
|
use Bytes::Random::Secure::Tiny (); |
|
12
|
|
|
|
|
64138
|
|
|
12
|
|
|
|
|
1308
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
my %PID_RNG; |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
sub _get { |
11
|
10203
|
|
66
|
10203
|
|
44869
|
return $PID_RNG{$$} ||= Bytes::Random::Secure::Tiny->new(); |
12
|
|
|
|
|
|
|
} |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
sub bytes { |
15
|
8
|
|
|
8
|
0
|
18
|
return _get()->bytes(@_); |
16
|
|
|
|
|
|
|
} |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
sub bytes_hex { |
19
|
9785
|
|
|
9785
|
0
|
19481
|
return _get()->bytes_hex(@_); |
20
|
|
|
|
|
|
|
} |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
sub bit_string { |
23
|
410
|
|
|
410
|
0
|
988
|
my ($count) = @_; |
24
|
|
|
|
|
|
|
|
25
|
410
|
|
|
|
|
2318
|
return _get()->string_from('01', $count); |
26
|
|
|
|
|
|
|
} |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
1; |