mirror of
https://github.com/elyby/accounts.git
synced 2024-12-26 07:09:46 +05:30
17 lines
341 B
PHP
17 lines
341 B
PHP
<?php
|
|
namespace api\components\OAuth2\Utils\KeyAlgorithm;
|
|
|
|
use League\OAuth2\Server\Util\KeyAlgorithm\KeyAlgorithmInterface;
|
|
use Ramsey\Uuid\Uuid;
|
|
|
|
class UuidAlgorithm implements KeyAlgorithmInterface {
|
|
|
|
/**
|
|
* @inheritdoc
|
|
*/
|
|
public function generate($len = 40) : string {
|
|
return Uuid::uuid4()->toString();
|
|
}
|
|
|
|
}
|