Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F4130220
Secure.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
Secure.php
View Options
<?php
/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <fabien@symfony.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace
Symfony\Polyfill\Php82\Random\Engine
;
use
Random\RandomException
;
use
Symfony\Polyfill\Php82\NoDynamicProperties
;
/**
* @author Tim Düsterhus <tim@bastelstu.be>
* @author Anton Smirnov <sandfox@sandfox.me>
*
* @internal
*/
class
Secure
{
use
NoDynamicProperties
;
public
function
generate
():
string
{
try
{
return
random_bytes
(
\PHP_INT_SIZE
);
}
catch
(
\Exception
$e
)
{
throw
new
RandomException
(
$e
->
getMessage
(),
$e
->
getCode
(),
$e
->
getPrevious
());
}
}
public
function
__sleep
():
array
{
throw
new
\Exception
(
"Serialization of 'Random
\E
ngine
\S
ecure' is not allowed"
);
}
public
function
__wakeup
():
void
{
throw
new
\Exception
(
"Unserialization of 'Random
\E
ngine
\S
ecure' is not allowed"
);
}
public
function
__clone
()
{
throw
new
\Error
(
'Trying to clone an uncloneable object of class Random
\E
ngine
\S
ecure'
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Wed, Aug 19, 10:17 (2 w, 6 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
2d/b4/f1e78383d75314e3716e8631a66c
Default Alt Text
Secure.php (1 KB)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment