add Kevacoin utils

This commit is contained in:
ghost 2024-02-12 21:08:38 +02:00
parent 6ec264df7d
commit 0e33447c91

26
src/Kevacoin.php Normal file
View File

@ -0,0 +1,26 @@
<?php
declare(strict_types=1);
namespace Kvazar\Crypto;
class Kevacoin
{
function decode(string $value)
{
if (is_numeric($string) && $string < 0xFFFFFFFF)
{
return mb_chr(
$string,
'ASCII'
);
}
else
{
return hex2bin(
$string
);
}
}
}